Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 2 additions & 19 deletions dockers/docker-lldp/lldpd.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -19,24 +19,7 @@ configure ports eth0 lldp portidsubtype local {{ mgmt_if.port_name }}
configure system ip management pattern {{ mgmt_if.ipv4 }}
{% endif %}
configure system hostname {{ DEVICE_METADATA['localhost']['hostname'] }}
{# Configure port ID subtype for front-panel ports at startup.
Without this, lldpd uses MAC address as default Port ID. When lldpd
auto-resumes after config processing, the first LLDP frame would carry
MAC-based Port IDs. Peers see a transient MSAP change when lldpmgrd
later reconfigures portidsubtype, causing unnecessary neighbor flaps.
Special ports (inband/recirculation/backplane) are excluded to match
lldpmgrd behavior which skips these port types. #}
{% if PORT %}
{% for port_name in PORT|sort %}
{% if not port_name.startswith('Ethernet-IB') and not port_name.startswith('Ethernet-Rec') and not port_name.startswith('Ethernet-BP') %}
{% set port_alias = PORT[port_name].alias|default('') %}
{% if port_alias %}
configure ports {{ port_name }} lldp portidsubtype local {{ port_alias }}
{% else %}
configure ports {{ port_name }} lldp portidsubtype local {{ port_name }}
{% endif %}
{% endif %}
{% endfor %}
{% endif %}
{# Use ifname globally to avoid MAC-as-Port-ID; lldpmgrd sets alias per port later. #}
configure lldp portidsubtype ifname
{# pause lldpd operations until all interfaces are well configured, resume command will run in lldpmgrd #}
pause
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
configure ports eth0 lldp portidsubtype local eth0
configure system ip management pattern 10.0.0.100
configure system hostname switch-t0
configure lldp portidsubtype ifname
pause
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
configure system hostname switch-t0
configure lldp portidsubtype ifname
pause
Loading