Gratuitous ARP
Gratuitous ARP allows a device to send an ARP Request packet that carries its own IP address as the destination IP address.
Gratuitous ARP has the following functions:
Checks for IP address conflicts. When the protocol state of a device interface changes to Up, the device sends gratuitous ARP packets. Normally, the device should not receive an ARP reply. If the device receives an ARP reply, another device is using the same IP address. When detecting an IP address conflict, the device periodically broadcasts gratuitous ARP Reply packets until the conflict is removed.
Advertises a new MAC address. If the MAC address of a device changes because its network adapter is replaced, the device sends a gratuitous ARP packet to notify all devices of the change before the ARP entry is aged out.
Notifies other devices of an active/standby switchover in a VRRP group: After an active/standby switchover, the master device broadcasts a gratuitous ARP packet in the VRRP group to notify other devices of the switchover.
When a device receives a gratuitous ARP packet, it checks whether the source IP address of the packet is the same as the local IP address:
- If the IP addresses are the same, the device periodically broadcasts a gratuitous ARP Reply packet to notify the address conflict until the conflict is removed.
- If the IP addresses are different, the device updates the ARP entry according to the received gratuitous ARP packet only when it receives the packet on the VLANIF interface and has the dynamic ARP entry mapping the source IP address of the packet. In other cases, the device does not update the ARP entry.