LinuxCommandLibrary

arp

TLDR

Display ARP table

$ arp -a
copy
Display in numeric format
$ arp -n
copy
Add static ARP entry
$ sudo arp -s [192.168.1.1] [00:11:22:33:44:55]
copy
Delete ARP entry
$ sudo arp -d [192.168.1.1]
copy
Show entries for specific interface
$ arp -i [eth0]
copy

SYNOPSIS

arp [-a] [-d address] [-s address hwaddr] [-i interface] [options_]

DESCRIPTION

arp manipulates the system's ARP (Address Resolution Protocol) cache. ARP maps IP addresses to MAC (hardware) addresses on a local network segment.
The ARP table is built dynamically as the system communicates, but entries can be manually added, deleted, or viewed for network troubleshooting.

PARAMETERS

-a

Display all entries (BSD style)
-n, --numeric
Show numeric addresses (no DNS lookup)
-d address
Delete entry for address
-s address hwaddr_
Add static entry
-i interface
Limit to specific interface
-D
Use device's hardware address
-v, --verbose
Verbose output
-H type, --hw-type type
Hardware type (ether, arcnet, etc.)

CAVEATS

The arp command is deprecated in favor of ip neigh on modern Linux. Static entries don't survive reboots by default. ARP is only used for IPv4; IPv6 uses Neighbor Discovery.

HISTORY

arp has been part of Unix networking since the early days of TCP/IP in the 1980s. On Linux, it's part of net-tools, which is being replaced by iproute2.

SEE ALSO

Copied to clipboard