Check if an IP Is Taken on Your LAN with arping
Use arping to detect IP address conflicts at the ARP layer, which works even when firewalls block ICMP ping.
01Command
$ sudo arping -D -I eth0 192.168.1.5002What it does
arping works at layer 2: it asks 'who has this IP?' on the local segment and waits for an ARP reply, so it succeeds even when ICMP ping is blocked by a host firewall. The -D flag puts it in duplicate address detection mode, the same idea RFC 5227 uses when a host claims an address. Exit status is non-zero when a conflict is found, which makes it easy to use in scripts that pick a free static IP.
03Risk
04Undo
✓No undo needed — this command does not change persistent state.
05Sources
- arping(8) — send ARP REQUEST to a neighbour hostEvidence: Page documents -U/unsolicited ARP mode and duplicate address detection; the string 'conflict' and the '-D' option appear in the man page text, confirming -D (duplicate address detection mode).
- arping(8) — Linux man page (iputils)Evidence: Man page text contains 'arping' usage with -I to select the interface and describes unsolicited ARP mode; confirms arping sends ARP REQUEST at layer 2.
Last verified: 2026-09-19 · Category: Network
06Related solutions
The classic forgotten-syntax command: `traceroute` shows every router between you and a destination plus the round-trip time of probes to each hop.
Show every TCP and UDP socket in listening state with the owning process name and PID — the modern replacement for netstat.
Send a HEAD request to any URL and print the status line, server, content type, caching, and redirect headers.