How to find IP address conflicts in Linux

  
 

You all know what an IP address is, right? They are assigned to devices on the network to represent them. They are distributed through the DHCP server and will change frequently. There are now two IP addresses. Dynamic ones change frequently (once a few days), while static ones are static like their names, meaning they don't change.

Sometimes this can cause some conflicts. When a dynamic IP is assigned and another network device already has the same IP. Or there are multiple DHCP servers that allocate IP on the same network subnet. If you have connectivity problems and assume it is due to IP conflicts, then you can use a tool called arp-scan to scan them.


This tool will send an ARP (Address Resolution Protocol) packet on the local network to collect the address. If there are multiple MAC addresses claiming to have the same IP address, there is a conflict here. To install arp-scan on Ubuntu or Debian, type:

$ sudo apt-get install arp-scan

For Fedora, CentOS or RedHat:

$ sudo yum Install arp-scan To detect IP conflicts, run the following command: 
$ sudo arp-scan –I eth0 -l output example: 
192.168.1.10 00:1b:a9:63:a2:4c BROTHER INDUSTRIES , LTD.192.168.1.30 00:1e:8f:58:ec:49 CANON INC.192.168.1.33 00:25:4b:1b:10:20 Apple, Inc192.168.1.37 10:9a:dd:55:d7 :95 Apple Inc192.168.1.38 20:c9:d0:27:8d:56 (Unknown)192.168.1.39 d4:85:64:4d:35:be Hewlett Packard192.168.1.39 00:0b:46:e4: 8e:6d Cisco (DUP: 2)192.168.1.40 90:2b:34:18:59:c0 (Unknown) 192.168.1.39 This IP conflicts because it appears twice. 
Article material comes from "Linux should be like this"
						
Copyright © Windows knowledge All Rights Reserved