Home
Certification Preparation
Cisco
CCNA & CCENT
can a switch be a dhcp client?
clarson
Can a switch get its ip address and etc. from a dhcp server?
A router can obtain an ip address from a dhcp for an interface using ip address dhcp
But, when I tried that on 2950 switch it didn't work.
Find more posts tagged with
Comments
azaghul
For a L2 only switch, about the only place you could put it is under interface vlan.
interface vlan 1 ip address dhcp
For a L3 switch, either under interface vlan, or a physical interface after converting it to routed mode.
interface fast 1/0/1 no switchport ip address dhcp
But this general rule can also change depending on the hardware platform used, not all Cisco switches are created equal...
clarson
I thought that is how it would work also. I guess just not on a 2950.
S1(config)#inter vlan 1
S1(config-if)#ip address dh
S1(config-if)#ip address dh?
% Unrecognized command
S1(config-if)#ip address d?
% Unrecognized command
S1(config-if)#ip address dh?
% Unrecognized command
S1(config-if)#ip address dhc?
% Unrecognized command
S1(config-if)#ip address dhcp
^
% Invalid input detected at '^' marker.
Iristheangel
The 2950 is a pretty old switch - it might not be available on either the version of code you are running or the switch. I've gotten it to work on the 2960 model though.
bigdogz
Yeah it can work....
I had to do it in a pinch some time ago. You may want to check the code running on the switch.
clarson
well it is:
C2950 Software (C2950-I6K2L2Q4-M), Version 12.1(22)EA14,
which is pretty good for a 2950
Quick Links
All Categories
Recent Posts
Activity
Unanswered
Groups
Best Of