June 2017
Intermediate to advanced
446 pages
10h 10m
English
We are now ready to incorporate this new parser script back into our playbook. We can now add the additional task of rendering the output with graph generation in cisco_discover_lldp.yml:
- name: Execute Python script to render output command: ./cisco_graph_lldp.py
The playbook can now be scheduled to run regularly via cron or other means. It will automatically query the devices for LLDP neighbors and construct the graph, and the graph will represent the current topology as known by the routers.
We can test this by shutting down the Gi0/1 and Go0/2 interfaces on r6-edge when the LLDP neighbor passes the hold time and disappears from the LLDP table:
r6-edge#sh lldp neighbors...Device ID Local Intf Hold-time Capability Port ...
Read now
Unlock full access