CDP neighbour showing lowest IP address

Unanswered Question
Mar 8th, 2010
User Badges:

Is there a way to specify what IP address the s

witch will advertise in its cdp packets?


I have a switch which has two IP's


10.x.x.x  and 192.x.x.x.  I want the switch to advertise the 192 address but it only sends the 10 address in its advertisements.

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
Loading.
Collin Clark Mon, 03/08/2010 - 15:18
User Badges:
  • Purple, 4500 points or more

Try cdp source-interface [interface name]


Hope that helps.

Ganesh Hariharan Mon, 03/08/2010 - 23:01
User Badges:
  • Purple, 4500 points or more
  • Community Spotlight Award,

    Member's Choice, February 2016

Is there a way to specify what IP address the s

witch will advertise in its cdp packets?


I have a switch which has two IP's


10.x.x.x  and 192.x.x.x.  I want the switch to advertise the 192 address but it only sends the 10 address in its advertisements


Hi,


cdp source-interface


Use of this command ensures that Cisco Discovery Protocol packets use the IP address that has been previously assigned to an interface. Without this command, Cisco Discovery Protocol uses the IP address of the first available interface.


The conditions that an interface should satisfy to be the source interface are as follows:

•It should have an IP address.
•Its status should be UP.
•It should not be an IP unnumbered interface.


When Cisco Discovery Protocol is enabled and the Cisco Discovery Protocol source interface has not been configured, then Cisco Discovery Protocol uses the IP address of the first available interface.


The following example configures Cisco Discovery Protocol to use the IP address that has been assigned to interface loopback 1.

Router# configure terminal

Enter configuration commands, one per line.  End with CNTL/Z.

Router(config)# cdp source-interface loopback 1

Router(config)# exit


Hope to help !!


Ganesh.H

srego4 Tue, 03/09/2010 - 07:22
User Badges:

thks collin, ganesh, but that did not help me.  Looks like cisco may have taken out the comma

nd?


My ios is (C3560-ADVIPSERVICESK9-M), Version 12.2(40)SE   and I am trying it on a 3560 cat switch.  It does not appear to be a supported or unsupported command. I tried with /without the hyphen, also global & interface...no luck.


switch(config)#cdp source-interface vlan 210

                           ^

% Invalid input detected at '^' marker.


My interface also matches all the reqts -


•It should have an IP address.
•Its status should be UP.
•It should not be an IP unnumbered interface.

Collin Clark Tue, 03/09/2010 - 08:14
User Badges:
  • Purple, 4500 points or more

Ooops that's my fault, I thought it was a router. According to the documentation that is not a valid command. I also checked my switches and I don't see of any way to do it. Sorry.

bbosch4210 Tue, 12/17/2013 - 03:44
User Badges:

I still don't understand why the cdp source-interface hasn't been implemented on Catalyst fixed configuration switches.

I'm surely not the only one with multiple IP addresses on Access and Distribution switches.

Please Cisco, add the code.

Actions

This Discussion