I tested in Packet tracer and I don't see that CDP uses an IP address of another interface for the CDP neighbor, it just leaves it empty but still works as usual. I don't see how you guys say it is B, but the simulation on PT says otherwise. I'm going with C.
According to 4aynick who tested it through GNS3 and the CISCO documentation, answer B is correct, perhaps in Packet Tracer there is indeed this limitation, but it should include the ip address of another interface in an example of a #show cdp neighbors detail command, which does not happen leaving the ip address field empty (as I tested), but in GNS3 it manages to acquire the ip address of another interface (as mentioned by 4aynick), as well as also mentions the CISCO documentation, in this case, taking this into account limitation of Packet Tracer, I agree with answer B “updates the ip address of another interface”.
https://www.cisco.com/c/en/us/td/docs/ios-xml/ios/cdp/configuration/15-mt/cdp-15-mt-book/nm-cdp-discover.html#:~:text=Restrictions%20for%20Using%20Cisco%20Discovery%20Protocol,-Cisco%20Discovery%20Protocol&text=Cisco%20Discovery%20Protocol%20is%20not,the%20non%2DIP%20address%20interface
unfortunately this is what happens, according to the cisco documentation (and GNS3 according to 4aynick), so we have to pay attention to the repeated IP addresses in the CDP "show" outputs.
Dude, I got confused with you here. You said Packet Tracer isn't reliable and therefore you disagree with his reasoning..... But then you agree with his answer. Lol wtf?
The Right answer is B. If a neighbor has no IP address on an interface enabled with Cisco Discovery Protocol, the IP address of another interface will be updated as IP address for the non-IP address interface.
Reference: https://www.cisco.com/c/en/us/td/docs/ios-xml/ios/cdp/configuration/15-mt/cdp-15-mt-book/nm-cdp-discover.html
What is the another interface? The C is correct. CDP does not need IPs to works normally
https://learningnetwork.cisco.com/s/question/0D53i00000Kt3Mp/how-does-cdp-work-without-l3-addresses
Read his link!
"If a neighbor has no IP address on an interface enabled with Cisco Discovery Protocol, the IP address of another interface will be updated as IP address for the non-IP address interface."
B is correct, as stated by Gere.
ChatGPT voted C
Me:
"Won't it show the IP address of another interface of the device?"
ChatGPT:
"Yes, you're correct! If a device has multiple interfaces and one of those interfaces has an IP address configured, CDP will display the IP address of a different interface if it’s available."
CDP works on layer 2. It means there is no require for an IP address of the neighbor device to collect its information. The neigbors devices are directly connected, they can learn each other's MAC address.
CDP is a Layer 2 protocol, which means it operates independently of Layer 3 (IP) addresses. As a result, CDP can still exchange information such as device identifiers, port identifiers, capabilities, and platform information with neighboring devices, even if the interface does not have an IP address configured.
However, without an IP address on the interface, CDP cannot provide IP address information for that neighbor because there is no IP address to report. Despite this, other information can still be exchanged and displayed through CDP.
Definitely C.
Verified on real Cisco hardware - a L3 switch and a router.
SW1
port #5: 10.0.0.1
R1
port #1: no ip addr
port #3: 172.16.1.1
SW1#5 connected to R1 #1
SW1# show cdp neighbors detail
Information about R1 is displayed, without any IP address
Particularly, 172.16.1.1 is not displayed at all.
R1#show cdp neighbors detail
It displays SW1 information with IP address 10.0.0.1
Swapped the Switch and the Router, and tested again.
Result is the same. Still C is correct.
SW1
port #5 10.0.0.1
port #6 no ip
R1
port #1 172.16.1.1
SW1 #6 connected to R1 #1
Still, the command [show cdp neighbors detail] from R1 does NOT show SW1's IP address.
The Cisco article quoted by some people is either incorrect or talking about some situation
C. CDP uses the IP address of another interface for that neighbor.
If a neighbor has no IP address on an interface enabled with Cisco Discovery Protocol, the IP address of another interface will be updated as IP address for the non-IP address interface.
It is not B. Why majority picked B is beyond my networking comprehension. Cdp is a layer 2 protocol but can get ip info of an interface IF it has. Not picking the IP of another interface. Why would it even do that? To achieve what? This one i avoid the majority vote
Since there is no way to delete my previous comment, I withdraw my comment. This is directly from cisco site.
“Restrictions” for Using Cisco Discovery Protocol
Cisco Discovery Protocol functions only on Cisco devices.
Cisco Discovery Protocol is not supported on Frame Relay multipoint subinterfaces.
**If a neighbor has no IP address on an interface enabled with Cisco Discovery Protocol, the IP address of another interface will be updated as IP address for the non-IP address interface.***
So it’s a restriction of cdp. Correct answer is B
If a neighbor has no IP address on an interface enabled with Cisco Discovery Protocol, the IP address of another interface will be updated as IP address for the non-IP address interface.
https://www.cisco.com/c/en/us/td/docs/ios-xml/ios/cdp/configuration/15-mt/cdp-15-mt-book/nm-cdp-discover.html#GUID-3C4F2637-ED36-4EC0-9CD5-B73C0CF9DBEC
Restrictions for Using Cisco Discovery Protocol
Cisco Discovery Protocol functions only on Cisco devices.
Cisco Discovery Protocol is not supported on Frame Relay multipoint subinterfaces.
If a neighbor has no IP address on an interface enabled with Cisco Discovery Protocol, the IP address of another interface will be updated as IP address for the non-IP address interface.
https://www.cisco.com/c/en/us/td/docs/ios-xml/ios/cdp/configuration/15-mt/cdp-15-mt-book/nm-cdp-discover.html
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
ddban
Highly Voted 3 years, 8 months agodropspablo
1 year, 5 months agoNicocisco
2 years, 11 months agoBhrino
1 year, 8 months agoDunedrifter
1 year, 6 months agodropspablo
1 year, 5 months agoBrocolee
1 year, 6 months agoGere
Highly Voted 3 years, 11 months agoAval0n1
3 years, 10 months agooooMooo
3 years, 8 months agoNicocisco
2 years, 11 months agoXdarkrai
Most Recent 3 weeks agojojolabubu
1 month, 2 weeks agokhamva
1 month, 4 weeks agoSupernovaBoom
2 months agoSimrankoor
2 months, 3 weeks agoJoshua25
3 months agoJoshua25
3 months agoMr0Robot
3 months agoMicroDiff
3 months, 1 week agocybercerberes
6 months, 2 weeks agotumajay
7 months agotumajay
7 months agoKT_Yu
7 months, 1 week agoSarooor
8 months, 1 week ago593554d
8 months, 1 week ago[Removed]
10 months, 2 weeks ago4ffc2ad
10 months, 3 weeks ago