Introduction

In the event of network modifications, it is possible for nodes within your network to encounter difficulties when attempting to establish connections with hosts outside of their respective subnets.

This situation often arises when the IP address of the default gateway is reassigned to a new router, while the previous device remains operational for various reasons. Hosts that had previously communicated with the old router are familiar with its MAC address and associate the old IP with that particular MAC. However, the IP address now belongs to a different node, resulting in connectivity issues for these network hosts when attempting to communicate outside of their subnet.

To resolve this issue promptly, clearing the ARP cache on these hosts can be an option. By doing so, they will be able to query and acquire the MAC address of the new router, thereby restoring proper connectivity.

Flush ARP cache in Windows

# View the ARP table
arp -a 
# Delete a single entry (1.1.1.1 in this example)
arp -d 1.1.1.1
# Flush the whole ARP cache
arp -d *
# *** or ***
arp -a -d

Flush the ARP cache on Linux/Unix System.

# View the ARP cache
arp -n 
# Delete a single entry (1.1.1.1 here)
arp -d 1.1.1.1
# Flush the whole cache
ip -s neigh flush all