1

LLDP is a link layer protocol used on switched at layer 2. Why do routers support it since routers work on layer 3?

4
  • 3
    Routers, too, have links to other devices. LLDP is for discovering what is on the other end of a link, not just for switches, but for any linked devices.
    – Ron Maupin
    Apr 15 '20 at 12:43
  • 2
    Routers also support layer-1 autonegotiation. The layers are a "stack" for a reason. Apr 15 '20 at 14:54
  • 2
    Besides all the other comments and answers, the concept of layers is used very liberally these days, they are not something that stems from the technical underpinnings of networking, it's just a concept humans came up with. So don't be surprised if what you've been taught does not correspond to the real world. Especially the closer you get to application layer.
    – JohnEye
    Apr 15 '20 at 15:51
  • Did any answer help you? If so, you should accept the answer so that the question doesn't keep popping up forever, looking for an answer. Alternatively, you can post and accept your own answer.
    – Ron Maupin
    Dec 17 '20 at 16:49
6

They work on layer 3, but to do so they also use lower layers, including layer 2. So LLDP can still be used and be useful to see what's connected to a specific port on the router.

1
  • 1
    I'd like to see a working router that supports layer 3 only, with no lower layers implemented!
    – Criggie
    Apr 15 '20 at 22:45
5

You could ask why Windows, or MacOS, or linux supports LLDP. When you list the LLDP neighbors on your switch, where do you think it got that information?

LLDP has two parts: a sender, and a receiver. Devices that don't have an LLDP sending process will have nothing shown on the switch (an LLDP receiver.) Likewise, that device will know nothing of the switch if it doesn't have a receiving process -- and the switch a sender.

1

LLDP is a neighbour discovery protocol. Often times you will want to see what is connected where, and this is as important on a router as any other network connected device.

1

LLDP is a "Link Layer Discovery Protocol". The protocol advertises itself on links, and populates its own database from other senders. Routers and or switches (or even your home PC) can be connected to each other, and exchange LLDP information.

A router understands "layer 2" as well as "layer 3". Routers, as you probably know, speaks arp, which is a "layer 2" protocol.

A router will send a layer 2 frame with destination multicast mac-address 01:80:c2:00:00:0e. If a switch or router supporting LLDP receives a frame on it's port, with this destination it will be handled by the CPU. It will then let the LLDP process handle that information.

A 802.1D compliant bridge should not forward these frames destined for the LLDP multicast mac-address. LLDP is a great protocol to troubleshoot when you need to see who is connected to what port etc.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.