Technical Documentation

Configuring the JUNOS Software ARP Learning and Aging Options for Mapping IPv4 Network Addresses to MAC Addresses

The Address Resolution Protocol (ARP) is a protocol used by IPv4 to map IP network addresses to MAC addresses. This topic describes how to set passive ARP learning and ARP aging options for network devices. (A switch operates as a virtual router.)

Tasks for configuring ARP learning and aging are:

  1. Configuring Passive ARP Learning for Backup VRRP Routers
  2. Adjusting the ARP Aging Timer

Configuring Passive ARP Learning for Backup VRRP Routers

By default, the backup VRRP router drops ARP requests for the VRRP-IP to VRRP-MAC address translation. The backup router does not learn the ARP (IP-to-MAC address) mappings for the hosts sending the requests. When it detects a failure of the master router and becomes the new master, the backup router must learn all the entries that were present in the ARP cache of the master router. In environments with many directly attached hosts, such as metro Ethernet environments (this type of environment does not pertain to switches), the number of ARP entries to learn can be high. This can cause a significant transition delay, during which traffic transmitted to some of the hosts might be dropped.

Passive ARP learning enables the ARP cache in the backup router to hold approximately the same contents as the ARP cache in the master router, thus preventing the problem of learning ARP entries in a burst. To enable passive ARP learning, include the passive-learning statement at the [edit system arp] hierarchy level:

[edit system arp]passive-learning;

We recommend setting passive learning on both the backup and master VRRP routers. This prevents the need to intervene manually when the master router becomes the backup router. While a router is operating as the master, the passive learning configuration has no operational impact. The configuration takes effect only when the router is operating as a backup router.

Adjusting the ARP Aging Timer

By default, the ARP aging timer is set at 20 minutes. In environments with many directly attached hosts, such as metro Ethernet environments (this type of environment does not pertain to switches), increasing the amount of time between ARP updates by configuring the ARP aging timer can improve performance. However, in some scenarios, it might be desirable to lower the ARP aging timer value to prevent the flooding of traffic and improve performance.

The range of the ARP aging timer is from 1 through 240 minutes.

To configure a system-wide ARP aging timer, include the aging-timer statement at the [edit system arp] hierarchy level:

[edit system arp]aging-timer minutes;

You can also configure the ARP aging timer for each logical interface of family type inet. To configure the ARP aging timer at the logical interface level, specify the timer value in minutes at the [edit system arp aging-timer interface interface-name] hierarchy level:

[edit system arp aging-timer interface interface-name]aging-timer aging-timer-minutes;

Note: If the aging timer value is configured both at the system and the logical interface levels, the value configured at the logical interface level takes precedence for the specific logical interface.

The timer value you configure takes effect as ARP entries expire. Each refreshed ARP entry receives the new timer value. The new timer value does not apply to ARP entries that exist at the time you commit the configuration.


Published: 2010-04-26