1, the experimental topology:
2, configuration commands:
AR2:
<The Huawei> System-View
[Huawei] # DHCP enable DHCP service opening
[Huawei] interface GigabitEthernet 0/0/0 # Configure interface to enter
[Huawei-GigabitEthernet0 / 0/0 ] ip address 192.168.1.1 24 # Configure IP address
[Huawei -GigabitEthernet0 / 0/0] quit
[the Huawei] IP CYZ the pool established IP address pool #
[Huawei-ip-pool-cyz ] network 192.168.1.0 mask 255.255.255.0 # set IP
[IP-the Huawei-the pool-CYZ] Gateway- set the gateway list 192.168.1.1 #
[Huawei-ip-pool-cyz ] dns-list 202.106.0.20 # set the DNS
[the Huawei the pool-CYZ-IP-] quit
[the Huawei] interface of GigabitEthernet 0/0/0
[the Huawei-the GigabitEthernet0 / 0/0] dhcp select global # open global allocation
[Huawei-GigabitEthernet0 / 0/0 ] quit