How Linux uses the arping command to detect IP address conflicts

  
                

Each host on each network has an IP address. If the IP address conflicts, the network connection will not be connected or dropped. Then how to query the IP address conflict? The following small series will tell you how Linux uses the arping command to detect IP address conflicts. Let's take a look at it.

In the example below: arping -c 3 -f -D * * * * (* * * * IP address...) returns

192.168.2.222... Empty, indicating that this IP address is not occupied by the LAN.

192.168.2.106 returns 1, indicating that this IP address is already occupied, and receiving a reply can see the mac address of the terminal bound to the IP.

Arping Command Details:

Usage: arping [-fqbDUAV] [-c count] [-w timeout] [-I device] [-s source] ip address

Parameters:

-A ARP reply mode, update neighbors

-b keep broadcast

-D copy address detection mode

-f get the first Exit with a reply

-q Do not display warning message

-U Active ARP mode, update neighbor

-c "Number of packets" Packet sent Number of

-w "Timeout" Setting the timeout period

-I "Network Card" Using the specified Ethernet device, by default eth0

-s specifies the source IP address

-h Display help information

-V Display version information

The above is how Linux uses the arping command to detect ip address conflicts. This article introduces Commands to detect ip conflicts, and other tools to detect.

Copyright © Windows knowledge All Rights Reserved