ip dhcp pool <name>
Create a DHCP pool. Inside the pool define network, default-router, dns-server, etc. A switch serves the subnet of the SVI in the client's VLAN, so that SVI must be up with an address inside the pool's network.
Example
R1(config)# ip dhcp pool LAN
R1(dhcp-config)# network 10.0.0.0 /24
R1(dhcp-config)# default-router 10.0.0.1On a server there is no enable or configure terminal: give it a static IP first (ipconfig 192.168.1.2 255.255.255.0 192.168.1.1), then type 'ip dhcp pool LAN' at the Terminal, followed by network, default-router, dns-server and end. Clients lease with dhclient or ipconfig /renew. The pool never offers an address another device already holds. dns-server only tells clients which resolver to use: servers don't answer DNS queries here, and dig/nslookup resolve device names directly.
Don't just read it — type ip dhcp pool <name> in a real network simulator in your browser and watch it take effect. No install, no account needed to start.
Frequently asked
What does the "ip dhcp pool <name>" command do?
Create a DHCP pool. Inside the pool define network, default-router, dns-server, etc. A switch serves the subnet of the SVI in the client's VLAN, so that SVI must be up with an address inside the pool's network.
What's the common gotcha with "ip dhcp pool <name>"?
On a server there is no enable or configure terminal: give it a static IP first (ipconfig 192.168.1.2 255.255.255.0 192.168.1.1), then type 'ip dhcp pool LAN' at the Terminal, followed by network, default-router, dns-server and end. Clients lease with dhclient or ipconfig /renew. The pool never offers an address another device already holds. dns-server only tells clients which resolver to use: servers don't answer DNS queries here, and dig/nslookup resolve device names directly.
Example of "ip dhcp pool <name>"
R1(config)# ip dhcp pool LAN R1(dhcp-config)# network 10.0.0.0 /24 R1(dhcp-config)# default-router 10.0.0.1