nixCraft Linux Forum

nixCraft

Linux / UNIX Tech Support Forum

Find Duplicate IP Address / Subnet with arping

This is a discussion on Find Duplicate IP Address / Subnet with arping within the Networking, Firewalls and Security forums, part of the Mastering Servers category; We run a Cisco-based network, with IP Phones and all that good stuff. The problem is that twice this month, ...


Go Back   nixCraft Linux Forum > Mastering Servers > Networking, Firewalls and Security

Linux answers from nixCraft.


Networking, Firewalls and Security No it's not a secret. Talk about firewalls and security issues.

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 03-08-2008, 04:56 AM
Junior Member
User
 
Join Date: Aug 2008
OS: PCLinuxOS
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
dougp23 is on a distinguished road
Default Find Duplicate IP Address / Subnet with arping

We run a Cisco-based network, with IP Phones and all that good stuff.

The problem is that twice this month, the phone system has entered a state of "one-way audio". If you call in, you can hear us, but we can't hear you. It is quite frustrating when it happens! Cisco says it is because somehow, someway, some device is trying to use of my router's or phone's IP address...

So I looked at arpping, but that only checks one IP. Obviously when this happens, we need to get the phones back up as quickly as possible...this is usually done with a reboot of the main router.

Is there a way to use arpping that would check all IPs within one subnet?

Thanks.
Reply With Quote
  #2 (permalink)  
Old 03-08-2008, 01:20 PM
nixcraft's Avatar
Never say die
User
 
Join Date: Jan 2005
Location: BIOS
OS: RHEL
Scripting language: Bash and Python
Posts: 2,710
Thanks: 11
Thanked 245 Times in 184 Posts
Rep Power: 10
nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute
Default

Noop, but you can use shell script or for loop. For example, 192.168.1.0/24 subnet can be tested using following code:

Code:
for i in $(seq 1 254); 
do 
echo "arping -q -D -I eth0 -c 2 192.168.1.${i}"; [ $? -ne 0 ] && echo "192.168.1.${i} duplicate"; 
done
__________________
Vivek Gite
Linux Evangelist
Be proud RHEL user, and let the world know about your enterprise choices! Join RedHat user group.
Always use CODE tags for posting system output and commands!
Do you run a Linux? Let's face it, you need help
Reply With Quote
  #3 (permalink)  
Old 03-08-2008, 07:20 PM
Junior Member
User
 
Join Date: Aug 2008
OS: PCLinuxOS
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
dougp23 is on a distinguished road
Default

Thanks. That looks perfect!!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads

Thread Thread Starter Forum Replies Last Post
Validate IP Address devxtech Shell scripting 5 21-11-2007 11:02 PM
log mac address in squid log sunlinux Networking, Firewalls and Security 1 04-09-2007 02:32 AM
OpenBSD get or display network card IP address Subnet mask information rockdalinux Getting started tutorials 0 15-06-2007 10:06 PM
list of IPs used in a subnet raghuram Networking, Firewalls and Security 1 21-02-2007 09:07 AM
Linux find subnet mask commands chiku Linux software 1 06-12-2006 02:28 AM


All times are GMT +5.5. The time now is 06:57 PM.


Powered by vBulletin® Version 3.8.5 - Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2
©2005-2010 nixCraft. All rights reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38