cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
42936
Views
24
Helpful
6
Replies

How does a Cisco Router/Switch detect duplicate IP address?

Talha Ansari
Level 1
Level 1

Hi,

I wish to know how does a Cisco router/switch detect an IPv4 address conflict?

Regards,

Talha

1 Accepted Solution

Accepted Solutions

Hi,

I checked the output of this command but it doesnt display anything... although I m pinging the next end serial ports ip but no entries... ARP is not bound to ethernet .... rite? correct me if wrong...!

I'm gonna correct you then    Serial interfaces withHDLC or PPP, HDLC being the default encapsulation on Cisco routers are point-to-point so there is no need for a mechanism mapping L3 to L2 and on Frame-Relay the mechanism is Inverse ARP which maps a particular DLCI to a remote L3 address.

I gave the command "no ip gratuitous-arp" from the config mode and applied same ip addresses but yet the router sent the gratuitous arp requests and detected duplicate ip addresses... strange..!!

This is surely because this command has got nothing to do with duplicate address detection:

http://www.cisco.com/en/US/docs/ios/12_3/ipaddr/command/reference/ip1_l1g.html#wp1079158

This is the command you want to test: http://www.cisco.com/en/US/docs/ios/ipaddr/command/reference/iad_arp.html#wp1043032

Regards.

Alain.

Don't forget to rate helpful posts.

View solution in original post

6 Replies 6

Latchum Naidu
VIP Alumni
VIP Alumni

Hi,

Router does not detect conflict in Router IP address and DHCP Start/End Address.
The conflict IP address popup on the computer if that have same IP in the network.

Hope this clear you.

Please click on the correct answer if this answered your question.
Regards,
Naidu.

hi naidu,

i would disagree. router does detect duplicate IP addresses on its ARP table. i previously encountered this on one of our routers. a host was detected using the same IP address assigned to VLAN 1 gateway, 192.168.1.1.

Jul  7 2010 13:29:55 SGT: %IP-4-DUPADDR: Duplicate address 192.168.1.1 on Vlan1, sourced by 687f.7454.9439

RouterW#sh ip arp
Protocol  Address          Age (min)  Hardware Addr   Type   Interface
Internet  192.168.1.1             -   001d.7088.56ca  ARPA   Vlan1
Internet  192.168.1.2             0   0021.5e4d.854d  ARPA   Vlan1
Internet  192.168.1.3           232   0021.5e4d.d335  ARPA   Vlan1

I disagree... I had seen routers detecting ip address conflict in production environment.

Anyway fortunately I got lucky to lay my hands on two routers after I started this thread. I connected it back to back with ethernet cross cable. Also configured same IP address on both the router's interfaces and sure enough it quickly threw the syslog message as..

%IP-4-DUPADDR: Duplicate address 2.2.2.1 on Ethernet0/0, sourced by xxxx.xxxx.xxxx

Later I administratively shutdown the interface and did a sniffer trace by putting a hub in between... in which I got the answer.

As soon as we configure an IP address on the router's interface it sends a gratutous ARP request. This is a special request in which the router sends an ARP request with its own IP in the target field. IF and only IF it receives a reply to this request then it understands that someone else in the network is using the same IP so there's a conflict. Ideally the router should not receieve any reply for this ARP request.

Just a small edit here.. after doing this test I gave the command "no ip gratuitous-arp" from the config mode and applied same ip addresses but yet the router sent the gratuitous arp requests and detected duplicate ip addresses... strange..!!

But I must mention that I did not notice any IP address conflict if I configure same IP addresses on serial interfaces of two routers connected back to back. May be Gratutious ARP doesnt work on Serial...

Can anyone shed any light on the output of this command :

show ip arp serial0/0

I checked the output of this command but it doesnt display anything... although I m pinging the next end serial ports ip but no entries... ARP is not bound to ethernet .... rite? correct me if wrong...!

Regards,

Talha

Message was edited by: Talha Ansari

Hi,

I checked the output of this command but it doesnt display anything... although I m pinging the next end serial ports ip but no entries... ARP is not bound to ethernet .... rite? correct me if wrong...!

I'm gonna correct you then    Serial interfaces withHDLC or PPP, HDLC being the default encapsulation on Cisco routers are point-to-point so there is no need for a mechanism mapping L3 to L2 and on Frame-Relay the mechanism is Inverse ARP which maps a particular DLCI to a remote L3 address.

I gave the command "no ip gratuitous-arp" from the config mode and applied same ip addresses but yet the router sent the gratuitous arp requests and detected duplicate ip addresses... strange..!!

This is surely because this command has got nothing to do with duplicate address detection:

http://www.cisco.com/en/US/docs/ios/12_3/ipaddr/command/reference/ip1_l1g.html#wp1079158

This is the command you want to test: http://www.cisco.com/en/US/docs/ios/ipaddr/command/reference/iad_arp.html#wp1043032

Regards.

Alain.

Don't forget to rate helpful posts.

Hi Alain,

Thanks for your response...

Just adding a document which I came across today for reference pupose..

http://tools.ietf.org/html/rfc5227

I was too lazy to browse the RFCs...

Regards,

Talha

smartd_03
Level 1
Level 1

A router/switch cares only about local or on-link duplication in most cases. However BGP and LDP hace their own specifics.

In general terms a router/switch doesnt care about anything unless it will impair its own operations.