同网段dhcp
[r1]dhcp enable
[r1]dhcp server forbidden-ip 192.168.1.254
[r1-dhcp-pool-1]dhcp server ip-pool 1
[r1-dhcp-pool-1] gateway-list 192.168.1.254
[r1-dhcp-pool-1]network 192.168.1.0 mask 255.255.255.0
[r1-dhcp-pool-1]expired day 1 hour 12
[r1-GigabitEthernet0/0]dhcp select server