No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

CLI-based Configuration Guide - IP Service

AR100, AR120, AR160, AR1200, AR2200, AR3200, and AR3600 V300R003

This document describes the concepts and configuration procedures of IP Service features on the device, and provides the configuration examples.

Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Dynamic ARP

Dynamic ARP

Definition

Dynamic ARP entries are automatically generated and maintained using ARP packets. They can be aged, updated, or overwritten by Static ARP entries.

Dynamic ARP applies to a network that has a complex topology and transmits delay-sensitive services.

Address Resolution Process

Dynamic ARP broadcasts ARP Request packets and unicasts ARP Reply packets to complete address resolution.

Figure 2-1  Address resolution process

As shown in Figure 2-1, Host_1 and Host_3 are on the same network segment, and Host_1 needs to send data to Host_3.

  1. Host_1 searches its local ARP table for the ARP entry of Host_3. If the MAC address of Host_3 is found, Host_1 uses this MAC address to encapsulate the data packet into a frame and sends it to Host_3. If Host_1 does not find the MAC address of Host_3, Host_1 caches the data packet and broadcasts an ARP Request packet. In Figure 2-1, the value 1 of the OP field indicates an ARP Request packet. The source MAC and IP addresses in this packet belong to Host_1, the destination MAC address is all 0s, and the destination IP address belongs to Host_3. For details on the ARP packet format, see ARP Packet Format.
  2. Router_1 receives the ARP Request packet and forwards it in the same broadcast domain.
  3. Host_2 and Host_3 in the same broadcast domain can receive the ARP Request packet, but only the destination host (Host_3) processes the packet. Host_3 compares its IP address with the destination IP address in the ARP Request packet. If the IP addresses are the same, Host_3 adds the source IP and MAC addresses (IP and MAC addresses of Host_1) in the packet to the local ARP table, and then unicasts an ARP Reply packet to Host_1. In Figure 2-1, the value 2 of the OP field indicates an ARP Reply packet. The source MAC and IP addresses in this packet belong to Host_3, and the destination MAC and IP addresses belong to Host_1.
  4. Router_1 receives the ARP Reply packet and forwards it to Host_1. After receiving the ARP Reply packet, Host_1 adds the MAC address of Host_3 to the local ARP table. At the same time, Host_1 encapsulates the data packet in a frame and forwards it to Host_3.

When two hosts on different network segments need to communicate with each other (for example, Host_1 and Host_4 in Figure 2-1), and the default gateway address has been set on Host_1, Host_1 sends an ARP Request packet to request the MAC address mapping the router's IP address. After receiving an ARP Reply packet from the router, Host_1 encapsulates the data packet and sends it to the gateway. The gateway then forwards the data packet to the destination host (Host_4). The ARP address resolution procedures on Host_1, Host_4, and the gateway are the same as those on Host_1 and Host_3, and are not mentioned here.

ARP Aging Mechanism

If Host_1 broadcasts an ARP Request packet every time it sends data to Host_3, as shown in Figure 2-1, the communication traffic on the network will increase. In addition, all the devices in the same broadcast domain need to receive and process this ARP Request packet, greatly reducing the device running efficiency on the network. To solve the preceding problems, each host or device maintains a high-speed ARP cache, which is the key to the efficient ARP operations. This high-speed cache stores the mapping between IP and MAC addresses (that is, dynamic ARP entries) recently learned by the host or device.

A host or device first queries the local high-speed cache for the MAC address mapping the destination IP address every time it sends a packet. If the MAC address is found, the host or device no longer sends an ARP Request packet but directly sends the data packet to the MAC address. If the MAC address is not found, the host or device broadcasts an ARP Request packet for ARP address resolution.

The device ages and updates dynamic ARP entries to ensure that the capacity limit of the high-speed cache is not exceeded and the ARP entries in the cache are correct.

The aging parameters of a dynamic ARP entry include: aging time, number of aging probe attempts, and aging probe mode. After the aging time of a dynamic ARP entry expires, the device sends an aging probe packet (ARP Request packet) to detect whether the peer device is present. If the device receives an ARP Reply packet, it updates this dynamic ARP entry and the aging probe procedure ends. If the device does not receive an ARP Reply packet after the configured aging probe attempts, it deletes the dynamic ARP entry and the aging probe procedure ends.

The aging probe packet can be a unicast or broadcast packet.

The device deletes the corresponding dynamic ARP entries immediately when an interface goes Down.

ARP Packet Format

Figure 2-2 shows the format of an ARP Request or Reply packet.

Figure 2-2  Format of an ARP Request or Reply packet

The length of an ARP packet is 42 bytes. The first 14 bytes indicate the Ethernet frame header, and the last 28 bytes are the content of the ARP Request or Reply packet. Table 2-1 describes each field in an ARP packet.

Table 2-1  Description of each field in an ARP packet

Field

Length

Description

Ethernet destination MAC

48 bits

Ethernet destination MAC address.

When the device sends an ARP Request packet, the value of this field is the broadcast MAC address 0xffff-ffff-ffff.

Ethernet source MAC

48 bits

Ethernet source MAC address.

Frame type

16 bits

Data type.

The value of this field is 0x0806 in an ARP Request or Reply packet.

Hardware type

16 bits

Type of the hardware address.

The value of this field is 1 for an Ethernet.

Protocol type

16 bits

Type of the protocol address to be mapped on the sender.

The value of this field is 0x0800 for an IP address.

Hardware address length

8 bits

Hardware address length.

The value of this field in an ARP Request or Reply packet is 6.

Protocol address length

8 bits

Protocol address length.

The value of this field in an ARP Request or Reply packet is 4.

OP

16 bits

Operation type. The values are as follows:
  • 1: ARP Request packet
  • 2: ARP Reply packet

Source MAC

48 bits

Source MAC address.

Source IP

32 bits

Source IP address.

Destination MAC

48 bits

Destination MAC address.

When the device sends an ARP Request packet, the value of this field is 0x0000-0000-0000.

Destination IP

32 bits

Destination IP address.

Translation
Download
Updated: 2019-03-06

Document ID: EDOC1100069333

Views: 43393

Downloads: 202

Average rating:
This Document Applies to these Products

Related Version

Related Documents

Share
Previous Next