arping
arping sends ARP and/or ICMP requests to a specified host and displays the replies. The host can be identified by hostname, IP address, or MAC address.
Description
The arping utility is designed to send IP and/or ARP pings to a given host, displaying the replies it receives. This tool is particularly useful for network diagnostics, verifying host reachability at the link layer, and mapping IP to MAC address relationships without relying on higher-layer protocols.
Common use cases include checking if a host is alive on the local network, discovering MAC addresses for devices on the same subnet, or troubleshooting ARP resolution issues. It supports specifying the target by hostname, IP, or MAC address, making it versatile for various network probing scenarios.
arping operates by crafting and transmitting ARP requests or ICMP echo requests directly, bypassing standard routing behaviors. This allows for precise control over source addressing and interface binding, essential in environments where interfaces are not yet fully configured or for targeted link-layer communication.
How It Works
arping sends ARP requests (for MAC resolution) and/or ICMP echo requests (IP pings) to the target host, capturing and displaying replies. It binds to a specific interface if specified, supports custom source IP (-S), target IP (-T), source/target MAC (-s/-t), and handles VLAN tagging (-V) or priority (-Q). Replies are filtered and counted based on options like -c for packet count or -A for address matching.
Installation
sudo apt install arpingFlags
Examples
arping <host/ip/MAC>arping -0 <host/ip>arping -a <host/ip>arping -A <host/ip>arping -i <interface> <host/ip>arping -c <count> <host/ip>arping -S <host/ip> <target>