Configuring a DHCP server with VLAN on a switch
31,289
yes, of course it's possible
take a look at this, i think it's what u want :
Here is what u should do :
ip dhcp pool pool1
network 10.10.1.0 255.255.255.0
default-router 10.10.1.1
dns-server what.ever.ip.itis
!
ip dhcp pool pool2
network 10.10.2.0 255.255.255.0
default-router 10.10.2.1
dns-server what.ever.ip.itis2
vlan 10
ip address 10.10.1.1 255.255.255.0
!
vlan 20
ip address 10.10.2.1 255.255.255.0
you must define two pools( or more ), and give them same range IP as u gave to your VLANs ... it will work ...
And you should also exclude ip addresses that the router uses (.1 in this example).
Author by
user2142166
Updated on November 24, 2022Comments
-
user2142166 over 1 year
I have a problem while configuring a switch, I want to create a VLAN and to activate the DHCP server and so all switch ports associated to this VLAN will receive automatically an IP address from the DHCP server.
So I want to ask you if this is possible ? and If 'yes', how can I dot it ? because I didn't found the appropriates commands (cisco or d-link) !