DHCP troubleshooting
Users on two LANs complain. On LAN 10 (192.168.10.0/24, behind R1 Gi0/0) PCs get an address but can't reach anything outside the LAN. On LAN 20 (192.168.20.0/24, behind R1 Gi0/1) PCs get no address at all. The DHCP server is R2 (10.0.0.2), with a pool for each LAN. Fix every fault (on R1 and R2) so both PCs get correct leases and can ping the server.
How it works: this is VulnTech NetLab, a network simulator running in your browser. Click a device in the diagram to open its console and type commands, just like on real equipment (? shows help, Tab finishes a word). Click a cable to inspect it. Tasks tick themselves off as you complete them; questions are answered in the box under each task. Your work is kept if you reload; Reset starts the network over.
Solution explanation
LAN 10's pool handed out 192.168.10.254 as the gateway, an address nobody has; it must be R1's 192.168.10.1, and the PCs only pick up the change when they renew. LAN 20 had two faults: R1's Gi0/1 had no ip helper-address, so the broadcasts never left the LAN; and even relayed, R2 had no pool for giaddr 192.168.20.1, because LAN20's pool said 192.168.21.0.
Show solution
[PC1]
ipconfig /all
[R2]
enable
show running-config | section dhcp
configure terminal
ip dhcp pool LAN10
default-router 192.168.10.1
ip dhcp pool LAN20
no network 192.168.21.0 255.255.255.0
network 192.168.20.0 255.255.255.0
end
[R1]
enable
configure terminal
interface g0/1
ip helper-address 10.0.0.2
end
[PC1]
ipconfig /renew
ping 10.0.0.2
[PC2]
sudo dhclient eth0
ping -c 3 10.0.0.2