LLDP

The Link Layer Discovery Protocol (IEEE 802.1AB) is used to exchange information between neighbor systems on each link. The exchanged LLDP PDUs include TLVs such as:

  • Chassis ID (e.g. MAC address).

  • Port ID (character string).

  • Time To Live (for message timeout purposes).

  • Management Address (e.g. IPv4 address).

  • Organizationally Specific TLVs, for example frame preemption capabilities.

The VelocitySP LLDP implementation can store information for one neighbor per switch port.

The following examples operate on the first port ('1') of the switch.

1. LLDP Port Configuration

Rx and Tx of LLDP messages can be enabled per port, using DMAC 01-80-C2-00-00-0E.

IPATCH request message:

- ? "/ieee802-dot1ab-lldp:lldp/\
     port[name='1'][dest-mac-address='01-80-C2-00-00-0E']/admin-status"
  : tx-and-rx

The configuration of the first port is retrieved as shown below.

FETCH request message:

- "/ieee802-dot1ab-lldp:lldp/\
   port[name='1'][dest-mac-address='01-80-C2-00-00-0E']/admin-status"

FETCH response message:

- ? "/ieee802-dot1ab-lldp:lldp/port/admin-status"
  : tx-and-rx

2. LLDP Rx Processing

Remote data received on the port is retrieved as shown below.

FETCH request message:

- "/ieee802-dot1ab-lldp:lldp/\
   port[name='1'][dest-mac-address='01-80-C2-00-00-0E']/remote-systems-data"

FETCH response message:

- ? "/ieee802-dot1ab-lldp:lldp/port/remote-systems-data"
  : - time-mark: 1234
      remote-index: 1
      chassis-id-subtype: mac-address
      chassis-id: 00-11-22-33-44-55
      port-id-subtype: interface-name
      port-id: '2'
      port-desc: ''
      system-name: ''
      system-description: ''
      management-address: []
      remote-org-defined-info: []

3. LLDP Tx Processing

When Tx is enabled on a port, LLDP messages including the TLVs listed above are sent every 30 seconds. If the IP address is changed, a number of transmissions are done every second.

4. LLDP Counters

LLDP counters for a port are retrieved as shown below.

- "/ieee802-dot1ab-lldp:lldp/\
   port[name='1'][dest-mac-address='01-80-C2-00-00-0E']/tx-statistics"

- "/ieee802-dot1ab-lldp:lldp/\
   port[name='1'][dest-mac-address='01-80-C2-00-00-0E']/rx-statistics"

FETCH response message:

- ? "/ieee802-dot1ab-lldp:lldp/port/tx-statistics"
  : total-frames: 1


- ? "/ieee802-dot1ab-lldp:lldp/port/rx-statistics"
  : total-discarded-frames: 0
    error-frames: 0
    total-frames: 1
    total-discarded-tlvs: 0
    total-unrecognized-tlvs: 0

5. LLDP Frame Preemption Negotiation

Frame preemption is negotiated via LLDP organizationally specific TLVs. The negotiation is done for each data direction on the switch port:

  • Data Rx:

    • LLDP Tx messages always announce Rx frame preemption capability.

    • The remote switch may then use frame preemption when sending data.

  • Data Tx:

    • LLDP Rx messages indicate whether the peer supports Rx frame preemption.

    • The local switch may then use frame preemption when sending data.

Frame preemption may be enabled per Tx queue on a port. By default, all queues are set up for express operation, disabling frame preemption. A number of queues, starting with queue 0 (low priority) may be set up as preemptable.

The first queue on the port is set up as preemptable as shown below.

IPATCH request message:

- ? "/ietf-interfaces:interfaces/interface[name='1']/\
     ieee802-dot1q-bridge:bridge-port/\
     ieee802-dot1q-preemption-bridge:frame-preemption-parameters/\
     frame-preemption-status-table"
  : priority0: preemptable

The frame preemption configuration is retrieved as shown below.

FETCH request message:

- "/ietf-interfaces:interfaces/interface[name='1']/\
   ieee802-dot1q-bridge:bridge-port/\
   ieee802-dot1q-preemption-bridge:frame-preemption-parameters/\
   frame-preemption-status-table"

FETCH response message:

- ? "/ietf-interfaces:interfaces/interface/ieee802-dot1q-bridge:bridge-port/\
     ieee802-dot1q-preemption-bridge:frame-preemption-parameters/\
     frame-preemption-status-table"
  : priority0: preemptable
    priority1: express
    priority2: express
    priority3: express
    priority4: express
    priority5: express
    priority6: express
    priority7: express