Method used to configure NAT and DHCP on the AR


Huawei AR series routers support DHCP and NAT so that users can dynamically obtain IP addresses and access the Internet. This function applies to all versions and models of the AR.

Other related questions:
Method used to configure DHCP client on the AR
The AR can function as a DHCP client to dynamically obtain configuration parameters such as an IP address from a DHCP server. This reduces the configuration costs and the errors and facilitates centralized management. Assume that RouterA functions as the DHCP client and RouterB as the DHCP server. The configuration is as follows: 1. Configure RouterA. [HUAWEI] dhcp enable //Enable the DHCP function. [HUAWEI] interface GigabitEthernet0/0/0 [HUAWEI-GigabitEthernet0/0/0] ip address dhcp-alloc //Enable the DHCP client on an interface. [HUAWEI-GigabitEthernet0/0/0] quit 2. Configure RouterB. [HUAWEI] dhcp enable //Enable the DHCP function. [HUAWEI] ip pool p1 [HUAWEI-ip-pool-p1] gateway-list //Configure the gateway IP address. [HUAWEI-ip-pool-p1] network mask //Specify the range of IP addresses that can be dynamically allocated in the global address pool. [HUAWEI-ip-pool-p1] quit [HUAWEI] interface GigabitEthernet0/0/0 [HUAWEI-GigabitEthernet0/0/0] ip address [HUAWEI-GigabitEthernet0/0/0] dhcp select global //Configure the global address pool mode. 3. Verify the configuration. Run the display ip interface brief command on RouterA to view the IP address that GE0/0/0 has obtained.

Method used to configure static NAT on the AR
Huawei AR routers support static NAT. Use either of the following methods to configure static NAT: Method 1: Configure static mapping in the interface view. Translate the combination of the public IP address and port 200 in TCP packets to the combination of the private IP address and port 300. [Huawei] interface gigabitethernet 1/0/0 [Huawei-GigabitEthernet1/0/0] nat static protocol tcp global 200 inside 300 Method 2: Configure static mapping in the system view. Translate the combination of Loopback 4 interface address and port 43 in TCP packets to private address [Huawei] nat static protocol tcp global interface loopback 4 43 inside netmask For details on the static NAT configuration, see "NAT Configuration->Configuring NAT->Configuring Static NAT" in Configuration Guide - IP Service.

If you have more questions, you can seek help from following ways:
To iKnow To Live Chat
Scroll to top