PARALLAX

eos_lldp_global

Configure global LLDP parameters on Arista EOS

Collection: arista.eos

Full Name: arista.eos.eos_lldp_global

Controller module — runs on the local controller, not on remote hosts.

Synopsis

Configure global LLDP parameters on Arista EOS

Parameters

NameTypeRequiredDefaultDescription
configdict
running_configstr
statestrmerged

Example

yaml
# 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
  arista.eos.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
  arista.eos.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
  arista.eos.eos_lldp_global:
    state: deleted

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

# Using rendered:

- name: Use Rendered to convert the structured data to native config
  arista.eos.eos_lldp_global:
    config:
      holdtime: 100
      tlv_select:
        management_address: false
        port_description: false
        system_description: true
    state: rendered

# -----------
# Output
# -----------
#
# rendered:
#   - "lldp holdtime 100"
#   - "no lldp tlv-select management-address"
#   - "no lldp tlv-select port-description"

# Using parsed

# parsed.cfg

# lldp timer 3000
# lldp holdtime 100
# lldp reinit 5
# no lldp tlv-select management-address
# no lldp tlv-select system-description

- name: Use parsed to convert native configs to structured data
  arista.eos.lldp_global:
    running_config: "{{ lookup('file', 'parsed.cfg') }}"
    state: parsed

# -----------
# Output
# -----------

#    parsed:
#      holdtime: 100
#      timer 3000
#      reinit 5
#      tlv_select:
#        management_address: False
#        port_description: False
#        system_description: True

# Using gathered:
# native config:
# lldp timer 3000
# lldp holdtime 100
# lldp reinit 5
# no lldp tlv-select management-address
# no lldp tlv-select system-description


- name: Gather lldp_global facts from the device
  arista.eos.lldp_global:
    state: gathered

# -----------
# Output
# -----------

#    gathered:
#      holdtime: 100
#      timer 3000
#      reinit 5
#      tlv_select:
#        management_address: False
#        port_description: False
#        system_description: True
Search
    ↑ ↓ move↵ openesc close