2950 Assign DHCP to VLAN

Answered Question
Apr 28th, 2012

Morning,

Stumped again with my Catalyst 2950. Everything is working perfectly with wan/dhcp/router on fa 0/1 with all ports assigned to vlan1. All devices plugged in connect to the router correctly with ip's being assigned via dhcp.

Instead of hooking up by console port I want to be able to SSH or telnet in to the switch using any port while still maintaining the above functionallity. Is it possible to assign a dhcp assigned ip address to vlan 2 and have vlan1 and 2 bridged? Or is there a better way of doing this?

I have this problem too.
0 votes
Correct Answer by John Blakley about 1 year 11 months ago

Alex,

You can put the management address on any vlan that you want, but the vlan will need to be accessible from hosts. If you put the address on vlan 2, you'll need to have your host on a port that's configured for vlan 2 or router-on-a-stick configured on the router to route for vlan 2. Either way, the easiest is to put your address on vlan 1 since the 2950 is a L2 switch (no routing functionality). You can only have a management address on the 2950 and that address cannot be used as a gateway for hosts; you would still use the router as your gateway.

Console into the switch and run these commands from the config prompt:

int vlan 1

ip address 192.168.1.2 255.255.255.0 (or whatever address you want to give it).

You'll want to have the address in the same subnet as what you're giving your hosts from your dhcp server, but you don't want the address to be in the range of the dhcp scope. If it is, you'll need to exclude the address on your router (if that's where the scope is) by putting in the command:

ip dhcp excluded-address (if it's the above one, it's: ip dhcp excluded-address 192.168.1.2)

HTH,

John

Please rate useful posts...

Correct Answer by Andydabell2 about 1 year 11 months ago

You could apply a static IP address to vlan 1 and then exclude that address from the dhcp pool.

Sent from Cisco Technical Support iPhone App

  • 1
  • 2
  • 3
  • 4
  • 5
Average Rating: 5 (2 ratings)
Correct Answer
Andydabell2 Sat, 04/28/2012 - 03:52

You could apply a static IP address to vlan 1 and then exclude that address from the dhcp pool.

Sent from Cisco Technical Support iPhone App

jpvh12345 Sat, 04/28/2012 - 04:32

Is ssh supported and configured on the switch? Are you attempting to open an ssh connection to the bridge admin address (the vlan1 address)?

Sent from Cisco Technical Support iPad App

Correct Answer
John Blakley Sat, 04/28/2012 - 05:35

Alex,

You can put the management address on any vlan that you want, but the vlan will need to be accessible from hosts. If you put the address on vlan 2, you'll need to have your host on a port that's configured for vlan 2 or router-on-a-stick configured on the router to route for vlan 2. Either way, the easiest is to put your address on vlan 1 since the 2950 is a L2 switch (no routing functionality). You can only have a management address on the 2950 and that address cannot be used as a gateway for hosts; you would still use the router as your gateway.

Console into the switch and run these commands from the config prompt:

int vlan 1

ip address 192.168.1.2 255.255.255.0 (or whatever address you want to give it).

You'll want to have the address in the same subnet as what you're giving your hosts from your dhcp server, but you don't want the address to be in the range of the dhcp scope. If it is, you'll need to exclude the address on your router (if that's where the scope is) by putting in the command:

ip dhcp excluded-address (if it's the above one, it's: ip dhcp excluded-address 192.168.1.2)

HTH,

John

Please rate useful posts...

Actions

Login or Register to take actions

This Discussion

Posted April 28, 2012 at 3:13 AM
Stats:
Replies:3 Avg. Rating:5
Views:1680 Votes:0
Shares:0
Tags: dhcp, vlan, 2950, assign
+

Related Content

Discussions Leaderboard

Rank Username Points
1 14,997
2 8,150
3 7,720
4 7,078
5 6,723
Rank Username Points
175
80
60
59
55