Skip to content

Instantly share code, notes, and snippets.

@f-bader
Created November 3, 2017 10:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save f-bader/2e2c897da883354d955269f884835ed6 to your computer and use it in GitHub Desktop.
Save f-bader/2e2c897da883354d955269f884835ed6 to your computer and use it in GitHub Desktop.
Switch(config)# ip dhcp pool DHCP-Vlan1
Switch(dhcp-config)# network 172.16.100.1 /24
Switch(dhcp-config)# domain-name example.com
Switch(dhcp-config)# dns-server 172.16.0.10 172.16.0.11
Switch(dhcp-config)# default-router 172.16.100.254
Switch(dhcp-config)# lease 7
Switch(dhcp-config)# exit
Switch(config)# ip dhcp pool DHCP-Vlan2
Switch(dhcp-config)# network 172.16.200.1 /24
Switch(dhcp-config)# domain-name example.com
Switch(dhcp-config)# dns-server 172.16.0.10 172.16.0.11
Switch(dhcp-config)# default-router 172.16.200.254
Switch(dhcp-config)# lease 7
Switch(dhcp-config)# exit
Switch(config)# interface vlan1
Switch(config-if)# ip address 172.16.100.1 255.255.255.0
Switch(config)# interface vlan2
Switch(config-if)# ip address 172.16.200.1 255.255.255.0
Switch(config-if)# end
Switch# show ip dhcp binding
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment