W3cubDocs

/Ansible 2.9

eos_lldp_global – Manage Global Link Layer Discovery Protocol (LLDP) settings on Arista EOS devices

Synopsis

  • This module manages Global Link Layer Discovery Protocol (LLDP) settings on Arista EOS devices.

Parameters

Parameter Choices/Defaults Comments
config
dictionary
The provided global LLDP configuration.
holdtime
integer
Specifies the holdtime (in sec) to be sent in packets.
reinit
integer
Specifies the delay (in sec) for LLDP initialization on any interface.
timer
integer
Specifies the rate at which LLDP packets are sent (in sec).
tlv_select
dictionary
Specifies the LLDP TLVs to enable or disable.
link_aggregation
boolean
    Choices:
  • no
  • yes
Enable or disable link aggregation TLV.
management_address
boolean
    Choices:
  • no
  • yes
Enable or disable management address TLV.
max_frame_size
boolean
    Choices:
  • no
  • yes
Enable or disable maximum frame size TLV.
port_description
boolean
    Choices:
  • no
  • yes
Enable or disable port description TLV.
system_capabilities
boolean
    Choices:
  • no
  • yes
Enable or disable system capabilities TLV.
system_description
boolean
    Choices:
  • no
  • yes
Enable or disable system description TLV.
system_name
boolean
    Choices:
  • no
  • yes
Enable or disable system name TLV.
state
string
    Choices:
  • merged
  • replaced
  • deleted
The state of the configuration after module completion.

Notes

Note

  • Tested against Arista EOS 4.20.10M
  • This module works with connection network_cli. See the EOS Platform Options.

Examples

# Using merged
#
# ------------
# Before State
# ------------
#
# veos# show run | section lldp
# lldp timer 3000
# lldp holdtime 100
# lldp reinit 5
# no lldp tlv-select management-address
# no lldp tlv-select system-description

- name: Merge provided LLDP configuration with the existing configuration
  eos_lldp_global:
    config:
      holdtime: 100
      tlv_select:
        management_address: False
        port_description: False
        system_description: True
    state: merged

# -----------
# After state
# -----------
#
# veos# show run | section lldp
# lldp timer 3000
# lldp holdtime 100
# lldp reinit 5
# no lldp tlv-select management-address
# no lldp tlv-select port-description


# Using replaced
#
# ------------
# Before State
# ------------
#
# veos# show run | section lldp
# lldp timer 3000
# lldp holdtime 100
# lldp reinit 5
# no lldp tlv-select management-address
# no lldp tlv-select system-description

- name: Replace existing LLDP device configuration with provided configuration
  eos_lldp_global:
    config:
      holdtime: 100
      tlv_select:
        management_address: False
        port_description: False
        system_description: True
    state: replaced

# -----------
# After state
# -----------
#
# veos# show run | section lldp
# lldp holdtime 100
# no lldp tlv-select management-address
# no lldp tlv-select port-description


# Using deleted
#
# ------------
# Before State
# ------------
#
# veos# show run | section lldp
# lldp timer 3000
# lldp holdtime 100
# lldp reinit 5
# no lldp tlv-select management-address
# no lldp tlv-select system-description

- name: Delete existing LLDP configurations from the device
  eos_lldp_global:
    state: deleted

# -----------
# After state
# -----------
#
# veos# show run | section ^lldp

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key Returned Description
after
dictionary
when changed
The configuration as structured data after module completion.

Sample:
The configuration returned will always be in the same format of the parameters above.
before
dictionary
always
The configuration as structured data prior to module invocation.

Sample:
The configuration returned will always be in the same format of the parameters above.
commands
list
always
The set of commands pushed to the remote device.

Sample:
['lldp holdtime 100', 'no lldp timer', 'lldp tlv-select system-description']


Status

Red Hat Support

More information about Red Hat’s support of this module is available from this Red Hat Knowledge Base article.

Authors

  • Nathaniel Case (@Qalthos)

Hint

If you notice any issues in this documentation, you can edit this document to improve it.

© 2012–2018 Michael DeHaan
© 2018–2019 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/2.9/modules/eos_lldp_global_module.html