Linux下检查IP冲突

今天发现一个VPS服务时断时续,于是排错….

使用arping 检查是否有IP冲突,发现有两个MAC响应同一IP地址

arping x.x.x.120 -I eth0
ARPING x.x.x.120 from x.x.x.206 eth0
Unicast reply from x.x.x.120 [00:16:3E:E3:DE:8D] 0.932ms
Unicast reply from x.x.x.120 [00:16:3E:2C:07:3F] 1.023ms
Unicast reply from x.x.x.120 [00:16:3E:2C:07:3F] 0.739ms
Unicast reply from x.x.x.120 [00:16:3E:2C:07:3F] 0.790ms

使用ifconfig确认主机MAC 地址

eth0: flags=4163 mtu 1500
inet x.x.x.120 netmask 255.255.255.0 broadcast x.x.x.255
inet6 fe80::216:3eff:fe2c:73f prefixlen 64 scopeid 0x20
ether 00:16:3e:2c:07:3f txqueuelen 1000 (Ethernet)
RX packets 143489 bytes 9333858 (8.9 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 3625 bytes 662568 (647.0 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0