Giter Site home page Giter Site logo

ntc-templates's Introduction

NTC Templates



Overview

Repository of TextFSM Templates for Network Devices, and Python wrapper for TextFSM's CliTable. TextFSM is a tool to help make parsing cli commands more manageable.

Documentation

Full web-based HTML documentation for this library can be found over on the NTC Templates Docs website:

Contributing to the Docs

All the Markdown source for the library documentation can be found under the docs folder in this repository. For simple edits, a Markdown capable editor is sufficient - clone the repository and edit away.

If you need to view the fully generated documentation site, you can build it with mkdocs. A container hosting the docs will be started using the invoke commands (details in the Development Environment Guide) on http://localhost:8001. As your changes are saved, the live docs will be automatically reloaded.

Any PRs with fixes or improvements are very welcome!

Questions

For any questions or comments, please check the FAQ first. Feel free to also swing by the Network to Code Slack (channel #networktocode), sign up here if you don't have an account.

ntc-templates's People

Contributors

amb1s1 avatar dainok avatar diepes avatar elavaud avatar ericdost avatar evilmonkey19 avatar fragmentedpacket avatar ggabriele avatar guillaume-mbali avatar h4ndzdatm0ld avatar itdependsnetworks avatar jamiecaesar avatar jedelman8 avatar jmcgill298 avatar jvanderaa avatar k-ribot avatar kadecole avatar lamiskin avatar mjbear avatar netmanchris avatar nsnelson402 avatar ogenstad avatar pavloskliarenko avatar pbe9216 avatar pszulczewski avatar sandeepsr avatar sjhloco avatar that1guy15 avatar tom0010 avatar yakuza-ua avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ntc-templates's Issues

Build is failing in Travis CI

Kindly check, my build is getting failed with below error

vmware_nsxv_show_ip_route2
----> passed

The command "python test-templates.py" exited with 1.
Done. Your build exited with 1.

Master branch fails tox tests

This is from the master branch

ISSUE TYPE
  • Bug Report
TEMPLATE USING

Running Tox tests

SUMMARY

See above.

STEPS TO REPRODUCE

git pull
cd ntc-templates
tox

EXPECTED RESULTS

I expected the tests to pass

ACTUAL RESULTS

It failed with an Invocation error. Complete output below...

$ time tox
py27 create: /home/alanr/Charter/networktocode/ntc-templates/.tox/py27
py27 installdeps: pytest, PyYAML, netmiko, textfsm, ansible==1.9.2, terminal
py27 installed: DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.,ansible==1.9.2,asn1crypto==0.24.0,atomicwrites==1.2.1,attrs==18.2.0,bcrypt==3.1.6,cffi==1.11.5,cryptography==2.5,enum34==1.1.6,funcsigs==1.0.2,ipaddress==1.0.22,Jinja2==2.10,MarkupSafe==1.1.0,more-itertools==5.0.0,netmiko==2.3.0,paramiko==2.4.2,pathlib2==2.3.3,pkg-resources==0.0.0,pluggy==0.8.1,py==1.7.0,pyasn1==0.4.5,pycparser==2.19,pycrypto==2.6.1,PyNaCl==1.3.0,pyserial==3.4,pytest==4.1.1,PyYAML==3.13,scandir==1.9.0,scp==0.13.0,six==1.12.0,terminal==0.4.0,textfsm==0.4.1
py27 runtests: PYTHONHASHSEED='2431119445'
py27 runtests: commands[0] | py.test
================================================================================ test session starts ================================================================================
platform linux2 -- Python 2.7.15rc1, pytest-4.1.1, py-1.7.0, pluggy-0.8.1
rootdir: /home/alanr/Charter/networktocode/ntc-templates, inifile:
collected 1377 items                                                                                                                                                                

tests/test_index_order.py .                                                                                                                                                   [  0%]
tests/test_structured_data_against_parsed_reference_files.py ................................................................................................................ [  8%]
............................................................................................................................................................................. [ 20%]
............................................................................................................................................................................. [ 33%]
............................................................................................................................................................................. [ 45%]
............................................................................................................................................................................. [ 58%]
............................................................................................................................................................................. [ 71%]
............................................................................................................................................................................. [ 83%]
............................................................................................................................................................................. [ 96%]
.....................................................                                                                                                                         [100%]

=========================================================================== 1377 passed in 36.37 seconds ============================================================================
py27 runtests: commands[1] | rm -rf .ntc-modules
py27 runtests: commands[2] | git clone https://github.com/networktocode/ntc-ansible.git .ntc-modules
Cloning into '.ntc-modules'...
remote: Enumerating objects: 2381, done.        
remote: Total 2381 (delta 0), reused 0 (delta 0), pack-reused 2381        
Receiving objects: 100% (2381/2381), 421.69 KiB | 2.20 MiB/s, done.
Resolving deltas: 100% (1382/1382), done.
py27 runtests: commands[3] | /home/alanr/Charter/networktocode/ntc-templates/.tox/py27/bin/python test-templates.py
{'dark': {}, 'contacted': {'localhost': {'invocation': {'module_name': 'get_test_info', 'module_args': ''}, u'changed': False, u'tests': [{u'path': u'tests/hp_procurve/show_vlans', u'platform': u'hp_procurve', u'parsedfile': u'hp_procurve_show_vlans2.parsed', u'rawfile': u'hp_procurve_show_vlans2.raw', u'command': u'show vlans'}, {u'path': u'tests/hp_procurve/show_vlans', u'platform': u'hp_procurve', u'parsedfile': u'hp_procurve_show_vlans.parsed', u'rawfile': u'hp_procurve_show_vlans.raw', u'command': u'show vlans'}, {u'path': u'tests/hp_procurve/show_vlans', u'platform': u'hp_procurve', u'parsedfile': u'hp_procurve_show_vlans3.parsed', u'rawfile': u'hp_procurve_show_vlans3.raw', u'command': u'show vlans'}, {u'path': u'tests/hp_procurve/show_system', u'platform': u'hp_procurve', u'parsedfile': u'hp_procurve_show_system.parsed', u'rawfile': u'hp_procurve_show_system.raw', u'command': u'show system'}, {u'path': u'tests/hp_procurve/show_arp', u'platform': u'hp_procurve', u'parsedfile': u'hp_procurve_show_arp.parsed', u'rawfile': u'hp_procurve_show_arp.raw', u'command': u'show arp'}, {u'path': u'tests/hp_procurve/show_tech_buffers', u'platform': u'hp_procurve', u'parsedfile': u'hp_procurve_show_tech_buffers.parsed', u'rawfile': u'hp_procurve_show_tech_buffers.raw', u'command': u'show tech buffers'}, {u'path': u'tests/cisco_ios/show_power_available', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_power_available1.parsed', u'rawfile': u'cisco_ios_show_power_available1.raw', u'command': u'show power available'}, {u'path': u'tests/cisco_ios/show_power_available', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_power_available.parsed', u'rawfile': u'cisco_ios_show_power_available.raw', u'command': u'show power available'}, {u'path': u'tests/cisco_ios/show_ip_bgp', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_bgp.parsed', u'rawfile': u'cisco_ios_show_ip_bgp.raw', u'command': u'show ip bgp'}, {u'path': u'tests/cisco_ios/show_ip_bgp', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_bgp2.parsed', u'rawfile': u'cisco_ios_show_ip_bgp2.raw', u'command': u'show ip bgp'}, {u'path': u'tests/cisco_ios/show_ip_bgp', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_bgp1.parsed', u'rawfile': u'cisco_ios_show_ip_bgp1.raw', u'command': u'show ip bgp'}, {u'path': u'tests/cisco_ios/show_ip_bgp', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_bgp3.parsed', u'rawfile': u'cisco_ios_show_ip_bgp3.raw', u'command': u'show ip bgp'}, {u'path': u'tests/cisco_ios/show_ip_bgp', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_bgp4.parsed', u'rawfile': u'cisco_ios_show_ip_bgp4.raw', u'command': u'show ip bgp'}, {u'path': u'tests/cisco_ios/show_ip_bgp', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_bgp5.parsed', u'rawfile': u'cisco_ios_show_ip_bgp5.raw', u'command': u'show ip bgp'}, {u'path': u'tests/cisco_ios/show_lldp_neighbors_detail', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_lldp_neighbors_detail1.parsed', u'rawfile': u'cisco_ios_show_lldp_neighbors_detail1.raw', u'command': u'show lldp neighbors detail'}, {u'path': u'tests/cisco_ios/show_lldp_neighbors_detail', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_lldp_neighbors_detail3.parsed', u'rawfile': u'cisco_ios_show_lldp_neighbors_detail3.raw', u'command': u'show lldp neighbors detail'}, {u'path': u'tests/cisco_ios/show_lldp_neighbors_detail', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_lldp_neighbors_detail2.parsed', u'rawfile': u'cisco_ios_show_lldp_neighbors_detail2.raw', u'command': u'show lldp neighbors detail'}, {u'path': u'tests/cisco_ios/show_standby', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_standby.parsed', u'rawfile': u'cisco_ios_show_standby.raw', u'command': u'show standby'}, {u'path': u'tests/cisco_ios/show_ip_route', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_route.parsed', u'rawfile': u'cisco_ios_show_ip_route.raw', u'command': u'show ip route'}, {u'path': u'tests/cisco_ios/show_capability_feature_routing', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_capability_feature_routing.parsed', u'rawfile': u'cisco_ios_show_capability_feature_routing.raw', u'command': u'show capability feature routing'}, {u'path': u'tests/cisco_ios/show_isis_neighbors', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_isis_neighbors.parsed', u'rawfile': u'cisco_ios_show_isis_neighbors.raw', u'command': u'show isis neighbors'}, {u'path': u'tests/cisco_ios/show_controller_t1', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_controller_t1.parsed', u'rawfile': u'cisco_ios_show_controller_t1.raw', u'command': u'show controller t1'}, {u'path': u'tests/cisco_ios/show_ip_ospf_neighbor', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_ospf_neighbor.parsed', u'rawfile': u'cisco_ios_show_ip_ospf_neighbor.raw', u'command': u'show ip ospf neighbor'}, {u'path': u'tests/cisco_ios/show_vlan', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_vlan.parsed', u'rawfile': u'cisco_ios_show_vlan.raw', u'command': u'show vlan'}, {u'path': u'tests/cisco_ios/show_cdp_neighbors', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_cdp_neighbors.parsed', u'rawfile': u'cisco_ios_show_cdp_neighbors.raw', u'command': u'show cdp neighbors'}, {u'path': u'tests/cisco_ios/show_cdp_neighbors', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_cdp_neighbors_2.parsed', u'rawfile': u'cisco_ios_show_cdp_neighbors_2.raw', u'command': u'show cdp neighbors'}, {u'path': u'tests/cisco_ios/show_interfaces', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_interfaces.parsed', u'rawfile': u'cisco_ios_show_interfaces.raw', u'command': u'show interfaces'}, {u'path': u'tests/cisco_ios/show_interfaces', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_interfaces2.parsed', u'rawfile': u'cisco_ios_show_interfaces2.raw', u'command': u'show interfaces'}, {u'path': u'tests/cisco_ios/show_interfaces', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_interfaces3.parsed', u'rawfile': u'cisco_ios_show_interfaces3.raw', u'command': u'show interfaces'}, {u'path': u'tests/cisco_ios/show_version', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_version.parsed', u'rawfile': u'cisco_ios_show_version.raw', u'command': u'show version'}, {u'path': u'tests/cisco_ios/show_version', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_version1.parsed', u'rawfile': u'cisco_ios_show_version1.raw', u'command': u'show version'}, {u'path': u'tests/cisco_ios/show_version', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_version2.parsed', u'rawfile': u'cisco_ios_show_version2.raw', u'command': u'show version'}, {u'path': u'tests/cisco_ios/show_aliases', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_aliases.parsed', u'rawfile': u'cisco_ios_show_aliases.raw', u'command': u'show aliases'}, {u'path': u'tests/cisco_ios/show_tacacs', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_tacacs.parsed', u'rawfile': u'cisco_ios_show_tacacs.raw', u'command': u'show tacacs'}, {u'path': u'tests/cisco_ios/show_interface_transceiver', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_interface_transceiver.parsed', u'rawfile': u'cisco_ios_show_interface_transceiver.raw', u'command': u'show interface transceiver'}, {u'path': u'tests/cisco_ios/show_isdn_status', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_isdn_status.parsed', u'rawfile': u'cisco_ios_show_isdn_status.raw', u'command': u'show isdn status'}, {u'path': u'tests/cisco_ios/show_mac-address-table', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_mac-address-table2.parsed', u'rawfile': u'cisco_ios_show_mac-address-table2.raw', u'command': u'show mac-address-table'}, {u'path': u'tests/cisco_ios/show_mac-address-table', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_mac-address-table4.parsed', u'rawfile': u'cisco_ios_show_mac-address-table4.raw', u'command': u'show mac-address-table'}, {u'path': u'tests/cisco_ios/show_mac-address-table', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_mac-address-table3.parsed', u'rawfile': u'cisco_ios_show_mac-address-table3.raw', u'command': u'show mac-address-table'}, {u'path': u'tests/cisco_ios/show_mac-address-table', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_mac-address-table.parsed', u'rawfile': u'cisco_ios_show_mac-address-table.raw', u'command': u'show mac-address-table'}, {u'path': u'tests/cisco_ios/show_mac-address-table', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_mac-address-table5.parsed', u'rawfile': u'cisco_ios_show_mac-address-table5.raw', u'command': u'show mac-address-table'}, {u'path': u'tests/cisco_ios/show_ip_ospf_database', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_ospf_database.parsed', u'rawfile': u'cisco_ios_show_ip_ospf_database.raw', u'command': u'show ip ospf database'}, {u'path': u'tests/cisco_ios/show_vrf', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_vrf.parsed', u'rawfile': u'cisco_ios_show_vrf.raw', u'command': u'show vrf'}, {u'path': u'tests/cisco_ios/show_environment_power_all', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_environment_power_all1.parsed', u'rawfile': u'cisco_ios_show_environment_power_all1.raw', u'command': u'show environment power all'}, {u'path': u'tests/cisco_ios/show_environment_power_all', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_environment_power_all.parsed', u'rawfile': u'cisco_ios_show_environment_power_all.raw', u'command': u'show environment power all'}, {u'path': u'tests/cisco_ios/show_ip_eigrp_neighbors', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_eigrp_neighbors.parsed', u'rawfile': u'cisco_ios_show_ip_eigrp_neighbors.raw', u'command': u'show ip eigrp neighbors'}, {u'path': u'tests/cisco_ios/show_ip_eigrp_neighbors', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_eigrp_neighbors1.parsed', u'rawfile': u'cisco_ios_show_ip_eigrp_neighbors1.raw', u'command': u'show ip eigrp neighbors'}, {u'path': u'tests/cisco_ios/show_standby_brief', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_standby_brief.parsed', u'rawfile': u'cisco_ios_show_standby_brief.raw', u'command': u'show standby brief'}, {u'path': u'tests/cisco_ios/show_processes_cpu', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_processes_cpu.parsed', u'rawfile': u'cisco_ios_show_processes_cpu.raw', u'command': u'show processes cpu'}, {u'path': u'tests/cisco_ios/show_dot1x_all', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_dot1x_all.parsed', u'rawfile': u'cisco_ios_show_dot1x_all.raw', u'command': u'show dot1x all'}, {u'path': u'tests/cisco_ios/show_inventory', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_inventory.parsed', u'rawfile': u'cisco_ios_show_inventory.raw', u'command': u'show inventory'}, {u'path': u'tests/cisco_ios/show_redundancy', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_redundancy.parsed', u'rawfile': u'cisco_ios_show_redundancy.raw', u'command': u'show redundancy'}, {u'path': u'tests/cisco_ios/show_ip_prefix-list', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_prefix-list.parsed', u'rawfile': u'cisco_ios_show_ip_prefix-list.raw', u'command': u'show ip prefix-list'}, {u'path': u'tests/cisco_ios/show_ip_access-lists', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_access-lists.parsed', u'rawfile': u'cisco_ios_show_ip_access-lists.raw', u'command': u'show ip access-lists'}, {u'path': u'tests/cisco_ios/show_power_supplies', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_power_supplies.parsed', u'rawfile': u'cisco_ios_show_power_supplies.raw', u'command': u'show power supplies'}, {u'path': u'tests/cisco_ios/show_power_supplies', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_power_supplies1.parsed', u'rawfile': u'cisco_ios_show_power_supplies1.raw', u'command': u'show power supplies'}, {u'path': u'tests/cisco_ios/show_running-config_partition_access-list', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_running-config_partition_access-list.parsed', u'rawfile': u'cisco_ios_show_running-config_partition_access-list.raw', u'command': u'show running-config partition access-list'}, {u'path': u'tests/cisco_ios/show_platform_diag', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_platform_diag_2.parsed', u'rawfile': u'cisco_ios_show_platform_diag_2.raw', u'command': u'show platform diag'}, {u'path': u'tests/cisco_ios/show_platform_diag', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_platform_diag.parsed', u'rawfile': u'cisco_ios_show_platform_diag.raw', u'command': u'show platform diag'}, {u'path': u'tests/cisco_ios/show_ipv6_interface_brief', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ipv6_interface_brief.parsed', u'rawfile': u'cisco_ios_show_ipv6_interface_brief.raw', u'command': u'show ipv6 interface brief'}, {u'path': u'tests/cisco_ios/show_running-config_partition_route-map', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_running-config_partition_route-map.parsed', u'rawfile': u'cisco_ios_show_running-config_partition_route-map.raw', u'command': u'show running-config partition route-map'}, {u'path': u'tests/cisco_ios/show_running-config_partition_route-map', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_running-config_partition_route-map2.parsed', u'rawfile': u'cisco_ios_show_running-config_partition_route-map2.raw', u'command': u'show running-config partition route-map'}, {u'path': u'tests/cisco_ios/show_power_status', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_power_status2.parsed', u'rawfile': u'cisco_ios_show_power_status2.raw', u'command': u'show power status'}, {u'path': u'tests/cisco_ios/show_power_status', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_power_status.parsed', u'rawfile': u'cisco_ios_show_power_status.raw', u'command': u'show power status'}, {u'path': u'tests/cisco_ios/show_power_status', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_power_status1.parsed', u'rawfile': u'cisco_ios_show_power_status1.raw', u'command': u'show power status'}, {u'path': u'tests/cisco_ios/show_lldp_neighbors', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_lldp_neighbors.parsed', u'rawfile': u'cisco_ios_show_lldp_neighbors.raw', u'command': u'show lldp neighbors'}, {u'path': u'tests/cisco_ios/show_ip_mroute', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_mroute1.parsed', u'rawfile': u'cisco_ios_show_ip_mroute1.raw', u'command': u'show ip mroute'}, {u'path': u'tests/cisco_ios/show_ip_mroute', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_mroute3.parsed', u'rawfile': u'cisco_ios_show_ip_mroute3.raw', u'command': u'show ip mroute'}, {u'path': u'tests/cisco_ios/show_ip_mroute', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_mroute2.parsed', u'rawfile': u'cisco_ios_show_ip_mroute2.raw', u'command': u'show ip mroute'}, {u'path': u'tests/cisco_ios/show_ip_interface', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_interface2.parsed', u'rawfile': u'cisco_ios_show_ip_interface2.raw', u'command': u'show ip interface'}, {u'path': u'tests/cisco_ios/show_ip_interface', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_interface.parsed', u'rawfile': u'cisco_ios_show_ip_interface.raw', u'command': u'show ip interface'}, {u'path': u'tests/cisco_ios/show_snmp_community', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_snmp_community.parsed', u'rawfile': u'cisco_ios_show_snmp_community.raw', u'command': u'show snmp community'}, {u'path': u'tests/cisco_ios/show_ip_bgp_summary', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_bgp_summary.parsed', u'rawfile': u'cisco_ios_show_ip_bgp_summary.raw', u'command': u'show ip bgp summary'}, {u'path': u'tests/cisco_ios/show_authentication_sessions', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_authentication_sessions.parsed', u'rawfile': u'cisco_ios_show_authentication_sessions.raw', u'command': u'show authentication sessions'}, {u'path': u'tests/cisco_ios/show_authentication_sessions', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_authentication_sessions2.parsed', u'rawfile': u'cisco_ios_show_authentication_sessions2.raw', u'command': u'show authentication sessions'}, {u'path': u'tests/cisco_ios/show_ip_arp', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_arp.parsed', u'rawfile': u'cisco_ios_show_ip_arp.raw', u'command': u'show ip arp'}, {u'path': u'tests/cisco_ios/show_interfaces_status', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_interfaces_status.parsed', u'rawfile': u'cisco_ios_show_interfaces_status.raw', u'command': u'show interfaces status'}, {u'path': u'tests/cisco_ios/dir', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_dir.parsed', u'rawfile': u'cisco_ios_dir.raw', u'command': u'dir'}, {u'path': u'tests/cisco_ios/show_vtp_status', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_vtp_status.parsed', u'rawfile': u'cisco_ios_show_vtp_status.raw', u'command': u'show vtp status'}, {u'path': u'tests/cisco_ios/show_clock', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_clock.parsed', u'rawfile': u'cisco_ios_show_clock.raw', u'command': u'show clock'}, {u'path': u'tests/cisco_ios/show_ip_eigrp_topology', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_eigrp_topology.parsed', u'rawfile': u'cisco_ios_show_ip_eigrp_topology.raw', u'command': u'show ip eigrp topology'}, {u'path': u'tests/cisco_ios/show_ip_interface_brief', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_interface_brief.parsed', u'rawfile': u'cisco_ios_show_ip_interface_brief.raw', u'command': u'show ip interface brief'}, {u'path': u'tests/cisco_ios/show_archive', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_archive.parsed', u'rawfile': u'cisco_ios_show_archive.raw', u'command': u'show archive'}, {u'path': u'tests/cisco_ios/show_access-list', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_access-list.parsed', u'rawfile': u'cisco_ios_show_access-list.raw', u'command': u'show access-list'}, {u'path': u'tests/cisco_ios/show_ip_ospf_interface_brief', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_ospf_interface_brief.parsed', u'rawfile': u'cisco_ios_show_ip_ospf_interface_brief.raw', u'command': u'show ip ospf interface brief'}, {u'path': u'tests/cisco_ios/show_ip_device_tracking_all', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_device_tracking_all.parsed', u'rawfile': u'cisco_ios_show_ip_device_tracking_all.raw', u'command': u'show ip device tracking all'}, {u'path': u'tests/cisco_ios/show_route-map', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_route-map.parsed', u'rawfile': u'cisco_ios_show_route-map.raw', u'command': u'show route-map'}, {u'path': u'tests/cisco_ios/show_cdp_neighbors_detail', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_cdp_neighbors_detail.parsed', u'rawfile': u'cisco_ios_show_cdp_neighbors_detail.raw', u'command': u'show cdp neighbors detail'}, {u'path': u'tests/cisco_ios/show_spanning_tree', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_spanning_tree.parsed', u'rawfile': u'cisco_ios_show_spanning_tree.raw', u'command': u'show spanning tree'}, {u'path': u'tests/cisco_ios/show_ip_source_binding', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_ip_source_binding.parsed', u'rawfile': u'cisco_ios_show_ip_source_binding.raw', u'command': u'show ip source binding'}, {u'path': u'tests/cisco_ios/show_interfaces_description', u'platform': u'cisco_ios', u'parsedfile': u'cisco_ios_show_interfaces_description.parsed', u'rawfile': u'cisco_ios_show_interfaces_description.raw', u'command': u'show interfaces description'}, {u'path': u'tests/brocade_netiron/show_lag_brief', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_lag_brief.parsed', u'rawfile': u'brocade_netiron_show_lag_brief.raw', u'command': u'show lag brief'}, {u'path': u'tests/brocade_netiron/show_topo', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_topo.parsed', u'rawfile': u'brocade_netiron_show_topo.raw', u'command': u'show topo'}, {u'path': u'tests/brocade_netiron/show_lldp_neighbors_detail', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_lldp_neighbors_detail.parsed', u'rawfile': u'brocade_netiron_show_lldp_neighbors_detail.raw', u'command': u'show lldp neighbors detail'}, {u'path': u'tests/brocade_netiron/show_running-config_vlan', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_running-config_vlan.parsed', u'rawfile': u'brocade_netiron_show_running-config_vlan.raw', u'command': u'show running-config vlan'}, {u'path': u'tests/brocade_netiron/show_interfaces', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_interfaces.parsed', u'rawfile': u'brocade_netiron_show_interfaces.raw', u'command': u'show interfaces'}, {u'path': u'tests/brocade_netiron/show_span', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_span.parsed', u'rawfile': u'brocade_netiron_show_span.raw', u'command': u'show span'}, {u'path': u'tests/brocade_netiron/show_running-config_interface', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_running-config_interface.parsed', u'rawfile': u'brocade_netiron_show_running-config_interface.raw', u'command': u'show running-config interface'}, {u'path': u'tests/brocade_netiron/show_running-config_interface', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_running-config_interface2.parsed', u'rawfile': u'brocade_netiron_show_running-config_interface2.raw', u'command': u'show running-config interface'}, {u'path': u'tests/brocade_netiron/show_monitor_actual', u'platform': u'brocade_netiron_show_monitor', u'parsedfile': u'brocade_netiron_show_monitor.parsed', u'rawfile': u'brocade_netiron_show_monitor.raw', u'command': u'show monitor actual'}, {u'path': u'tests/brocade_netiron/show_interfaces_brief', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_interfaces_brief.parsed', u'rawfile': u'brocade_netiron_show_interfaces_brief.raw', u'command': u'show interfaces brief'}, {u'path': u'tests/brocade_netiron/show_metro', u'platform': u'brocade_netiron', u'parsedfile': u'brocade_netiron_show_metro.parsed', u'rawfile': u'brocade_netiron_show_metro.raw', u'command': u'show metro'}, {u'path': u'tests/brocade_netiron/show_monitor_config', u'platform': u'brocade_netiron_show_monitor', u'parsedfile': u'brocade_netiron_show_monitor.parsed', u'rawfile': u'brocade_netiron_show_monitor.raw', u'command': u'show monitor config'}, {u'path': u'tests/cisco_xr/show_controller_fabric_plane_all', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_controller_fabric_plane_all.parsed', u'rawfile': u'cisco_xr_show_controller_fabric_plane_all.raw', u'command': u'show controller fabric plane all'}, {u'path': u'tests/cisco_xr/show_ip_route', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_ip_route2.parsed', u'rawfile': u'cisco_xr_show_ip_route2.raw', u'command': u'show ip route'}, {u'path': u'tests/cisco_xr/show_ip_route', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_ip_route.parsed', u'rawfile': u'cisco_xr_show_ip_route.raw', u'command': u'show ip route'}, {u'path': u'tests/cisco_xr/show_isis_neighbors', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_isis_neighbors.parsed', u'rawfile': u'cisco_xr_show_isis_neighbors.raw', u'command': u'show isis neighbors'}, {u'path': u'tests/cisco_xr/show_lpts_pifib_hardware_police_location', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_lpts_pifib_hardware_police_location.parsed', u'rawfile': u'cisco_xr_show_lpts_pifib_hardware_police_location.raw', u'command': u'show lpts pifib hardware police location'}, {u'path': u'tests/cisco_xr/show_lpts_pifib_hardware_police_location', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_lpts_pifib_hardware_police_location2.parsed', u'rawfile': u'cisco_xr_show_lpts_pifib_hardware_police_location2.raw', u'command': u'show lpts pifib hardware police location'}, {u'path': u'tests/cisco_xr/show_interfaces', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_interfaces.parsed', u'rawfile': u'cisco_xr_show_interfaces.raw', u'command': u'show interfaces'}, {u'path': u'tests/cisco_xr/show_controllers_HundredGigabitEthernet', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_controllers_HundredGigabitEthernet.parsed', u'rawfile': u'cisco_xr_show_controllers_HundredGigabitEthernet.raw', u'command': u'show controllers HundredGigabitEthernet'}, {u'path': u'tests/cisco_xr/show_version', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_version.parsed', u'rawfile': u'cisco_xr_show_version.raw', u'command': u'show version'}, {u'path': u'tests/cisco_xr/show_bgp_neighbors', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_bgp_neighbors1.parsed', u'rawfile': u'cisco_xr_show_bgp_neighbors1.raw', u'command': u'show bgp neighbors'}, {u'path': u'tests/cisco_xr/show_bgp_neighbors', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_bgp_neighbors.parsed', u'rawfile': u'cisco_xr_show_bgp_neighbors.raw', u'command': u'show bgp neighbors'}, {u'path': u'tests/cisco_xr/admin_show_vm', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_admin_show_vm.parsed', u'rawfile': u'cisco_xr_admin_show_vm.raw', u'command': u'admin show vm'}, {u'path': u'tests/cisco_xr/show_processes_cpu', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_processes_cpu.parsed', u'rawfile': u'cisco_xr_show_processes_cpu.raw', u'command': u'show processes cpu'}, {u'path': u'tests/cisco_xr/show_bfd_sessions', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_bfd_sessions.parsed', u'rawfile': u'cisco_xr_show_bfd_sessions.raw', u'command': u'show bfd sessions'}, {u'path': u'tests/cisco_xr/show_rsvp_neighbors', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_rsvp_neighbors.parsed', u'rawfile': u'cisco_xr_show_rsvp_neighbors.raw', u'command': u'show rsvp neighbors'}, {u'path': u'tests/cisco_xr/show_redundancy_summary', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_redundancy_summary.parsed', u'rawfile': u'cisco_xr_show_redundancy_summary.raw', u'command': u'show redundancy summary'}, {u'path': u'tests/cisco_xr/admin_show_platform', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_admin_show_platform.parsed', u'rawfile': u'cisco_xr_admin_show_platform.raw', u'command': u'admin show platform'}, {u'path': u'tests/cisco_xr/show_controllers_all_phy', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_controllers_all_phy2.parsed', u'rawfile': u'cisco_xr_show_controllers_all_phy2.raw', u'command': u'show controllers all phy'}, {u'path': u'tests/cisco_xr/show_controllers_all_phy', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_controllers_all_phy.parsed', u'rawfile': u'cisco_xr_show_controllers_all_phy.raw', u'command': u'show controllers all phy'}, {u'path': u'tests/cisco_xr/show_dhcp_ipv4_proxy_binding', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_dhcp_ipv4_proxy_binding.parsed', u'rawfile': u'cisco_xr_show_dhcp_ipv4_proxy_binding.raw', u'command': u'show dhcp ipv4 proxy binding'}, {u'path': u'tests/cisco_xr/show_interface_brief', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_interface_brief.parsed', u'rawfile': u'cisco_xr_show_interface_brief.raw', u'command': u'show interface brief'}, {u'path': u'tests/cisco_xr/show_mpls_ldp_neighbor_brief', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_mpls_ldp_neighbor_brief.parsed', u'rawfile': u'cisco_xr_show_mpls_ldp_neighbor_brief.raw', u'command': u'show mpls ldp neighbor brief'}, {u'path': u'tests/cisco_xr/show_lldp_neighbors', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_lldp_neighbors.parsed', u'rawfile': u'cisco_xr_show_lldp_neighbors.raw', u'command': u'show lldp neighbors'}, {u'path': u'tests/cisco_xr/admin_show_environment_fan', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_admin_show_environment_fan.parsed', u'rawfile': u'cisco_xr_admin_show_environment_fan.raw', u'command': u'admin show environment fan'}, {u'path': u'tests/cisco_xr/show_ip_bgp_summary', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_ip_bgp_summary.parsed', u'rawfile': u'cisco_xr_show_ip_bgp_summary.raw', u'command': u'show ip bgp summary'}, {u'path': u'tests/cisco_xr/show_bgp_vrf_all_ipv4_unicast_summary', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_bgp_vrf_all_ipv4_unicast_summary.parsed', u'rawfile': u'cisco_xr_show_bgp_vrf_all_ipv4_unicast_summary.raw', u'command': u'show bgp vrf all ipv4 unicast summary'}, {u'path': u'tests/cisco_xr/show_ospf_neighbor', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_ospf_neighbor.parsed', u'rawfile': u'cisco_xr_show_ospf_neighbor.raw', u'command': u'show ospf neighbor'}, {u'path': u'tests/cisco_xr/show_pim_neighbor', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_pim_neighbor.parsed', u'rawfile': u'cisco_xr_show_pim_neighbor.raw', u'command': u'show pim neighbor'}, {u'path': u'tests/cisco_xr/show_configuration_commit_list', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_configuration_commit_list.parsed', u'rawfile': u'cisco_xr_show_configuration_commit_list.raw', u'command': u'show configuration commit list'}, {u'path': u'tests/cisco_xr/show_cdp_neighbors_detail', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_show_cdp_neighbors_detail.parsed', u'rawfile': u'cisco_xr_show_cdp_neighbors_detail.raw', u'command': u'show cdp neighbors detail'}, {u'path': u'tests/cisco_xr/admin_show_controller_fabric_health', u'platform': u'cisco_xr', u'parsedfile': u'cisco_xr_admin_show_controller_fabric_health.parsed', u'rawfile': u'cisco_xr_admin_show_controller_fabric_health.raw', u'command': u'admin show controller fabric health'}, {u'path': u'tests/brocade_fastiron/show_lag_brief', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_lag_brief.parsed', u'rawfile': u'brocade_fastiron_show_lag_brief.raw', u'command': u'show lag brief'}, {u'path': u'tests/brocade_fastiron/show_trunk', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_trunk.parsed', u'rawfile': u'brocade_fastiron_show_trunk.raw', u'command': u'show trunk'}, {u'path': u'tests/brocade_fastiron/show_trunk', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_trunk1.parsed', u'rawfile': u'brocade_fastiron_show_trunk1.raw', u'command': u'show trunk'}, {u'path': u'tests/brocade_fastiron/show_topo', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_topo1.parsed', u'rawfile': u'brocade_fastiron_show_topo1.raw', u'command': u'show topo'}, {u'path': u'tests/brocade_fastiron/show_topo', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_topo.parsed', u'rawfile': u'brocade_fastiron_show_topo.raw', u'command': u'show topo'}, {u'path': u'tests/brocade_fastiron/show_lldp_neighbors_detail', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_lldp_neighbors_detail.parsed', u'rawfile': u'brocade_fastiron_show_lldp_neighbors_detail.raw', u'command': u'show lldp neighbors detail'}, {u'path': u'tests/brocade_fastiron/show_lldp_neighbors_detail', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_lldp_neighbors_detail1.parsed', u'rawfile': u'brocade_fastiron_show_lldp_neighbors_detail1.raw', u'command': u'show lldp neighbors detail'}, {u'path': u'tests/brocade_fastiron/show_running-config_vlan', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_running-config_vlan.parsed', u'rawfile': u'brocade_fastiron_show_running-config_vlan.raw', u'command': u'show running-config vlan'}, {u'path': u'tests/brocade_fastiron/show_running-config_vlan', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_running-config_vlan1.parsed', u'rawfile': u'brocade_fastiron_show_running-config_vlan1.raw', u'command': u'show running-config vlan'}, {u'path': u'tests/brocade_fastiron/show_interfaces', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_interfaces.parsed', u'rawfile': u'brocade_fastiron_show_interfaces.raw', u'command': u'show interfaces'}, {u'path': u'tests/brocade_fastiron/show_interfaces', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_interfaces1.parsed', u'rawfile': u'brocade_fastiron_show_interfaces1.raw', u'command': u'show interfaces'}, {u'path': u'tests/brocade_fastiron/show_version', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_version.parsed', u'rawfile': u'brocade_fastiron_show_version.raw', u'command': u'show version'}, {u'path': u'tests/brocade_fastiron/show_span', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_span.parsed', u'rawfile': u'brocade_fastiron_show_span.raw', u'command': u'show span'}, {u'path': u'tests/brocade_fastiron/show_span', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_span1.parsed', u'rawfile': u'brocade_fastiron_show_span1.raw', u'command': u'show span'}, {u'path': u'tests/brocade_fastiron/show_arp', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_arp.parsed', u'rawfile': u'brocade_fastiron_show_arp.raw', u'command': u'show arp'}, {u'path': u'tests/brocade_fastiron/show_monitor', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_monitor.parsed', u'rawfile': u'brocade_fastiron_show_monitor.raw', u'command': u'show monitor'}, {u'path': u'tests/brocade_fastiron/show_lldp_neighbors', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_lldp_neighbors.parsed', u'rawfile': u'brocade_fastiron_show_lldp_neighbors.raw', u'command': u'show lldp neighbors'}, {u'path': u'tests/brocade_fastiron/show_mac-address', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_mac-address.parsed', u'rawfile': u'brocade_fastiron_show_mac-address.raw', u'command': u'show mac-address'}, {u'path': u'tests/brocade_fastiron/show_interfaces_brief', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_interfaces_brief2.parsed', u'rawfile': u'brocade_fastiron_show_interfaces_brief2.raw', u'command': u'show interfaces brief'}, {u'path': u'tests/brocade_fastiron/show_interfaces_brief', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_interfaces_brief.parsed', u'rawfile': u'brocade_fastiron_show_interfaces_brief.raw', u'command': u'show interfaces brief'}, {u'path': u'tests/brocade_fastiron/show_interfaces_brief', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_interfaces_brief1.parsed', u'rawfile': u'brocade_fastiron_show_interfaces_brief1.raw', u'command': u'show interfaces brief'}, {u'path': u'tests/brocade_fastiron/show_metro', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_metro.parsed', u'rawfile': u'brocade_fastiron_show_metro.raw', u'command': u'show metro'}, {u'path': u'tests/brocade_fastiron/show_metro', u'platform': u'brocade_fastiron', u'parsedfile': u'brocade_fastiron_show_metro1.parsed', u'rawfile': u'brocade_fastiron_show_metro1.raw', u'command': u'show metro'}, {u'path': u'tests/avaya_ers/show_sys-info', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_sys-info.parsed', u'rawfile': u'avaya_ers_show_sys-info.raw', u'command': u'show sys-info'}, {u'path': u'tests/avaya_ers/show_sys-info', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_sys-info1.parsed', u'rawfile': u'avaya_ers_show_sys-info1.raw', u'command': u'show sys-info'}, {u'path': u'tests/avaya_ers/show_mlt', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mlt1.parsed', u'rawfile': u'avaya_ers_show_mlt1.raw', u'command': u'show mlt'}, {u'path': u'tests/avaya_ers/show_mlt', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mlt2.parsed', u'rawfile': u'avaya_ers_show_mlt2.raw', u'command': u'show mlt'}, {u'path': u'tests/avaya_ers/show_mlt', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mlt_7000.parsed', u'rawfile': u'avaya_ers_show_mlt_7000.raw', u'command': u'show mlt'}, {u'path': u'tests/avaya_ers/show_mlt', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mlt_4900.parsed', u'rawfile': u'avaya_ers_show_mlt_4900.raw', u'command': u'show mlt'}, {u'path': u'tests/avaya_ers/show_mlt', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mlt_4800.parsed', u'rawfile': u'avaya_ers_show_mlt_4800.raw', u'command': u'show mlt'}, {u'path': u'tests/avaya_ers/show_mlt', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mlt3.parsed', u'rawfile': u'avaya_ers_show_mlt3.raw', u'command': u'show mlt'}, {u'path': u'tests/avaya_ers/show_vlan', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_vlan1.parsed', u'rawfile': u'avaya_ers_show_vlan1.raw', u'command': u'show vlan'}, {u'path': u'tests/avaya_ers/show_vlan', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_vlan.parsed', u'rawfile': u'avaya_ers_show_vlan.raw', u'command': u'show vlan'}, {u'path': u'tests/avaya_ers/show_mac-address-table', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mac-address-table.parsed', u'rawfile': u'avaya_ers_show_mac-address-table.raw', u'command': u'show mac-address-table'}, {u'path': u'tests/avaya_ers/show_interface_name', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_interface_name1.parsed', u'rawfile': u'avaya_ers_show_interface_name1.raw', u'command': u'show interface name'}, {u'path': u'tests/avaya_ers/show_interface_name', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_interface_name.parsed', u'rawfile': u'avaya_ers_show_interface_name.raw', u'command': u'show interface name'}, {u'path': u'tests/avaya_ers/show_mlt_all-members', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mlt_all-members_4800.parsed', u'rawfile': u'avaya_ers_show_mlt_all-members_4800.raw', u'command': u'show mlt all-members'}, {u'path': u'tests/avaya_ers/show_mlt_all-members', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mlt_all-members_7000.parsed', u'rawfile': u'avaya_ers_show_mlt_all-members_7000.raw', u'command': u'show mlt all-members'}, {u'path': u'tests/avaya_ers/show_mlt_all-members', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_mlt_all-members_4900.parsed', u'rawfile': u'avaya_ers_show_mlt_all-members_4900.raw', u'command': u'show mlt all-members'}, {u'path': u'tests/avaya_ers/show_logging_config', u'platform': u'avaya_ers', u'parsedfile': u'avaya_ers_show_logging_config.parsed', u'rawfile': u'avaya_ers_show_logging_config.raw', u'command': u'show logging config'}, {u'path': u'tests/arista_eos/show_interfaces_transceiver', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_interfaces_transceiver.parsed', u'rawfile': u'arista_eos_show_interfaces_transceiver.raw', u'command': u'show interfaces transceiver'}, {u'path': u'tests/arista_eos/show_ip_bgp', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_bgp2.parsed', u'rawfile': u'arista_eos_show_ip_bgp2.raw', u'command': u'show ip bgp'}, {u'path': u'tests/arista_eos/show_ip_bgp', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_bgp.parsed', u'rawfile': u'arista_eos_show_ip_bgp.raw', u'command': u'show ip bgp'}, {u'path': u'tests/arista_eos/show_mac_security_interface', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_mac_security_interface.parsed', u'rawfile': u'arista_eos_show_mac_security_interface.raw', u'command': u'show mac security interface'}, {u'path': u'tests/arista_eos/show_boot-config', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_boot-config.parsed', u'rawfile': u'arista_eos_show_boot-config.raw', u'command': u'show boot-config'}, {u'path': u'tests/arista_eos/show_lldp_neighbors_detail', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_lldp_neighbors_detail.parsed', u'rawfile': u'arista_eos_show_lldp_neighbors_detail.raw', u'command': u'show lldp neighbors detail'}, {u'path': u'tests/arista_eos/show_ip_route', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_route.parsed', u'rawfile': u'arista_eos_show_ip_route.raw', u'command': u'show ip route'}, {u'path': u'tests/arista_eos/show_isis_neighbors', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_isis_neighbors.parsed', u'rawfile': u'arista_eos_show_isis_neighbors.raw', u'command': u'show isis neighbors'}, {u'path': u'tests/arista_eos/show_ip_ospf_neighbor', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_ospf_neighbor.parsed', u'rawfile': u'arista_eos_show_ip_ospf_neighbor.raw', u'command': u'show ip ospf neighbor'}, {u'path': u'tests/arista_eos/show_vlan', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_vlan.parsed', u'rawfile': u'arista_eos_show_vlan.raw', u'command': u'show vlan'}, {u'path': u'tests/arista_eos/show_interfaces', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_interfaces.parsed', u'rawfile': u'arista_eos_show_interfaces.raw', u'command': u'show interfaces'}, {u'path': u'tests/arista_eos/show_version', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_version.parsed', u'rawfile': u'arista_eos_show_version.raw', u'command': u'show version'}, {u'path': u'tests/arista_eos/show_hostname', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_hostname.parsed', u'rawfile': u'arista_eos_show_hostname.raw', u'command': u'show hostname'}, {u'path': u'tests/arista_eos/show_ip_ospf_database', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_ospf_database.parsed', u'rawfile': u'arista_eos_show_ip_ospf_database.raw', u'command': u'show ip ospf database'}, {u'path': u'tests/arista_eos/show_inventory', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_inventory.parsed', u'rawfile': u'arista_eos_show_inventory.raw', u'command': u'show inventory'}, {u'path': u'tests/arista_eos/show_environment_temperature', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_environment_temperature.parsed', u'rawfile': u'arista_eos_show_environment_temperature.raw', u'command': u'show environment temperature'}, {u'path': u'tests/arista_eos/show_ip_access-lists', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_access-lists.parsed', u'rawfile': u'arista_eos_show_ip_access-lists.raw', u'command': u'show ip access-lists'}, {u'path': u'tests/arista_eos/show_environment_cooling', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_environment_cooling.parsed', u'rawfile': u'arista_eos_show_environment_cooling.raw', u'command': u'show environment cooling'}, {u'path': u'tests/arista_eos/dir_flash', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_dir_flash.parsed', u'rawfile': u'arista_eos_dir_flash.raw', u'command': u'dir flash'}, {u'path': u'tests/arista_eos/show_reload_cause', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_reload_cause.parsed', u'rawfile': u'arista_eos_show_reload_cause.raw', u'command': u'show reload cause'}, {u'path': u'tests/arista_eos/show_mac_security_mka_counters', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_mac_security_mka_counters.parsed', u'rawfile': u'arista_eos_show_mac_security_mka_counters.raw', u'command': u'show mac security mka counters'}, {u'path': u'tests/arista_eos/show_module', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_module.template.parsed', u'rawfile': u'arista_eos_show_module.template.raw', u'command': u'show module'}, {u'path': u'tests/arista_eos/show_lldp_neighbors', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_lldp_neighbors.parsed', u'rawfile': u'arista_eos_show_lldp_neighbors.raw', u'command': u'show lldp neighbors'}, {u'path': u'tests/arista_eos/show_snmp_community', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_snmp_community.parsed', u'rawfile': u'arista_eos_show_snmp_community.raw', u'command': u'show snmp community'}, {u'path': u'tests/arista_eos/show_ip_bgp_summary', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_bgp_summary.parsed', u'rawfile': u'arista_eos_show_ip_bgp_summary.raw', u'command': u'show ip bgp summary'}, {u'path': u'tests/arista_eos/show_ip_bgp_summary', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_bgp_summary2.parsed', u'rawfile': u'arista_eos_show_ip_bgp_summary2.raw', u'command': u'show ip bgp summary'}, {u'path': u'tests/arista_eos/show_ip_arp', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_arp.parsed', u'rawfile': u'arista_eos_show_ip_arp.raw', u'command': u'show ip arp'}, {u'path': u'tests/arista_eos/show_interfaces_status', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_interfaces_status.parsed', u'rawfile': u'arista_eos_show_interfaces_status.raw', u'command': u'show interfaces status'}, {u'path': u'tests/arista_eos/show_clock', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_clock.parsed', u'rawfile': u'arista_eos_show_clock.raw', u'command': u'show clock'}, {u'path': u'tests/arista_eos/show_ip_interface_brief', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_ip_interface_brief.parsed', u'rawfile': u'arista_eos_show_ip_interface_brief.raw', u'command': u'show ip interface brief'}, {u'path': u'tests/arista_eos/show_interfaces_transceiver_detail', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_interfaces_transceiver_detail.parsed', u'rawfile': u'arista_eos_show_interfaces_transceiver_detail.raw', u'command': u'show interfaces transceiver detail'}, {u'path': u'tests/arista_eos/show_mlag', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_mlag.parsed', u'rawfile': u'arista_eos_show_mlag.raw', u'command': u'show mlag'}, {u'path': u'tests/arista_eos/show_mac_security_participants_detail', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_mac_security_participants_detail.parsed', u'rawfile': u'arista_eos_show_mac_security_participants_detail.raw', u'command': u'show mac security participants detail'}, {u'path': u'tests/arista_eos/bash_df_-h', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_bash_df_-h.parsed', u'rawfile': u'arista_eos_bash_df_-h.raw', u'command': u'bash df -h'}, {u'path': u'tests/arista_eos/show_mac_address-table', u'platform': u'arista_eos', u'parsedfile': u'arista_eos_show_mac_address-table.parsed', u'rawfile': u'arista_eos_show_mac_address-table.raw', u'command': u'show mac address-table'}, {u'path': u'tests/vyatta_vyos/show_interfaces', u'platform': u'vyatta_vyos', u'parsedfile': u'vyatta_vyos_show_interfaces.parsed', u'rawfile': u'vyatta_vyos_show_interfaces.raw', u'command': u'show interfaces'}, {u'path': u'tests/vyatta_vyos/show_arp', u'platform': u'vyatta_vyos', u'parsedfile': u'vyatta_vyos_show_arp.parsed', u'rawfile': u'vyatta_vyos_show_arp.raw', u'command': u'show arp'}, {u'path': u'tests/cisco_asa/show_running-config_tunnel-group', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_running-config_tunnel-group.parsed', u'rawfile': u'cisco_asa_show_running-config_tunnel-group.raw', u'command': u'show running-config tunnel-group'}, {u'path': u'tests/cisco_asa/show_name', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_name.parsed', u'rawfile': u'cisco_asa_show_name.raw', u'command': u'show name'}, {u'path': u'tests/cisco_asa/show_resource_usage', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_resource_usage.parsed', u'rawfile': u'cisco_asa_show_resource_usage.raw', u'command': u'show resource usage'}, {u'path': u'tests/cisco_asa/show_interface_detail', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_interface_detail.parsed', u'rawfile': u'cisco_asa_show_interface_detail.raw', u'command': u'show interface detail'}, {u'path': u'tests/cisco_asa/show_failover', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_failover2.parsed', u'rawfile': u'cisco_asa_show_failover2.raw', u'command': u'show failover'}, {u'path': u'tests/cisco_asa/show_failover', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_failover5505.parsed', u'rawfile': u'cisco_asa_show_failover5505.raw', u'command': u'show failover'}, {u'path': u'tests/cisco_asa/show_failover', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_failover.parsed', u'rawfile': u'cisco_asa_show_failover.raw', u'command': u'show failover'}, {u'path': u'tests/cisco_asa/show_failover', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_failoveractiveactive.parsed', u'rawfile': u'cisco_asa_show_failoveractiveactive.raw', u'command': u'show failover'}, {u'path': u'tests/cisco_asa/show_crypto_ikev1_sa_detail', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_crypto_ikev1_sa_detail.parsed', u'rawfile': u'cisco_asa_show_crypto_ikev1_sa_detail.raw', u'command': u'show crypto ikev1 sa detail'}, {u'path': u'tests/cisco_asa/show_vpn-sessiondb_detail_l2l', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_vpn-sessiondb_detail_l2l.parsed', u'rawfile': u'cisco_asa_show_vpn-sessiondb_detail_l2l.raw', u'command': u'show vpn-sessiondb detail l2l'}, {u'path': u'tests/cisco_asa/show_vpn-sessiondb_detail_l2l', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_vpn-sessiondb_detail_l2l2.parsed', u'rawfile': u'cisco_asa_show_vpn-sessiondb_detail_l2l2.raw', u'command': u'show vpn-sessiondb detail l2l'}, {u'path': u'tests/cisco_asa/show_version', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_version.parsed', u'rawfile': u'cisco_asa_show_version.raw', u'command': u'show version'}, {u'path': u'tests/cisco_asa/show_asp_drop', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_asp_drop.parsed', u'rawfile': u'cisco_asa_show_asp_drop.raw', u'command': u'show asp drop'}, {u'path': u'tests/cisco_asa/show_xlate', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_xlate.parsed', u'rawfile': u'cisco_asa_show_xlate.raw', u'command': u'show xlate'}, {u'path': u'tests/cisco_asa/show_crypto_ipsec_sa', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_crypto_ipsec_sa.parsed', u'rawfile': u'cisco_asa_show_crypto_ipsec_sa.raw', u'command': u'show crypto ipsec sa'}, {u'path': u'tests/cisco_asa/show_license_all', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_license_all3.parsed', u'rawfile': u'cisco_asa_show_license_all3.raw', u'command': u'show license all'}, {u'path': u'tests/cisco_asa/show_license_all', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_license_all.parsed', u'rawfile': u'cisco_asa_show_license_all.raw', u'command': u'show license all'}, {u'path': u'tests/cisco_asa/show_license_all', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_license_all2.parsed', u'rawfile': u'cisco_asa_show_license_all2.raw', u'command': u'show license all'}, {u'path': u'tests/cisco_asa/show_running-config_ipsec', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_running-config_ipsec.parsed', u'rawfile': u'cisco_asa_show_running-config_ipsec.raw', u'command': u'show running-config ipsec'}, {u'path': u'tests/cisco_asa/show_interface', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_interface.parsed', u'rawfile': u'cisco_asa_show_interface.raw', u'command': u'show interface'}, {u'path': u'tests/cisco_asa/show_route', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_route.parsed', u'rawfile': u'cisco_asa_show_route.raw', u'command': u'show route'}, {u'path': u'tests/cisco_asa/show_inventory', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_inventory.parsed', u'rawfile': u'cisco_asa_show_inventory.raw', u'command': u'show inventory'}, {u'path': u'tests/cisco_asa/show_running-config_object_network', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_running-config_object_network.parsed', u'rawfile': u'cisco_asa_show_running-config_object_network.raw', u'command': u'show running-config object network'}, {u'path': u'tests/cisco_asa/show_running-config_crypto_map', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_running-config_crypto_map.parsed', u'rawfile': u'cisco_asa_show_running-config_crypto_map.raw', u'command': u'show running-config crypto map'}, {u'path': u'tests/cisco_asa/show_running-config_crypto_ikev1', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_running-config_crypto_ikev1.parsed', u'rawfile': u'cisco_asa_show_running-config_crypto_ikev1.raw', u'command': u'show running-config crypto ikev1'}, {u'path': u'tests/cisco_asa/show_asp_table_vpn-context_detail', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_asp_table_vpn-context_detail.parsed', u'rawfile': u'cisco_asa_show_asp_table_vpn-context_detail.raw', u'command': u'show asp table vpn-context detail'}, {u'path': u'tests/cisco_asa/show_nat', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_nat.parsed', u'rawfile': u'cisco_asa_show_nat.raw', u'command': u'show nat'}, {u'path': u'tests/cisco_asa/dir', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_dir.parsed', u'rawfile': u'cisco_asa_dir.raw', u'command': u'dir'}, {u'path': u'tests/cisco_asa/show_access-list', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_access-list.parsed', u'rawfile': u'cisco_asa_show_access-list.raw', u'command': u'show access-list'}, {u'path': u'tests/cisco_asa/show_object-group_network', u'platform': u'cisco_asa', u'parsedfile': u'cisco_asa_show_object-group_network.parsed', u'rawfile': u'cisco_asa_show_object-group_network.raw', u'command': u'show object-group network'}, {u'path': u'tests/paloalto_panos/show_jobs_all', u'platform': u'paloalto_panos', u'parsedfile': u'paloalto_panos_show_jobs_all.parsed', u'rawfile': u'paloalto_panos_show_jobs_all.raw', u'command': u'show jobs all'}, {u'path': u'tests/paloalto_panos/show_jobs_all', u'platform': u'paloalto_panos', u'parsedfile': u'paloalto_panos_show_jobs_all2.parsed', u'rawfile': u'paloalto_panos_show_jobs_all2.raw', u'command': u'show jobs all'}, {u'path': u'tests/paloalto_panos/show_running_security-policy', u'platform': u'paloalto_panos', u'parsedfile': u'paloalto_panos_show_running_security-policy.parsed', u'rawfile': u'paloalto_panos_show_running_security-policy.raw', u'command': u'show running security-policy'}, {u'path': u'tests/paloalto_panos/show_system_info', u'platform': u'paloalto_panos', u'parsedfile': u'paloalto_panos_show_system_info.parsed', u'rawfile': u'paloalto_panos_show_system_info.raw', u'command': u'show system info'}, {u'path': u'tests/paloalto_panos/show_high-availability_all', u'platform': u'paloalto_panos', u'parsedfile': u'paloalto_panos_show_high-availability_all.parsed', u'rawfile': u'paloalto_panos_show_high-availability_all.raw', u'command': u'show high-availability all'}, {u'path': u'tests/paloalto_panos/show_counter_global', u'platform': u'paloalto_panos', u'parsedfile': u'paloalto_panos_show_counter_global.parsed', u'rawfile': u'paloalto_panos_show_counter_global.raw', u'command': u'show counter global'}, {u'path': u'tests/paloalto_panos/show_interface_logical', u'platform': u'paloalto_panos', u'parsedfile': u'paloalto_panos_show_interface_logical.parsed', u'rawfile': u'paloalto_panos_show_interface_logical.raw', u'command': u'show interface logical'}, {u'path': u'tests/paloalto_panos/show_interface_hardware', u'platform': u'paloalto_panos', u'parsedfile': u'paloalto_panos_show_interface_hardware.parsed', u'rawfile': u'paloalto_panos_show_interface_hardware.raw', u'command': u'show interface hardware'}, {u'path': u'tests/paloalto_panos/show_running_nat-policy', u'platform': u'paloalto_panos', u'parsedfile': u'paloalto_panos_show_running_nat-policy.parsed', u'rawfile': u'paloalto_panos_show_running_nat-policy.raw', u'command': u'show running nat-policy'}, {u'path': u'tests/checkpoint_gaia/show_interfaces_all', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_show_interfaces_all.parsed', u'rawfile': u'checkpoint_gaia_show_interfaces_all.raw', u'command': u'show interfaces all'}, {u'path': u'tests/checkpoint_gaia/show_version_all', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_show_version_all.parsed', u'rawfile': u'checkpoint_gaia_show_version_all.raw', u'command': u'show version all'}, {u'path': u'tests/checkpoint_gaia/show_lom', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_show_lom.parsed', u'rawfile': u'checkpoint_gaia_show_lom.raw', u'command': u'show lom'}, {u'path': u'tests/checkpoint_gaia/show_asset_all', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_show_asset_all.parsed', u'rawfile': u'checkpoint_gaia_show_asset_all.raw', u'command': u'show asset all'}, {u'path': u'tests/checkpoint_gaia/fw_stat', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_fw_stat.parsed', u'rawfile': u'checkpoint_gaia_fw_stat.raw', u'command': u'fw stat'}, {u'path': u'tests/checkpoint_gaia/show_ntp_servers', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_show_ntp_servers.parsed', u'rawfile': u'checkpoint_gaia_show_ntp_servers.raw', u'command': u'show ntp servers'}, {u'path': u'tests/checkpoint_gaia/show_domainname', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_show_domainname.parsed', u'rawfile': u'checkpoint_gaia_show_domainname.raw', u'command': u'show domainname'}, {u'path': u'tests/checkpoint_gaia/show_route', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_show_route.parsed', u'rawfile': u'checkpoint_gaia_show_route.raw', u'command': u'show route'}, {u'path': u'tests/checkpoint_gaia/show_dns', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_show_dns.parsed', u'rawfile': u'checkpoint_gaia_show_dns.raw', u'command': u'show dns'}, {u'path': u'tests/checkpoint_gaia/show_ipv6_route', u'platform': u'checkpoint_gaia', u'parsedfile': u'checkpoint_gaia_show_ipv6_route.parsed', u'rawfile': u'checkpoint_gaia_show_ipv6_route.raw', u'command': u'show ipv6 route'}, {u'path': u'tests/cisco_wlc_ssh/show_sysinfo', u'platform': u'cisco_wlc_ssh', u'parsedfile': u'cisco_wlc_ssh_show_sysinfo.parsed', u'rawfile': u'cisco_wlc_ssh_show_sysinfo.raw', u'command': u'show sysinfo'}, {u'path': u'tests/cisco_wlc_ssh/show_ap_config_general', u'platform': u'cisco_wlc_ssh', u'parsedfile': u'cisco_wlc_ssh_show_ap_config_general.parsed', u'rawfile': u'cisco_wlc_ssh_show_ap_config_general.raw', u'command': u'show ap config general'}, {u'path': u'tests/cisco_wlc_ssh/show_ap_summary', u'platform': u'cisco_wlc_ssh', u'parsedfile': u'cisco_wlc_ssh_show_ap_summary.parsed', u'rawfile': u'cisco_wlc_ssh_show_ap_summary.raw', u'command': u'show ap summary'}, {u'path': u'tests/cisco_wlc_ssh/show_cdp_neighbors_detail', u'platform': u'cisco_wlc_ssh', u'parsedfile': u'cisco_wlc_ssh_show_cdp_neighbors_detail.parsed', u'rawfile': u'cisco_wlc_ssh_show_cdp_neighbors_detail.raw', u'command': u'show cdp neighbors detail'}, {u'path': u'tests/juniper_junos/show_arp_no-resolve', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_arp_no-resolve.parsed', u'rawfile': u'juniper_junos_show_arp_no-resolve.raw', u'command': u'show arp no-resolve'}, {u'path': u'tests/juniper_junos/show_interfaces', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_interfaces.parsed', u'rawfile': u'juniper_junos_show_interfaces.raw', u'command': u'show interfaces'}, {u'path': u'tests/juniper_junos/show_version', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_version.parsed', u'rawfile': u'juniper_junos_show_version.raw', u'command': u'show version'}, {u'path': u'tests/juniper_junos/show_chassis_cluster_interfaces', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_chassis_cluster_interfaces2.parsed', u'rawfile': u'juniper_junos_show_chassis_cluster_interfaces2.raw', u'command': u'show chassis cluster interfaces'}, {u'path': u'tests/juniper_junos/show_chassis_cluster_interfaces', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_chassis_cluster_interfaces3.parsed', u'rawfile': u'juniper_junos_show_chassis_cluster_interfaces3.raw', u'command': u'show chassis cluster interfaces'}, {u'path': u'tests/juniper_junos/show_chassis_cluster_interfaces', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_chassis_cluster_interfaces.parsed', u'rawfile': u'juniper_junos_show_chassis_cluster_interfaces.raw', u'command': u'show chassis cluster interfaces'}, {u'path': u'tests/juniper_junos/show_chassis_cluster_interfaces', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_chassis_cluster_interfaces4.parsed', u'rawfile': u'juniper_junos_show_chassis_cluster_interfaces4.raw', u'command': u'show chassis cluster interfaces'}, {u'path': u'tests/juniper_junos/show_chassis_cluster_status', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_chassis_cluster_status.parsed', u'rawfile': u'juniper_junos_show_chassis_cluster_status.raw', u'command': u'show chassis cluster status'}, {u'path': u'tests/juniper_junos/show_chassis_firmware', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_chassis_firmware.parsed', u'rawfile': u'juniper_junos_show_chassis_firmware.raw', u'command': u'show chassis firmware'}, {u'path': u'tests/juniper_junos/show_ospf_neighbor', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_ospf_neighbor.parsed', u'rawfile': u'juniper_junos_show_ospf_neighbor.raw', u'command': u'show ospf neighbor'}, {u'path': u'tests/juniper_junos/show_isis_adjacency', u'platform': u'juniper_junos', u'parsedfile': u'juniper_junos_show_isis_adjacency.parsed', u'rawfile': u'juniper_junos_show_isis_adjacency.raw', u'command': u'show isis adjacency'}, {u'path': u'tests/cisco_nxos/show_ip_community-list', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_community-list.parsed', u'rawfile': u'cisco_nxos_show_ip_community-list.raw', u'command': u'show ip community-list'}, {u'path': u'tests/cisco_nxos/show_ip_bgp', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_bgp.parsed', u'rawfile': u'cisco_nxos_show_ip_bgp.raw', u'command': u'show ip bgp'}, {u'path': u'tests/cisco_nxos/show_lldp_neighbors_detail', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_lldp_neighbors_detail.parsed', u'rawfile': u'cisco_nxos_show_lldp_neighbors_detail.raw', u'command': u'show lldp neighbors detail'}, {u'path': u'tests/cisco_nxos/show_cts_interface_all', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_cts_interface_all.parsed', u'rawfile': u'cisco_nxos_show_cts_interface_all.raw', u'command': u'show cts interface all'}, {u'path': u'tests/cisco_nxos/show_ip_route', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_route.parsed', u'rawfile': u'cisco_nxos_show_ip_route.raw', u'command': u'show ip route'}, {u'path': u'tests/cisco_nxos/show_cts_interface_brief', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_cts_interface_brief.parsed', u'rawfile': u'cisco_nxos_show_cts_interface_brief.raw', u'command': u'show cts interface brief'}, {u'path': u'tests/cisco_nxos/show_l2rib_internal_permanently-frozen-list', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_l2rib_internal_permanently-frozen-list.parsed', u'rawfile': u'cisco_nxos_show_l2rib_internal_permanently-frozen-list.raw', u'command': u'show l2rib internal permanently-frozen-list'}, {u'path': u'tests/cisco_nxos/show_fex', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_fex.parsed', u'rawfile': u'cisco_nxos_show_fex.raw', u'command': u'show fex'}, {u'path': u'tests/cisco_nxos/show_vlan', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_vlan.parsed', u'rawfile': u'cisco_nxos_show_vlan.raw', u'command': u'show vlan'}, {u'path': u'tests/cisco_nxos/show_port-channel_summary', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_port-channel_summary.parsed', u'rawfile': u'cisco_nxos_show_port-channel_summary.raw', u'command': u'show port-channel summary'}, {u'path': u'tests/cisco_nxos/show_port-channel_summary', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_port-channel_summary2.parsed', u'rawfile': u'cisco_nxos_show_port-channel_summary2.raw', u'command': u'show port-channel summary'}, {u'path': u'tests/cisco_nxos/show_cdp_neighbors', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_cdp_neighbors2.parsed', u'rawfile': u'cisco_nxos_show_cdp_neighbors2.raw', u'command': u'show cdp neighbors'}, {u'path': u'tests/cisco_nxos/show_cdp_neighbors', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_cdp_neighbors.parsed', u'rawfile': u'cisco_nxos_show_cdp_neighbors.raw', u'command': u'show cdp neighbors'}, {u'path': u'tests/cisco_nxos/show_ip_arp_detail', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_arp_detail.parsed', u'rawfile': u'cisco_nxos_show_ip_arp_detail.raw', u'command': u'show ip arp detail'}, {u'path': u'tests/cisco_nxos/show_interface_status', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_interface_status.parsed', u'rawfile': u'cisco_nxos_show_interface_status.raw', u'command': u'show interface status'}, {u'path': u'tests/cisco_nxos/show_interface_status', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_interface_status1.parsed', u'rawfile': u'cisco_nxos_show_interface_status1.raw', u'command': u'show interface status'}, {u'path': u'tests/cisco_nxos/show_configuration_session_summary', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_configuration_session_summary.parsed', u'rawfile': u'cisco_nxos_show_configuration_session_summary.raw', u'command': u'show configuration session summary'}, {u'path': u'tests/cisco_nxos/show_version', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_version.parsed', u'rawfile': u'cisco_nxos_show_version.raw', u'command': u'show version'}, {u'path': u'tests/cisco_nxos/show_fex_id', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_fex_id.parsed', u'rawfile': u'cisco_nxos_show_fex_id.raw', u'command': u'show fex id'}, {u'path': u'tests/cisco_nxos/show_flogi_database', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_flogi_database.parsed', u'rawfile': u'cisco_nxos_show_flogi_database.raw', u'command': u'show flogi database'}, {u'path': u'tests/cisco_nxos/show_access-lists', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_access-lists.parsed', u'rawfile': u'cisco_nxos_show_access-lists.raw', u'command': u'show access-lists'}, {u'path': u'tests/cisco_nxos/show_hostname', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_hostname.parsed', u'rawfile': u'cisco_nxos_show_hostname.raw', u'command': u'show hostname'}, {u'path': u'tests/cisco_nxos/show_ip_ospf_database', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_ospf_database.parsed', u'rawfile': u'cisco_nxos_show_ip_ospf_database.raw', u'command': u'show ip ospf database'}, {u'path': u'tests/cisco_nxos/show_vrf', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_vrf.parsed', u'rawfile': u'cisco_nxos_show_vrf.raw', u'command': u'show vrf'}, {u'path': u'tests/cisco_nxos/show_interface', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_interface.parsed', u'rawfile': u'cisco_nxos_show_interface.raw', u'command': u'show interface'}, {u'path': u'tests/cisco_nxos/show_interface', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_interface2.parsed', u'rawfile': u'cisco_nxos_show_interface2.raw', u'command': u'show interface'}, {u'path': u'tests/cisco_nxos/show_ip_dhcp_relay_address', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_dhcp_relay_address.parsed', u'rawfile': u'cisco_nxos_show_ip_dhcp_relay_address.raw', u'command': u'show ip dhcp relay address'}, {u'path': u'tests/cisco_nxos/show_processes_cpu', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_processes_cpu.parsed', u'rawfile': u'cisco_nxos_show_processes_cpu.raw', u'command': u'show processes cpu'}, {u'path': u'tests/cisco_nxos/show_inventory', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_inventory.parsed', u'rawfile': u'cisco_nxos_show_inventory.raw', u'command': u'show inventory'}, {u'path': u'tests/cisco_nxos/show_environment_temperature', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_environment_temperature.parsed', u'rawfile': u'cisco_nxos_show_environment_temperature.raw', u'command': u'show environment temperature'}, {u'path': u'tests/cisco_nxos/show_vpc', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_vpc.parsed', u'rawfile': u'cisco_nxos_show_vpc.raw', u'command': u'show vpc'}, {u'path': u'tests/cisco_nxos/show_ipv6_interface_brief', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ipv6_interface_brief.parsed', u'rawfile': u'cisco_nxos_show_ipv6_interface_brief.raw', u'command': u'show ipv6 interface brief'}, {u'path': u'tests/cisco_nxos/show_feature', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_feature.parsed', u'rawfile': u'cisco_nxos_show_feature.raw', u'command': u'show feature'}, {u'path': u'tests/cisco_nxos/show_interface_brief', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_interface_brief.parsed', u'rawfile': u'cisco_nxos_show_interface_brief.raw', u'command': u'show interface brief'}, {u'path': u'tests/cisco_nxos/show_module', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_module.parsed', u'rawfile': u'cisco_nxos_show_module.raw', u'command': u'show module'}, {u'path': u'tests/cisco_nxos/show_lldp_neighbors', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_lldp_neighbors.parsed', u'rawfile': u'cisco_nxos_show_lldp_neighbors.raw', u'command': u'show lldp neighbors'}, {u'path': u'tests/cisco_nxos/show_interface_transceiver_details', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_interface_transceiver_details.parsed', u'rawfile': u'cisco_nxos_show_interface_transceiver_details.raw', u'command': u'show interface transceiver details'}, {u'path': u'tests/cisco_nxos/show_ip_bgp_summary', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_bgp_summary.parsed', u'rawfile': u'cisco_nxos_show_ip_bgp_summary.raw', u'command': u'show ip bgp summary'}, {u'path': u'tests/cisco_nxos/show_ip_arp', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_arp.parsed', u'rawfile': u'cisco_nxos_show_ip_arp.raw', u'command': u'show ip arp'}, {u'path': u'tests/cisco_nxos/show_ip_ospf_neighbor_vrf_all', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_ospf_neighbor_vrf_all.parsed', u'rawfile': u'cisco_nxos_show_ip_ospf_neighbor_vrf_all.raw', u'command': u'show ip ospf neighbor vrf all'}, {u'path': u'tests/cisco_nxos/show_clock', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_clock.parsed', u'rawfile': u'cisco_nxos_show_clock.raw', u'command': u'show clock'}, {u'path': u'tests/cisco_nxos/show_environments', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_environments.parsed', u'rawfile': u'cisco_nxos_show_environments.raw', u'command': u'show environments'}, {u'path': u'tests/cisco_nxos/show_cdp_neighbors_detail', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_cdp_neighbors_detail.parsed', u'rawfile': u'cisco_nxos_show_cdp_neighbors_detail.raw', u'command': u'show cdp neighbors detail'}, {u'path': u'tests/cisco_nxos/show_ip_bgp_neighbors', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_ip_bgp_neighbors.parsed', u'rawfile': u'cisco_nxos_show_ip_bgp_neighbors.raw', u'command': u'show ip bgp neighbors'}, {u'path': u'tests/cisco_nxos/show_mac_address-table', u'platform': u'cisco_nxos', u'parsedfile': u'cisco_nxos_show_mac_address-table.parsed', u'rawfile': u'cisco_nxos_show_mac_address-table.raw', u'command': u'show mac address-table'}, {u'path': u'tests/vmware_nsxv/show_ip_route', u'platform': u'vmware_nsxv', u'parsedfile': u'vmware_nsxv_show_ip_route1.parsed', u'rawfile': u'vmware_nsxv_show_ip_route1.raw', u'command': u'show ip route'}, {u'path': u'tests/vmware_nsxv/show_ip_route', u'platform': u'vmware_nsxv', u'parsedfile': u'vmware_nsxv_show_ip_route2.parsed', u'rawfile': u'vmware_nsxv_show_ip_route2.raw', u'command': u'show ip route'}, {u'path': u'tests/vmware_nsxv/show_ip_route', u'platform': u'vmware_nsxv', u'parsedfile': u'vmware_nsxv_show_ip_route.parsed', u'rawfile': u'vmware_nsxv_show_ip_route.raw', u'command': u'show ip route'}, {u'path': u'tests/vmware_nsxv/show_ip_bgp_neighbors', u'platform': u'vmware_nsxv', u'parsedfile': u'vmware_nsxv_show_ip_bgp_neighbors.parsed', u'rawfile': u'vmware_nsxv_show_ip_bgp_neighbors.raw', u'command': u'show ip bgp neighbors'}, {u'path': u'tests/juniper_screenos/get_route', u'platform': u'juniper_screenos', u'parsedfile': u'juniper_screenos_get_route.parsed', u'rawfile': u'juniper_screenos_get_route.raw', u'command': u'get route'}, {u'path': u'tests/aruba_os/show_ip_int_brief', u'platform': u'aruba_os', u'parsedfile': u'aruba_os_show_ip_int_brief.parsed', u'rawfile': u'aruba_os_show_ip_int_brief.raw', u'command': u'show ip int brief'}, {u'path': u'tests/aruba_os/show_ipv6_int_brief', u'platform': u'aruba_os', u'parsedfile': u'aruba_os_show_ipv6_int_brief.parsed', u'rawfile': u'aruba_os_show_ipv6_int_brief.raw', u'command': u'show ipv6 int brief'}, {u'path': u'tests/ubiquiti_edgeswitch/show_vlans', u'platform': u'ubiquiti_edgeswitch_show_vlan', u'parsedfile': u'ubiquiti_edgeswitch_show_vlan.parsed', u'rawfile': u'ubiquiti_edgeswitch_show_vlan.raw', u'command': u'show vlans'}, {u'path': u'tests/ubiquiti_edgeswitch/show_arp', u'platform': u'ubiquiti_edgeswitch', u'parsedfile': u'ubiquiti_edgeswitch_show_arp.parsed', u'rawfile': u'ubiquiti_edgeswitch_show_arp.raw', u'command': u'show arp'}, {u'path': u'tests/avaya_vsp/show_software', u'platform': u'avaya_vsp', u'parsedfile': u'avaya_vsp_show_software.parsed', u'rawfile': u'avaya_vsp_show_software.raw', u'command': u'show software'}, {u'path': u'tests/alcatel_aos/show_vlan', u'platform': u'alcatel_aos', u'parsedfile': u'alcatel_aos_show_vlan.parsed', u'rawfile': u'alcatel_aos_show_vlan.raw', u'command': u'show vlan'}, {u'path': u'tests/alcatel_sros/show_router_bgp_routes_vpn-ipv4', u'platform': u'alcatel_sros', u'parsedfile': u'alcatel_sros_show_router_bgp_routes_vpn-ipv4.parsed', u'rawfile': u'alcatel_sros_show_router_bgp_routes_vpn-ipv4.raw', u'command': u'show router bgp routes vpn-ipv4'}, {u'path': u'tests/alcatel_sros/oam_mac-ping', u'platform': u'alcatel_sros', u'parsedfile': u'alcatel_sros_oam_mac-ping.parsed', u'rawfile': u'alcatel_sros_oam_mac-ping.raw', u'command': u'oam mac-ping'}, {u'path': u'tests/alcatel_sros/show_service_id_base', u'platform': u'alcatel_sros', u'parsedfile': u'alcatel_sros_show_service_id_base.parsed', u'rawfile': u'alcatel_sros_show_service_id_base.raw', u'command': u'show service id base'}, {u'path': u'tests/dell_force10/show_vlan', u'platform': u'dell_force10', u'parsedfile': u'dell_force10_show_vlan.parsed', u'rawfile': u'dell_force10_show_vlan.raw', u'command': u'show vlan'}, {u'path': u'tests/dell_force10/show_vlan', u'platform': u'dell_force10', u'parsedfile': u'dell_force10_show_vlan_1.parsed', u'rawfile': u'dell_force10_show_vlan_1.raw', u'command': u'show vlan'}, {u'path': u'tests/dell_force10/show_version', u'platform': u'dell_force10', u'parsedfile': u'dell_force10_show_version.parsed', u'rawfile': u'dell_force10_show_version.raw', u'command': u'show version'}, {u'path': u'tests/dell_force10/show_arp', u'platform': u'dell_force10', u'parsedfile': u'dell_force10_show_arp.parsed', u'rawfile': u'dell_force10_show_arp.raw', u'command': u'show arp'}, {u'path': u'tests/dell_force10/show_vlan_brief', u'platform': u'dell_force10', u'parsedfile': u'dell_force10_show_vlan_brief.parsed', u'rawfile': u'dell_force10_show_vlan_brief.raw', u'command': u'show vlan brief'}, {u'path': u'tests/__pycache__', u'platform': u'test_structured_data_against_parsed_reference_files.cpython-27-PYTEST.pyc', u'parsedfile': u'test_structured_data_against_parsed_reference_files.cpython-27-PYTEST.pyc', u'rawfile': u'test_structured_data_against_parsed_reference_files.cpython-27-PYTEST.pyc.raw', u'command': u'  pycache  '}, {u'path': u'tests/hp_comware/display_clock', u'platform': u'hp_comware', u'parsedfile': u'hp_comware_display_clock.parsed', u'rawfile': u'hp_comware_display_clock.raw', u'command': u'display clock'}, {u'path': u'tests/hp_comware/display_mac-address', u'platform': u'hp_comware', u'parsedfile': u'hp_comware_display_mac-address.parsed', u'rawfile': u'hp_comware_display_mac-address.raw', u'command': u'display mac-address'}, {u'path': u'tests/hp_comware/display_vlan_bri', u'platform': u'hp_comware', u'parsedfile': u'hp_comware_display_vlan_brief.parsed', u'rawfile': u'hp_comware_display_vlan_brief.raw', u'command': u'display vlan bri'}, {u'path': u'tests/hp_comware/display_arp', u'platform': u'hp_comware', u'parsedfile': u'hp_comware_display_arp.parsed', u'rawfile': u'hp_comware_display_arp.raw', u'command': u'display arp'}, {u'path': u'tests/hp_comware/display_vlan_brief', u'platform': u'hp_comware', u'parsedfile': u'hp_comware_display_vlan_brief.parsed', u'rawfile': u'hp_comware_display_vlan_brief.raw', u'command': u'display vlan brief'}]}}}
FAILED
file=tests/__pycache__/test_structured_data_against_parsed_reference_files.cpython-27-PYTEST.pyc.raw
{'dark': {}, 'contacted': {'localhost': {u'failed': True, u'msg': u'could not read raw text file', 'invocation': {'module_name': 'ntc_show_command', 'module_args': u"file=tests/__pycache__/test_structured_data_against_parsed_reference_files.cpython-27-PYTEST.pyc.raw template_dir=templates/ command='  pycache  ' connection=offline platform=test_structured_data_against_parsed_reference_files.cpython-27-PYTEST.pyc"}}}}
ERROR: InvocationError: '/home/alanr/Charter/networktocode/ntc-templates/.tox/py27/bin/python test-templates.py'
______________________________________________________________________________________ summary ______________________________________________________________________________________
ERROR:   py27: commands failed

real    4m51.058s
user    2m20.479s
sys     0m47.946s

cisco_nxos_show_interface_status.template: error on 10G and 40G interfaces

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value PORT (\S+)
Value NAME (.*?)
Value STATUS (\S+)
Value VLAN (\d+|routed|trunk)
Value DUPLEX (\S+)
Value SPEED (\d+|auto)
Value TYPE (.+?)

Start
  ^[Pp]ort\s+[Nn]ame\s+[Ss]tatus\s+[Vv]lan\s+[Dd]uplex\s+[Ss]peed\s+[Tt]ype\s*$$ -> INTFS
  ^-+\s*$$
  ^$$
  ^.*$$ -> Error

INTFS
  ^${PORT}\s+${NAME}\s+${STATUS}\s+${VLAN}\s+${DUPLEX}\s+${SPEED}\s+${TYPE}\s*$$ -> Record
  ^-+\s*$$
  ^$$
  ^.*$$ -> Error

SAMPLE COMMAND OUTPUT
--------------------------------------------------------------------------------
Port          Name               Status    Vlan      Duplex  Speed   Type
--------------------------------------------------------------------------------
mgmt0         --                 connected routed    full    1000    --
Eth1/1        interface1         connected trunk     full    10G     10Gbase-SR-S
Eth1/2        interface2         connected trunk     full    10G     10Gbase-SR-S
Eth1/3        interface3         connected trunk     full    10G     10Gbase-SR
Eth1/4        interface4         connected trunk     full    10G     10Gbase-SR
Eth1/5        interface5         connected trunk     full    10G     10Gbase-SR-S
Eth1/6        interface6         connected trunk     full    10G     10Gbase-SR-S
Eth1/7        interface7         connected trunk     full    10G     10Gbase-SR-S
Eth1/8        interface8         connected trunk     full    10G     10Gbase-SR-S


SUMMARY

cisco_nxos_show_interface_status.template throws an error on 10G and 40G interfaces

STEPS TO REPRODUCE
$ textfsm.py templates/cisco_nxos_show_interface_status.template tests/cisco_nxos/show_interface_status/cisco_nxos_show_interface_status1.raw
EXPECTED RESULTS

No error

ACTUAL RESULTS
FSM Template:
Value PORT (\S+)
Value NAME (.*?)
Value STATUS (\S+)
Value VLAN (\d+|routed|trunk)
Value DUPLEX (\S+)
Value SPEED (\d+|auto)
Value TYPE (.+?)

Start
  ^[Pp]ort\s+[Nn]ame\s+[Ss]tatus\s+[Vv]lan\s+[Dd]uplex\s+[Ss]peed\s+[Tt]ype\s*$$ -> INTFS
  ^-+\s*$$
  ^$$
  ^.*$$ -> Error

INTFS
  ^${PORT}\s+${NAME}\s+${STATUS}\s+${VLAN}\s+${DUPLEX}\s+${SPEED}\s+${TYPE}\s*$$ -> Record
  ^-+\s*$$
  ^$$
  ^.*$$ -> Error


State Error raised. Rule Line: 19. Input Line: Eth1/1        interface1  connected trunk     full    10G     10Gbase-SR-S

Need an info

Hi Jason

any idea how do we parse the Build from the CISCO show version command ?
Any help on this would be greatly appreciated .

because
My template has the content below

Value Model (\S+)
Value Uptime (.)
Value sn (.
)
Value OS (\S+)
Value build ((.))
Value version (\d+.\d+(.+).
)

Start
^Cisco IOS Software.Software ${build},
^.uptime is ${Uptime}
^cisco ${Model} .

^Processor board ID ${sn}
^ROM: ${OS}.

^.Software\s.+),\sVersion\s${version}, RELEASE.
the textFSM wont parse the build and version if they are found at the same line

this is what the output i have got it

[u'Model', u'Uptime', u'sn', u'OS', u'build', u'version']
['CSR1000V', '1 week, 1 hour, 9 minutes', '9ZU0WTKPGYO', 'IOS-XE', '(X86_64_LINUX_IOSD-UNIVERSALK9-M', u'']

No version information is parsed .

Could you please help on this ?

NXOS-Show_Interfaces not finding Vlan Interfaces when additional interfaces are past the config. Also potential to provide wrong information.

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value Required INTERFACE (\S+)
Value LINK_STATUS (\w+)
Value ADMIN_STATE (\S+)
Value HARDWARE_TYPE (.*)
Value ADDRESS ([a-zA-Z0-9]+.[a-zA-Z0-9]+.[a-zA-Z0-9]+)
Value BIA ([a-zA-Z0-9]+.[a-zA-Z0-9]+.[a-zA-Z0-9]+)
Value DESCRIPTION (.*)
Value IP_ADDRESS (\d+\.\d+\.\d+\.\d+\/\d+)
Value MTU (\d+)
Value DUPLEX (.+duplex?)
Value SPEED (.+?)
Value BANDWIDTH (\d+\s+\w+)
Value DELAY (\d+\s+\w+)
Value ENCAPSULATION (\w+)

Start
  ^${INTERFACE}\s+is\s+${LINK_STATUS}
  ^admin\s+state\s+is\s+${ADMIN_STATE},
  ^\s+Hardware(:|\s+is)\s+${HARDWARE_TYPE},\s+address(:|\s+is)\s+${ADDRESS}(.*bia\s+${BIA})*
  ^\s+Description:\s+${DESCRIPTION}
  ^\s+Internet\s+Address\s+is\s+${IP_ADDRESS}
  ^\s+${DUPLEX}, ${SPEED}(,|$$)
  ^\s+MTU\s+${MTU}.*BW\s+${BANDWIDTH}.*DLY\s+${DELAY}
  ^\s+Encapsulation\s+${ENCAPSULATION}
  ^\s+Last -> Record
  ^\s+Rx -> Record
SAMPLE COMMAND OUTPUT

Vlan1 is down (Administratively down), line protocol is down
  Hardware is EtherSVI, address is  00de.fb01.c9bc
  MTU 1500 bytes, BW 1000000 Kbit, DLY 10 usec

Vlan330 is up, line protocol is up
  Hardware is EtherSVI, address is  00de.fb01.c921
  Internet Address is 192.168.1.3/24
  MTU 1500 bytes, BW 1000000 Kbit, DLY 10 usec

Vlan336 is up, line protocol is up
  Hardware is EtherSVI, address is  00de.fb01.c933
  Internet Address is 192.168.2.3/24
  MTU 1500 bytes, BW 1000000 Kbit, DLY 10 usec

Vlan339 is up, line protocol is up
  Hardware is EtherSVI, address is  00de.fb01.c9ab
  Internet Address is 192.168.3.3/24
  MTU 1500 bytes, BW 1000000 Kbit, DLY 10 usec

Vlan300 is up, line protocol is up
  Hardware is EtherSVI, address is  00de.fb01.c9ef
  Internet Address is 192.168.24.1/24
  MTU 1500 bytes, BW 1000000 Kbit, DLY 10 usec

Ethernet106/1/1 is down (Link not connected)
  Hardware: 10/100/1000 Ethernet, address: 0000.d200.0000 (bia 0000.d200.0000)
  MTU 1500 bytes, BW 23 Kbit, DLY 10 usec
  reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation ARPA
  Port mode is access
  auto-duplex, auto-speed
  Beacon is turned off
  Input flow-control is off, output flow-control is on
  Switchport monitor is off 
  EtherType is 0x8100 
  Last link flapped 14week(s) 5day(s)
  Last clearing of "show interface" counters never
  9 interface resets
  30 seconds input rate 0 bits/sec, 0 packets/sec
  30 seconds output rate 0 bits/sec, 0 packets/sec
  Load-Interval #2: 5 minute (300 seconds)
    input rate 0 bps, 0 pps; output rate 0 bps, 0 pps
  RX
    18476 unicast packets  506094 multicast packets  362760 broadcast packets
    887330 input packets  70500074 bytes
    2 jumbo packets  0 storm suppression bytes
    0 runts  0 giants  0 CRC  0 no buffer
    0 input error  0 short frame  0 overrun   0 underrun  0 ignored
    0 watchdog  0 bad etype drop  0 bad proto drop  0 if down drop
    0 input with dribble  0 input discard
    0 Rx pause
  TX
    17841 unicast packets  5660600 multicast packets  339717 broadcast packets
    6018158 output packets  711823811 bytes
    0 jumbo packets
    0 output error  0 collision  0 deferred  0 late collision
    0 lost carrier  0 no carrier  0 babble 0 output discard
    0 Tx pause
SUMMARY

When the VLAN interface on show interfaces is in the middle of a section, TextFSM does not detect the VLAN interface. When it does pick up the VLAN interface is when the VLAN is the last item in the list.

Also just noticed, that with the sample provided above that the ip address detected and assigned to the physical interface was the VLAN IP address.

{'address': '0041.d23f.b4d1',
'admin_state': '',
'bandwidth': '23 Kbit',
'bia': '0041.d23f.b4d1',
'delay': '10 usec',
'description': '',
'duplex': 'auto-duplex',
'encapsulation': 'ARPA',
'hardware_type': '10/100/1000 Ethernet',
'interface': 'Ethernet106/1/48',
'ip_address': '',
'link_status': 'down',
'mtu': '1500',
'speed': 'auto-speed'}

STEPS TO REPRODUCE

Ran the information pasted above through a textfsm parser as referenced in the Netmiko slack channel.

Originally I had developed a script to add IP addresses to Netbox that was not populating the Vlan information, and found that the template was not finding the Vlan information unless the Vlan was the last interface.

import textfsm
import pprint

input_file = open("tests//cisco_nxos//cisco_nxos_show_interface.raw")
raw_text_data = input_file.read()
input_file.close()

fsm_template = open('cisco_nxos_show_interface.template')
fsm_table = textfsm.TextFSM(fsm_template)
fsm_results = fsm_table.ParseText(raw_text_data)

with open('data.yml', 'w') as outfile:
    for row in fsm_results:
        temp_dict = {}
        
        for index, element in enumerate(row):
            temp_dict[fsm_table.header[index].lower()] = element
        
        print '\n'
        pprint.pprint(temp_dict)
EXPECTED RESULTS

I expected to see outputs for 5 VLAN interfaces.

ACTUAL RESULTS

There are no VLANs and the VLAN IP address is assigned to the first physical interface after the VLANs in the output.

{'address': '0000.d200.0000',
 'admin_state': '',
 'bandwidth': '23 Kbit',
 'bia': '0000.d200.0000',
 'delay': '10 usec',
 'description': '',
 'duplex': 'auto-duplex',
 'encapsulation': 'ARPA',
 'hardware_type': '10/100/1000 Ethernet',
 'interface': 'Ethernet106/1/1',
 'ip_address': '192.168.24.1/24',
 'link_status': 'down',
 'mtu': '1500',
 'speed': 'auto-speed'}


{'address': '0041.d23f.b4d1',
 'admin_state': '',
 'bandwidth': '23 Kbit',
 'bia': '0041.d23f.b4d1',
 'delay': '10 usec',
 'description': '',
 'duplex': 'auto-duplex',
 'encapsulation': 'ARPA',
 'hardware_type': '10/100/1000 Ethernet',
 'interface': 'Ethernet106/1/48',
 'ip_address': '',
 'link_status': 'down',
 'mtu': '1500',
 'speed': 'auto-speed'}

Cisco ASA show version template

ISSUE TYPE
  • Template Creation Help
SUMMARY

Would like to have a cisco ASA show version template.
I am happy to work on this if no one else is already doing it.

Template update: cisco_ios_show_vlan to get interface list

Hello,

I am trying to improve your template called cisco_ios_show_vlan.template to get interface list for each VLAN
You can see that this file cisco_ios_show_vlan.raw contains "Ports" column.

ISSUE TYPE

I have an issue with the Template Creation

TEMPLATE USING
Value VLAN_ID (\d+)
Value NAME (\S+)
Value STATUS (\S+)
Value List PORTS (\S.+)

Start
  ^VLAN\s+Type -> Done
  ^${VLAN_ID}\s+${NAME}\s+${STATUS}\s+$PORTS -> Record
  ^\s+$PORTS -> Record
SAMPLE COMMAND OUTPUT
VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
1    default                          active    Gi0/1
10   Management                       active    
50   VLan50                           active    Fa0/1, Fa0/2, Fa0/3, Fa0/4, Fa0/5, Fa0/6, Fa0/7, Fa0/8, Fa0/9
                                                Fa0/10, Fa0/11, Fa0/12
60   VLan60                           active    Fa0/13, Fa0/14, Fa0/15, Fa0/16, Fa0/17, Fa0/18, Fa0/19, Fa0/20
                                                Fa0/21, Fa0/22, Fa0/23, Fa0/24
1002 fddi-default                     act/unsup 
1003 token-ring-default               act/unsup 
1004 fddinet-default                  act/unsup 
1005 trnet-default                    act/unsup 

VLAN Type  SAID       MTU   Parent RingNo BridgeNo Stp  BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------
1    enet  100001     1500  -      -      -        -    -        0      0   
10   enet  100010     1500  -      -      -        -    -        0      0   
50   enet  100050     1500  -      -      -        -    -        0      0   
60   enet  100060     1500  -      -      -        -    -        0      0   
1002 fddi  101002     1500  -      -      -        -    -        0      0   
1003 tr    101003     1500  -      -      -        -    srb      0      0   
1004 fdnet 101004     1500  -      -      -        ieee -        0      0   
1005 trnet 101005     1500  -      -      -        ibm  -        0      0   

Remote SPAN VLANs
------------------------------------------------------------------------------


Primary Secondary Type              Ports
------- --------- ----------------- ------------------------------------------
SUMMARY

I new some help to fix my template proposal because I don't how to copy VLAN_ID variable for the second to N row for each VLAN.

STEPS TO REPRODUCE

Apply the previous template against cisco_ios_show_vlan.raw

EXPECTED RESULTS
---
parsed_sample:

 - vlan_id: '1'
   name: 'default'
   status: 'active'
   ports: 'Gi0/1'

 - vlan_id: '10'
   name: 'Management'
   status: 'active'

 - vlan_id: '50'
   name: 'VLan50'
   status: 'active'
   ports: Fa0/1, Fa0/2, Fa0/3, Fa0/4, Fa0/5, Fa0/6, Fa0/7, Fa0/8, Fa0/9, Fa0/10, Fa0/11, Fa0/12

 - vlan_id: '60'
   name: 'VLan60'
   status: 'active'
   ports: Fa0/13, Fa0/14, Fa0/15, Fa0/16, Fa0/17, Fa0/18, Fa0/19, Fa0/20, Fa0/21, Fa0/22, Fa0/23, Fa0/24

 - vlan_id: '1002'
   name: 'fddi-default'
   status: 'act/unsup'

 - vlan_id: '1003'
   name: 'token-ring-default'
   status: 'act/unsup'

 - vlan_id: '1004'
   name: 'fddinet-default'
   status: 'act/unsup'

 - vlan_id: '1005'
   name: 'trnet-default'
   status: 'act/unsup'
ACTUAL RESULTS

Regards,
Ludovic

Multiple Failing Use Cases in Cisco IOS ACL Template

Using this issue to track progress on fixes.

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value Required,Filldown ACL_TYPE (Standard|Extended)
Value Required,Filldown ACL_NAME (\S+)
Value LINE_NUM (\d+)
Value ACTION (permit|deny)
Value PROTOCOL ([a-z]+)
Value SRC_HOST (\d+\.\d+\.\d+\.\d+)
Value SRC_ANY (any)
Value SRC_NETWORK (\d+\.\d+\.\d+\.\d+)
Value SRC_WILDCARD (\d+\.\d+\.\d+\.\d+)
Value SRC_PORT_MATCH (eq|range|lt|gt)
Value SRC_PORT ((?<!range\s)\S+)
Value SRC_PORT_RANGE_START ((?<!range\s)\S+)
Value SRC_PORT_RANGE_END (\S+)
Value DST_HOST (\d+\.\d+\.\d+\.\d+)
Value DST_ANY (any)
Value DST_NETWORK (\d+\.\d+\.\d+\.\d+)
Value DST_WILDCARD (\d+\.\d+\.\d+\.\d+)
Value DST_PORT_MATCH (eq|range|lt|gt)
Value DST_PORT ((?<!range\s)\S+)
Value DST_PORT_RANGE_START ((?<=range\s)\S+)
Value DST_PORT_RANGE_END (\S+)
Value LOG (log-input|log)
Value TIME (\S+)
Value STATE (inactive|active)


Start
  ^(Standard|Extended) -> Continue.Clearall
  ^${ACL_TYPE}\s+IP\s+access\s+list\s+${ACL_NAME}\s* -> Record
  ^\s+${LINE_NUM}\s+${ACTION}\s+${PROTOCOL}\s+(host\s+${SRC_HOST}|${SRC_ANY}|${SRC_NETWORK}\s+${SRC_WILDCARD})(\s+${SRC_PORT_MATCH}\s+|)(${SRC_PORT_RANGE_START}\s+${SRC_PORT_RANGE_END}|${SRC_PORT}|)\s+(host\s+${DST_HOST}|${DST_ANY}|${DST_NETWORK}\s+${DST_WILDCARD})(\s+${DST_PORT_MATCH}\s+(${DST_PORT_RANGE_START}\s+${DST_PORT_RANGE_END}|${DST_PORT}|)|)(\s+${LOG}|)(\s+time-range\s+${TIME}\s+\(${STATE}\)|)\s* -> Record
  ^\s+${LINE_NUM}\s+${ACTION}\s+(${SRC_NETWORK},\s+wildcard\s+bits\s+${SRC_WILDCARD}|${SRC_HOST}|${SRC_ANY})(\s+{LOG}|)(\s+time-range\s+${TIME}\s+\(${STATE}\)|)\s* -> Record
  ^.* -> Error "Could not parse line:"

EOF
SAMPLE COMMAND OUTPUT
310 permit udp any range 16384 32767 10.XXX.XXX.0 0.0.XXX.XXX range 16384 32767
330 permit udp any eq snmp bootpc 10.XXX.0.0 0.XXX.XXX.XXX
430 permit ip 10.XXX.XXX.XXX 0.XXX.XXX.XXX object-group SOME_APP_IPS
10 permit tcp any any established
SUMMARY

The template fails on source port ranges, multiple port entries (up to 10 allowed on IOS), and object-groups.

STEPS TO REPRODUCE

(using netmiko)

device.send_command('show ip access-list MY_ACL', use_textfsm=True)
EXPECTED RESULTS

Structured data returned from template.

ACTUAL RESULTS

TextFSM failed parsing on all 3 2 scenarios.

textfsm.TextFSMError: Error: "Could not parse line:". Rule Line: 32. Input Line:     310 permit udp any range 16384 32767 10.XXX.XXX.0 0.0.XXX.XXX range 16384 32767.
Error: "Could not parse line:". Rule Line: 32. Input Line:     310 permit udp any range 16384 32767 10.XXX.XXX.0 0.0.XXX.XXX range 16384 32767.
POTENTIAL FIXES
  • Src Port Range: Value SRC_PORT_RANGE_START ((?<=range\s)\S+) (courtesy @jmcgill298)
  • Multiple Ports:
Value SRC_PORT ((?<!range\s)\S+|(\S+(\s\S+){1,9}))
Value DST_PORT ((?<!range\s)\S+|(\S+(\s\S+){1,9}))
  • Object groups: TBD
  • established line: TBD

show_mac_address-table - Output contains single dictionary

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value DESTINATION_ADDRESS ([0-9a-fA-F]{4}\.[0-9a-fA-F]{4}\.[0-9a-fA-F]{4})
Value TYPE (\w+)
Value VLAN (\w+)
Value DESTINATION_PORT (\S+)

Start
  ^Destination\s+Address\s+Address\s+Type\s+VLAN\s+Destination\s+Port -> TYPE1
  ^\s+vlan\s+mac address\s+type\s+learn\s+age\s+ports -> TYPE2
  ^\s+vlan\s+mac address\s+type\s+protocols\s+port -> TYPE3
  ^Vlan\s+Mac Address\s+Type\s+Ports -> TYPE4

TYPE1
  ^${DESTINATION_ADDRESS}\s+${TYPE}\s+${VLAN}\s+${DESTINATION_PORT} -> Record

TYPE2
  ^[\*|\s]\s+${VLAN}\s+${DESTINATION_ADDRESS}\s+${TYPE}\s+\S+\s+\S+\s+${DESTINATION_PORT} -> Record

TYPE3
  ^\s+${VLAN}\s+${DESTINATION_ADDRESS}\s+${TYPE}\s+\S+\s+${DESTINATION_PORT} -> Record

TYPE4
  ^\s+${VLAN}\s+${DESTINATION_ADDRESS}\s+${TYPE}\s+${DESTINATION_PORT} -> Record

SAMPLE COMMAND OUTPUT
dd-r-vss#sh mac address-table
Unicast Entries
 vlan     mac address     type        protocols               port
---------+---------------+--------+---------------------+-------------------------
 950      0008.e3ff.fca8    static ip,ipx,assigned,other Switch
1105      0008.e3ff.fca8    static ip,ipx,assigned,other Switch
1105      0008.e3ff.fcac   dynamic ip,ipx,assigned,other Port-channel30
1106      0008.e3ff.fca8    static ip,ipx,assigned,other Switch
1106      002a.6a8b.e343   dynamic ip,ipx,assigned,other TenGigabitEthernet1/1/1
1171      0008.e3ff.fca8    static ip,ipx,assigned,other Switch
1171      001b.baf8.ca15   dynamic ip,ipx,assigned,other Port-channel41
1171      001b.baf8.ca31   dynamic ip,ipx,assigned,other Port-channel41

SUMMARY

When using this template, the output only produces a list of 1 dictionary of the first entry of the show mac address-table command. FYI... This is in conjunction with the Netmiko

STEPS TO REPRODUCE

mac_int_output = net_conn.send_command("show mac address-table", use_textfsm=True)

EXPECTED RESULTS

[{'destination_address': '0008.e3ff.fca8',
'type': 'static',
'vlan': '950',
'destination_port': 'Switch'}]
[{'destination_address': '0008.e3ff.fca8',
'type': 'static',
'vlan': '1105',
'destination_port': 'Switch'}]

ACTUAL RESULTS
[{'destination_address': '0008.e3ff.fca8',
  'type': 'static',
  'vlan': '950',
  'destination_port': 'Switch'}]

Add tests for index file to Travis

ISSUE TYPE
  • Bug Report
TEMPLATE USING
N/A
SAMPLE COMMAND OUTPUT
N/A
SUMMARY

Travis is not currently validating the index file, so the index file is not formatted properly as new templates are added.

STEPS TO REPRODUCE
EXPECTED RESULTS

Travis to fail due to malformed index file

ACTUAL RESULTS
Travis tests pass

cisco_ios_show_ip_bgp.template some entries are not parsed

ISSUE TYPE
  • Bug Report
TEMPLATE USING

Value Filldown STATUS ([bdhimrsSx*>])
Value Filldown PATH_SELECTION ([bdhimrsSx*> ])
Value Filldown ROUTE_SOURCE ([bdhimrsSx*> ])
Value Filldown NETWORK (\S{0,18})
Value Required NEXT_HOP (\S{0,19})
Value Filldown METRIC (\S{0,6})
Value LOCAL_PREF (\S{0,6})
Value WEIGHT (\S{0,6})
Value AS_PATH (.*?)
Value ORIGIN ([ie?])

Start

Since using mostly position, play it safe and ensure we see header first

^\s+Network\s+Next Hop\s+Metric\s+LocPrf\s+Weight\s+Path -> Bgp_table

Bgp_table

Match if subnet is 17,18 characters long, creates two lines

Example: *>i 10.104.192.208/29

^\s{0,1}${STATUS}${PATH_SELECTION}${ROUTE_SOURCE}\s{0,1}(?=${NETWORK}).{17,18}$$ -> Next

Compliment to previous, status, path_selection, route_source, network is filldown.

Example: 157.191.186.194 0 100 50000 64801 64808 64608 64601 64787 i

^\s{23,25}(?=${NEXT_HOP}).{19}\s(?=\s{0,6}${METRIC}).{6}\s(?=\s{0,6}${LOCAL_PREF}).{6}\s(?=\s{0,6}${WEIGHT}).{6}\s*${AS_PATH}\s*${ORIGIN}$$ -> Record

Match first when there is no network, since previous line had it already (compliment and filldown below)

Example: * i172.16.1.0/24 172.16.1.2 0 100 0 i

^\s{0,1}${STATUS}${PATH_SELECTION}${ROUTE_SOURCE}\s{0,1}\s{16}\s(?=${NEXT_HOP}).{19}\s(?=\s{0,6}${METRIC}).{6}\s(?=\s{0,6}${LOCAL_PREF}).{6}\s(?=\s{0,6}${WEIGHT}).{6}\s*${AS_PATH}\s*${ORIGIN}$$ -> Record

Full normal example. metric, and as_path might not exist, regex defaults to blank line.

Example: *> 0.0.0.0 0 32768 i

^\s{0,1}${STATUS}${PATH_SELECTION}${ROUTE_SOURCE}\s{0,1}(?=${NETWORK}).{16}\s(?=${NEXT_HOP}).{19}\s(?=\s{0,6}${METRIC}).{6}\s(?=\s{0,6}${LOCAL_PREF}).{6}\s(?=\s{0,6}${WEIGHT}).{6}\s*${AS_PATH}\s*${ORIGIN}$$ -> Record

EOF

SAMPLE COMMAND OUTPUT
* i199.16.104.96/27 10.66.166.3              0    100      0 11111 99999 65278 ?
* i                 10.66.166.4              0    100      0 11111 99999 65278 ?
* i                 10.66.166.2              0    100      0 11111 99999 65278 ?
*>                  10.118.160.97                          0 11111 99999 65278 ?
* i199.16.104.128/27
                    10.66.166.3              0    100      0 11111 99999 ?
* i                 10.66.166.4              0    100      0 11111 99999 ?
* i                 10.66.166.2              0    100      0 11111 99999 ?
*>                  10.118.160.97                          0 11111 99999 ?
* i199.16.104.160/27
                    10.66.166.3              0    100      0 11111 99999 ?
* i                 10.66.166.4              0    100      0 11111 99999 ?
* i                 10.66.166.2              0    100      0 11111 99999 ?
*>                  10.118.160.97                          0 11111 99999 ?

Parsed output (the issue is with prefix 199.16.104.128/27 (this is not an actual public ip, pure for demonstration purposes), 4 paths in "show_ip_bgp" output, but only 3 paths are parsed

['*', ' ', 'i', '199.16.104.96/27', '10.66.166.4', '0', '100', '0', '11111 99999 65278', '?']
['*', ' ', 'i', '199.16.104.96/27', '10.66.166.2', '0', '100', '0', '11111 99999 65278', '?']
['*', '>', ' ', '199.16.104.96/27', '10.118.160.97', '', '', '0', '11111 99999 65278', '?']
['*', ' ', 'i', '199.16.104.128/27', '10.66.166.4', '0', '100', '0', '11111 99999', '?']
['*', ' ', 'i', '199.16.104.128/27', '10.66.166.2', '0', '100', '0', '11111 99999', '?']
['*', '>', ' ', '199.16.104.128/27', '10.118.160.97', '', '', '0', '11111 99999', '?']
['*', ' ', 'i', '199.16.104.160/27', '10.66.166.4', '0', '100', '0', '11111 99999', '?']
['*', ' ', 'i', '199.16.104.160/27', '10.66.166.2', '0', '100', '0', '11111 99999', '?']

SUMMARY

Textfsm Parsed output only shows 3 out of 4 paths for prefix 199.16.104.128/27. The first path is not parsed. I am using textfsm version 0.2.2 directly from commandline on Linux Ubuntu 14.4, python 2.7.12

STEPS TO REPRODUCE

need a help on escaping the parenthesis

Hi All ,

can anybody help me how do i escape the paranthesis

my requirement is to pull the X86_64_LINUX_IOSD-UNIVERSALK9-M

from the build from the cisco show version output

Cisco IOS Software, CSR1000V Software (X86_64_LINUX_IOSD-UNIVERSALK9-M),

since textfsm has the definition where most of the pattern we want to fetch it needs to be grouped

if i try like

pattern = ((.*)) to extract the (X86_64_LINUX_IOSD-UNIVERSALK9-M)

the textFSM throws the error .

any help on this will be appreciated .

Issues with trying to use the test-template playbook

ISSUE TYPE
  • Bug Report
COMMAND
ansible-playbook  test-template.yml
-- ansible 2.3.0 (devel 07a517aebd) last updated 2017/01/09
SUMMARY

I was working on some template improvements and wanted to add the tests in. I ran into a couple of issues.

  1. test-template.yml does not work out of the box. Perhaps I'm missing something, but it seems to not work with ansible 2.3 dev branch. Starting with I can't see where TEST_DIR was defined, | split('_') balks, and with_items on the last task seemed to be in the wrong spot. I was able to work through these and get it running with the diff below (Also simplified the prompting a bit with new var setup).
--- a/test-template.yml
+++ b/test-template.yml
@@ -7,30 +7,27 @@
   vars_prompt:
     - name: template_name
       prompt: "Enter the name of the template to verify:"
-      default: "cisco_nxos_show_ip_route"
-      private: no
-
-    - name: platform
-      prompt: "Enter the platform"
-      default: "cisco_nxos"
+      default: "cisco_ios_show_snmp_community"
       private: no

+  vars:
+    top_dir: "{{ lookup('env', 'PWD') }}"
+    TEST_DIR: "{{ top_dir }}/tests/"
+    platform: "{{ template_name.split('_')[0:2] | join('_') }}"
+    command_variable: "{{ template_name.split(platform + '_') | last }}"
+    command: "{{ command_variable.split('_') | join(' ') }}"
+
   tasks:

-  - name: extract command from template name
-    set_fact: command_variable="{{ template_name | split(platform + '_') | last }}"
-
-  - name: extract command string from command_variable
-    set_fact: command="{{ command_variable | split('_') | join(' ') }}"
-
   - name: run TextFSM locally on test input
     ntc_show_command:
       connection: offline
       file: "{{ item }}"
       platform: "{{ platform }}"
       command: "{{ command }}"
+      template_dir: "{{ top_dir }}/templates"
     with_fileglob:
-      - "{{ TEST_DIR }}/{{ platform }}/{{ command_variable}}/{{ template_name}}*.raw"
+      - "{{ TEST_DIR }}/{{ platform }}/{{ command_variable }}/{{ template_name }}*.raw"
     register: ntc_result

   - name: read parsed sample files
@@ -39,7 +36,7 @@
     register: ntc_result

   - name: verify that parsed result is the same as expected
+    with_items: "{{ ntc_result.results }}"
     compare_dict:
       result: "{{ item.item.response }}"
       sample: "{{ item.ansible_facts.parsed_sample }}"
-    with_items: "{{ ntc_result.results }}"
  1. In addition to the above, once I did get it working I was not able to do negative testing with incorrect values on the parsed vs raw samples. After digging a little further I found that compare_dict was not doing the job 100%. I'm not sure if things changed somewhere in ansible, but the dicts are being passed in as strings and it appears to be breaking the string into characters to compare the expected results contains the same set of ascii characters (not necessarily in the right order!) I was able to work out a patch for this as well, but I wanted to mention it before hand. As that code is also in a separate repo, probably should just discuss there. test-templates.py has a similar compare function in this repo, but I wasn't able to get that to run either.

  2. after I succeeded with the above, ran into a case where I wanted to introduce a new variable (for ios show snmp) as entries can optional have an ACL apply, but then I wasn't sure how the template verification should handle "optional" record variables. I think gTextFSM probably shouldn't be returning them if they were not parsed out of the input (or at least differentiate undefined from ""), but it not clear to me if you can make vars optional. I guess I can discuss this one separately later, but just wanted to mention it.

Using the .textfsm extension for templates

ISSUE TYPE
  • Feature Idea
TEMPLATE USING

all

SUMMARY

I think there's value in renaming the textfsm templates to use the .textfsm file extension as currently they cannot be syntax-highlighted in editors, or they are syntax-highlighted wrongly.

Template update: cisco_nxos_show_cdp_neighbors

ISSUE TYPE
  • Template Creation Help
TEMPLATE USING
Value Filldown NEIGHBOR (\S+)
Value Required LOCAL_INTERFACE (\S+)
Value NEIGHBOR_INTERFACE (\S+)

Start
  ^Device.*ID -> CDP

CDP
  ^${NEIGHBOR}\s+${LOCAL_INTERFACE}\s+\d+\s+[\w\s]+\S+\s+${NEIGHBOR_INTERFACE} -> Record
  ^${NEIGHBOR}
  ^\s+${LOCAL_INTERFACE}\s+\d+\s+[\w\s]+\S+\s+${NEIGHBOR_INTERFACE} -> Record
SAMPLE COMMAND OUTPUT
xxx-xxx-xxx-xxx# show cdp neighbors 
Capability Codes: R - Router, T - Trans-Bridge, B - Source-Route-Bridge
                 S - Switch, H - Host, I - IGMP, r - Repeater,
                 V - VoIP-Phone, D - Remotely-Managed-Device,
                 s - Supports-STP-Dispute


Device-ID             Local Intrfce Hldtme Capability  Platform         Port ID
my-dc1-mgt-sw1(FOC213230KP)
                   mgmt0          138    R S I s   N3K-C3172PQ-XL     Eth1/48       
lx-dc1-server01.mynetwork.com
                   Eth1/1/1       109    H         Linux              eth9          
lx-dc1-server02.mynetwork.com
                   Eth1/1/2       106    H         Linux              eth9          
lx-dc1-server03.mynetwork.com
                   Eth1/1/3       91     H         Linux              eth9          
lx-dc1-server04.mynetwork.com
                   Eth1/1/4       112    H         Linux              eth9          
lx-dc1-server05.mynetwork.com
                   Eth1/2/1       100    H         Linux              eth9
SUMMARY

I would like to learn how to add Capability and Platform to the template above. This will be very useful as the output for these values in the show cdp neighbor detail is somewhat different. I find the values supplied in this output to be much more useful.

cisco_xr_show_ip_route uptime format and protocol sub-type support

ISSUE TYPE
  • Bug Report
TEMPLATE USING

cisco_xr_show_ip_route.template

SAMPLE COMMAND OUTPUT
Wed Apr  4 19:27:36.016 UTC

Codes: C - connected, S - static, R - RIP, B - BGP, (>) - Diversion path
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
       i - ISIS, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, su - IS-IS summary null, * - candidate default
       U - per-user static route, o - ODR, L - local, G  - DAGR, l - LISP
       A - access/subscriber, a - Application route
       M - mobile route, r - RPL, (!) - FRR Backup path

Gateway of last resort is 10.0.0.1 to network 0.0.0.0

D EX 10.0.10.4/30 [170/76800] via 10.0.20.2, 14:56:35, TenGigE0/0/0/5.1
B    192.168.70.4/30 [200/0] via 10.0.20.2, 1y03w
SUMMARY

cisco_xr_show_ip_route.template currently does not account for non-hh:mm:ss uptime formats, such as '1y03w'
cisco_xr_show_ip_route.template currently does not account for protocol sub-type support, such as 'D EX'
I have a working template if you prefer I submit a pull request for this.

STEPS TO REPRODUCE

Use the above show ip route output as 'sh_ip_route.txt'.
Use the following script as 'check.py':

import textfsm

with open('sh_ip_route.txt', 'r') as input_file:
    iproute_raw = input_file.read()

with open('./templates/cisco_xr_show_ip_route.template', 'r') as template_file:
    re_table = textfsm.TextFSM(template_file)
    fsm_results = re_table.ParseText(iproute_raw)

print(fsm_results)

Run python check.py

EXPECTED RESULTS

Receive a list of 2 lists corresponding to the 2 routes in the show ip route output.

ACTUAL RESULTS
Traceback (most recent call last):
  File "check.py", line 8, in <module>
    fsm_results = re_table.ParseText(iproute_raw)
  File "/home/user/Projects/registrar/lib64/python3.4/site-packages/textfsm.py", line 855, in ParseText
    self._CheckLine(line)
  File "/home/user/Projects/registrar/lib64/python3.4/site-packages/textfsm.py", line 878, in _CheckLine
    if self._Operations(rule):
  File "/home/user/Projects/registrar/lib64/python3.4/site-packages/textfsm.py", line 954, in _Operations
    % (rule.new_state, rule.line_num))
textfsm.TextFSMError: Error: "LINE NOT FOUND". Line: 29.

cisco_ios_show_lldp_neighbor_detail failing when `Physical media capabilities` are `Other/unknown`

ISSUE TYPE
  • Bug Report
TEMPLATE USING

Github link

Value LOCAL_INTERFACE (\S+)
Value CHASSIS_ID (\S+)
Value NEIGHBOR_PORT_ID (.*)
Value NEIGHBOR_INTERFACE (.*)
Value NEIGHBOR (\S+)
Value SYSTEM_DESCRIPTION (.*)
Value CAPABILITIES (.*)
Value MANAGEMENT_IP (\S+)
Value VLAN (\d+)

Start
  ^.*not advertised
  ^.*Invalid input detected -> EOF
  ^.*LLDP is not enabled -> EOF
  ^Local\s+Intf:\s+${LOCAL_INTERFACE}\s*$$
  ^Chassis\s+id:\s+${CHASSIS_ID}\s*$$
  ^Port\s+id:\s+${NEIGHBOR_PORT_ID}\s*$$
  ^Port\s+Description:\s+${NEIGHBOR_INTERFACE}\s*$$
  ^System\s+Name(?::\s+${NEIGHBOR}|\s+-\s+not\s+advertised)\s*$$
  ^System\s+Description -> GetDescription
  ^Time
  ^System\s+Capabilities
  ^Enabled\s+Capabilities:\s+${CAPABILITIES}\s*$$
  ^Management\s+Addresses
  ^\s+OID
  ^\s+[\d+\.]{8,}
  ^.*IP:\s+${MANAGEMENT_IP}
  ^Auto\s+Negotiation
  ^Physical\s+media
  ^\s+.+\(\S+\)\s*$$
  ^Media\s+Attachment
  ^\s+Inventory
  ^\s+Capabilities
  ^\s+Device\s+type
  ^\s+Network\s+Policies
  ^\s+Power\s+requirements
  ^\s+Location
  ^Time\s+remaining
  ^Vlan\s+ID:\s+(?:${VLAN}|-\s+not\s+advertised)\s*$$
  ^\s+\(\S+\)
  ^(?:PoE|\s+Power)
  ^\s*-+\s*$$ -> Record
  ^MED -> Med
  ^\s*\^\s*
  ^\s*Total\s+entries\s+displayed -> Record
  ^\s*$$
  ^.*$$ -> Error

GetDescription
  ^${SYSTEM_DESCRIPTION} -> IgnoreDescription

IgnoreDescription
  ^Time\s+remaining -> Start
  ^\S*
  ^\s*$$
  ^.* -> Error

Med
  ^\s+\S+
  ^\s*$$
  ^\s*-+\s*$$ -> Continue.Record
  ^\s*-+\s*$$ -> Start
^.* -> Error
SAMPLE COMMAND OUTPUT
#show lldp neigh detail
------------------------------------------------
Local Intf: Te1/1/1
Chassis id: 2c33.1100.eece
Port id: Te1/1/12
Port Description: asw21 
System Name: dsw01

System Description: 
Cisco IOS Software, s6t64 Software (s6t64-ADVENTERPRISEK9-M), Version 15.4(1)SY3, RELEASE SOFTWARE (fc4)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2017 by Cisco Systems, Inc.
Compiled Fri 27-Oct-17 23:06 by prod_rel_team

Time remaining: 84 seconds
System Capabilities: B,R
Enabled Capabilities: B,R
Management Addresses:
    IP: 172.16.4.20
Auto Negotiation - supported, enabled
Physical media capabilities:
    Other/unknown
Media Attachment Unit type - not advertised
Vlan ID: 1
          
SUMMARY

When a device is advertising Other/unknown Physical media capabilities: the module fails. I believe this is from there being no ( ) in the string.

I have a possible working solution that I will be submitting a PR for this later today.

STEPS TO REPRODUCE

Used the validation playbook for NTC-templates with the following as the raw:

------------------------------------------------
Local Intf: Gi2/0/13
Chassis id: 172.16.4.125
Port id: 000b.ea00.16e0
Port Description: WAN PORT
System Name: ZULTYS IP Phone

System Description: 
ZULTYS IP Phone

Time remaining: 64 seconds
System Capabilities: T
Enabled Capabilities: T
Management Addresses - not advertised
Auto Negotiation - supported, enabled
Physical media capabilities:
    1000baseT(FD)
    100base-TX(FD)
    100base-TX(HD)
    10base-T(FD)
    10base-T(HD)
Media Attachment Unit type: 30
Vlan ID: - not advertised

MED Information:

    MED Codes:
          (NP) Network Policy, (LI) Location Identification
          (PS) Power Source Entity, (PD) Power Device
          (IN) Inventory

    H/W revision: 47.0.0.80.0.0.0
    F/W revision: 47.80.132.1
    S/W revision: 47.80.132.1
    Serial number: 000bea0016e0
    Manufacturer: ZULTYS
    Model: ZIP 33G
    Capabilities: NP, PD, IN
    Device type: Endpoint Class III
    Network Policy(Voice): VLAN 174, tagged, Layer-2 priority: 5, DSCP: 46
    PD device, Power source: PSE, Power Priority: High, Wattage: 4.0
    Location - not advertised


------------------------------------------------
Local Intf: Te1/1/1
Chassis id: 2c33.1100.eece
Port id: Te1/1/12
Port Description: asw21 
System Name: dsw01

System Description: 
Cisco IOS Software, s6t64 Software (s6t64-ADVENTERPRISEK9-M), Version 15.4(1)SY3, RELEASE SOFTWARE (fc4)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2017 by Cisco Systems, Inc.
Compiled Fri 27-Oct-17 23:06 by prod_rel_team

Time remaining: 84 seconds
System Capabilities: B,R
Enabled Capabilities: B,R
Management Addresses:
    IP: 172.16.4.20
Auto Negotiation - supported, enabled
Physical media capabilities:
    Other/unknown
Media Attachment Unit type - not advertised
Vlan ID: 1
          

Total entries displayed: 2
EXPECTED RESULTS

I would expect that the module would run through still, the Physical media capabilities are not something that is captured today

ACTUAL RESULTS
TASK [cisco_ios_show_lldp_neighbors_detail: run TextFSM on test input] ***********************************************************************************************************************************************************************
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: textfsm.TextFSMError: State Error raised. Rule Line: 49. Input Line:     Other/unknown
failed: [localhost] (item=/Users/jvanderaa/template_updates/ntc-templates/tests/cisco_ios/show_lldp_neighbors_detail/cisco_ios_show_lldp_neighbors_detail4.raw) => {"changed": false, "item": "/Users/jvanderaa/template_updates/ntc-templates/tests/cisco_ios/show_lldp_neighbors_detail/cisco_ios_show_lldp_neighbors_detail4.raw", "module_stderr": "Traceback (most recent call last):\n  File \"/Users/jvanderaa/.ansible/tmp/ansible-tmp-1550856018.7-237240458117837/AnsiballZ_ntc_show_command.py\", line 113, in <module>\n    _ansiballz_main()\n  File \"/Users/jvanderaa/.ansible/tmp/ansible-tmp-1550856018.7-237240458117837/AnsiballZ_ntc_show_command.py\", line 105, in _ansiballz_main\n    invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\n  File \"/Users/jvanderaa/.ansible/tmp/ansible-tmp-1550856018.7-237240458117837/AnsiballZ_ntc_show_command.py\", line 48, in invoke_module\n    imp.load_module('__main__', mod, module, MOD_DESC)\n  File \"/var/folders/dq/_tjy3jfn0j98n6j590nyr24jpxb_7r/T/ansible_ntc_show_command_payload_9OjdaM/__main__.py\", line 511, in <module>\n  File \"/var/folders/dq/_tjy3jfn0j98n6j590nyr24jpxb_7r/T/ansible_ntc_show_command_payload_9OjdaM/__main__.py\", line 498, in main\n  File \"/var/folders/dq/_tjy3jfn0j98n6j590nyr24jpxb_7r/T/ansible_ntc_show_command_payload_9OjdaM/__main__.py\", line 316, in parse_raw_output\n  File \"/var/folders/dq/_tjy3jfn0j98n6j590nyr24jpxb_7r/T/ansible_ntc_show_command_payload_9OjdaM/__main__.py\", line 292, in get_structured_data\n  File \"/Library/Python/2.7/site-packages/clitable.py\", line 277, in ParseCmd\n    self.table = self._ParseCmdItem(self.raw, template_file=template_files[0])\n  File \"/Library/Python/2.7/site-packages/clitable.py\", line 310, in _ParseCmdItem\n    for record in fsm.ParseText(cmd_input):\n  File \"/Library/Python/2.7/site-packages/textfsm.py\", line 885, in ParseText\n    self._CheckLine(line)\n  File \"/Library/Python/2.7/site-packages/textfsm.py\", line 908, in _CheckLine\n    if self._Operations(rule, line):\n  File \"/Library/Python/2.7/site-packages/textfsm.py\", line 989, in _Operations\n    % (rule.line_num, line))\ntextfsm.TextFSMError: State Error raised. Rule Line: 49. Input Line:     Other/unknown\n", "module_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}

cisco_nxos_show_interface_status.template

ISSUE TYPE
  • Bug Report
TEMPLATE USING
FSM Template:
Value PORT (\S+)
Value NAME (.*?)
Value STATUS (\S+)
Value VLAN (\d+|routed|trunk)
Value DUPLEX (\S+)
Value SPEED (\d+G?|auto)
Value TYPE (.+?)

Start
  ^[Pp]ort\s+[Nn]ame\s+[Ss]tatus\s+[Vv]lan\s+[Dd]uplex\s+[Ss]peed\s+[Tt]ype\s*$$ -> INTFS
  ^-+\s*$$
  ^$$
  ^.*$$ -> Error

INTFS
  ^${PORT}\s+${NAME}\s+${STATUS}\s+${VLAN}\s+${DUPLEX}\s+${SPEED}\s+${TYPE}\s*$$ -> Record
  ^-+\s*$$
  ^$$
  ^.*$$ -> Error

SAMPLE COMMAND OUTPUT
--------------------------------------------------------------------------------
Port          Name               Status    Vlan      Duplex  Speed   Type
--------------------------------------------------------------------------------
mgmt0         --                 connected routed    full    100     --
Eth1/1        managed by puppet  disabled  routed    auto    auto    SFP-H10GB-CU2M
Eth1/2        --                 disabled  1         auto    auto    SFP-H10GB-CU2M
Eth1/3        --                 xcvrAbsen 1         auto    auto    --
Eth1/4        --                 xcvrAbsen trunk     auto    auto    --
Eth1/5        --                 xcvrAbsen trunk     auto    auto    --
Eth1/6        --                 xcvrAbsen trunk     auto    auto    --
Eth1/7        --                 xcvrAbsen trunk     auto    auto    --
Eth1/8        --                 xcvrAbsen 1         auto    auto    --
Eth1/9        --                 xcvrAbsen 1         auto    auto    --
Eth1/10       managed by puppet  xcvrAbsen routed    auto    auto    --
Eth1/11       --                 xcvrAbsen 1         auto    auto    --
Eth1/12       --                 xcvrAbsen 1         auto    auto    --
Eth1/13       --                 xcvrAbsen 1         auto    auto    --
Eth1/14       --                 xcvrAbsen 1         auto    auto    --
Eth1/15       --                 xcvrAbsen 1         auto    auto    --
Eth1/16       --                 xcvrAbsen 1         auto    auto    --
Eth1/17       --                 xcvrAbsen 1         auto    auto    --
Eth1/18       --                 xcvrAbsen 1         auto    auto    --
Eth1/19       --                 xcvrAbsen 1         auto    auto    --
Eth1/20       --                 xcvrAbsen 1         auto    auto    --
Eth1/21       --                 xcvrAbsen 1         auto    auto    --
Eth1/22       --                 xcvrAbsen 1         auto    auto    --
Eth1/23       --                 xcvrAbsen 1         auto    auto    --
Eth1/24       --                 xcvrAbsen 1         auto    auto    --
Eth1/25       --                 xcvrAbsen 1         auto    auto    --
Eth1/26       --                 xcvrAbsen 1         auto    auto    --
Eth1/27       --                 xcvrAbsen 1         auto    auto    --
Eth1/28       --                 xcvrAbsen 1         auto    auto    --
Eth1/29       --                 xcvrAbsen 1         auto    auto    --
Eth1/30       --                 xcvrAbsen 1         auto    auto    --
Eth1/31       --                 xcvrAbsen 1         auto    auto    --
Eth1/32       --                 xcvrAbsen 1         auto    auto    --
Eth1/33       --                 xcvrAbsen 1         auto    auto    --
Eth1/34       --                 xcvrAbsen 1         auto    auto    --
Eth1/35       --                 xcvrAbsen 1         auto    auto    --
Eth1/36       --                 xcvrAbsen 1         auto    auto    --
Eth1/37       --                 xcvrAbsen 1         auto    auto    --
Eth1/38       --                 xcvrAbsen 1         auto    auto    --
Eth1/39       --                 xcvrAbsen 1         auto    auto    --
Eth1/40       --                 xcvrAbsen 1         auto    auto    --
Eth1/41       --                 xcvrAbsen 1         auto    auto    --
Eth1/42       --                 xcvrAbsen 1         auto    auto    --
Eth1/43       --                 xcvrAbsen 1         auto    auto    --
Eth1/44       --                 xcvrAbsen 1         auto    auto    --
Eth1/45       --                 xcvrAbsen 1         auto    auto    --
Eth1/46       --                 xcvrAbsen 1         auto    auto    --
Eth1/47       --                 xcvrAbsen 1         auto    auto    --
Eth1/48       --                 xcvrAbsen 1         auto    auto    --
Eth2/1        --                 notconnec routed    auto    auto    QSFP-40G-SR-BD
Eth2/2        --                 notconnec routed    auto    auto    QSFP-40G-SR-BD
Eth2/3        --                 notconnec routed    auto    auto    QSFP-40G-SR-BD
Eth2/4        --                 notconnec routed    auto    auto    QSFP-40G-SR-BD
Eth2/5        --                 xcvrAbsen trunk     auto    auto    --
Eth2/6        --                 xcvrAbsen trunk     auto    auto    --
Eth2/7        --                 xcvrAbsen 1         auto    auto    --
Eth2/8        --                 xcvrAbsen 1         auto    auto    --
Eth2/9        --                 xcvrAbsen 1         auto    auto    --
Eth2/10       --                 xcvrAbsen 1         auto    auto    --
Eth2/11       --                 disabled  1         auto    auto    QSFP-40G-SR-BD
Eth2/12       --                 disabled  1         auto    auto    QSFP-40G-SR-BD
Po10          --                 noOperMem 1         auto    auto    --
Po11          --                 noOperMem 1         auto    auto    --
Po12          --                 noOperMem 1         auto    auto    --
Lo10          --                 connected routed    auto    auto    --
Vlan1         --                 down      routed    auto    auto    --
Vlan5         --                 down      routed    auto    auto    --
Vlan10        --                 down      routed    auto    auto    --
Vlan20        --                 down      routed    auto    auto    --
Vlan66        --                 down      routed    auto    auto    --
Vlan77        --                 down      routed    auto    auto    --
Vlan146       my vlan 146        down      routed    auto    auto    --
nve1          --                 connected --        auto    auto    --
SUMMARY

Template give an error on the line for the nve1 interface because the VLAN value is "--"

STEPS TO REPRODUCE
$ textfsm.py templates/cisco_nxos_show_interface_status.template tests/cisco_nxos/show_interface_status/cisco_nxos_show_interface_status.raw
EXPECTED RESULTS

No error

ACTUAL RESULTS
FSM Template:
Value PORT (\S+)
Value NAME (.*?)
Value STATUS (\S+)
Value VLAN (\d+|routed|trunk)
Value DUPLEX (\S+)
Value SPEED (\d+|auto)
Value TYPE (.+?)

Start
  ^[Pp]ort\s+[Nn]ame\s+[Ss]tatus\s+[Vv]lan\s+[Dd]uplex\s+[Ss]peed\s+[Tt]ype\s*$$ -> INTFS
  ^-+\s*$$
  ^$$
  ^.*$$ -> Error

INTFS
  ^${PORT}\s+${NAME}\s+${STATUS}\s+${VLAN}\s+${DUPLEX}\s+${SPEED}\s+${TYPE}\s*$$ -> Record
  ^-+\s*$$
  ^$$
  ^.*$$ -> Error


State Error raised. Rule Line: 19. Input Line: nve1          --                 connected --        auto    auto    --

show_lldp_neighbors.template failing when switch + domain name is > 19 characters

ISSUE TYPE
  • Bug Report
TEMPLATE USING

cisco_ios_show_lldp_neighbors

Value Required NEIGHBOR (\S+)
Value Required LOCAL_INTERFACE (\S+)
Value Required NEIGHBOR_INTERFACE (\S+)

Start
  ^Device.*ID -> LLDP

LLDP
  ^${NEIGHBOR}\s+${LOCAL_INTERFACE}\s+\d+\s+(\S+)*\s+${NEIGHBOR_INTERFACE} -> Record
  ^${NEIGHBOR}
  ^\s+${LOCAL_INTERFACE}\s+\d+\s+(\S+)*\s+${NEIGHBOR_INTERFACE} -> Record
SAMPLE COMMAND OUTPUT
#show lldp neigh
Capability codes:
    (R) Router, (B) Bridge, (T) Telephone, (C) DOCSIS Cable Device
    (W) WLAN Access Point, (P) Repeater, (S) Station, (O) Other

Device ID           Local Intf     Hold-time  Capability      Port ID
long_name_swt.josh-vGi0/2          120        R               Gi0/0

Total entries displayed: 1
SUMMARY

When the hostname + domain name gets long the lldp neighbor output truncates at 20 characters. The result is no record being created and getting a blank completion.

Sample output of NTC Templates with network engine as is:

TASK [CLI >> Get LLDP neighbors] *********************************************************************************************************************************************************************************
ok: [rtr01]

TASK [SYS >> Parse LLDP Information] *****************************************************************************************************************************************************************************
ok: [rtr01]

TASK [DEBUG >> LLDP Neighbors] ***********************************************************************************************************************************************************************************
ok: [rtr01] => {
    "msg": []
}

PLAY RECAP *******************************************************************************************************************************************************************************************************
rtr01                      : ok=3    changed=0    unreachable=0    failed=0
STEPS TO REPRODUCE
- name: Switch config
  connection: network_cli
  hosts: cisco_routers
  gather_facts: no
  become: yes
  become_method: enable
  roles:
    - ansible-network.network-engine

  tasks:

    - name: CLI >> Get LLDP neighbors
      ios_command:
        commands:
          - show lldp neighbors
      register: command_output

    - name: SYS >> Parse LLDP Information
      textfsm_parser:
        file: "/opt/ntc-templates/templates/cisco_ios_show_lldp_neighbors.template"
        content: "{{ command_output.stdout[0] }}"
        name: lldp_facts

    - name: DEBUG >> LLDP Neighbors
      debug:
        msg: "{{ ansible_facts.lldp_facts }}"
EXPECTED RESULTS

I expect to see a neighbor in the output

ACTUAL RESULTS

I got a blank facts set as shown above.

ios show mac address-table

Checking the implementation and the variety of output on ios devices, I collect these three types of output for the same command. Can we discuss how to handle all these under single template?

Legend: * - primary entry
age - seconds since last seen
n/a - not available

vlan mac address type learn age ports
------+----------------+--------+-----+----------+--------------------------

Unicast Entries
vlan mac address type protocols port
---------+---------------+--------+---------------------+-------------------------

      Mac Address Table

Vlan Mac Address Type Ports


Huawei - display lldp neighbor formatting

Hi ,
it will be greate if somebody can assist formating the below output . I am struggling to get it working , I did the arp one easy , but this require alot of work, any tips at least to which template might help reverse engineer this ?

<> display lldp neighbor

GigabitEthernet0/0/0 has 0 neighbors

GigabitEthernet0/0/1 has 1 neighbors:

Neighbor index : 1
Chassis type :macAddress
Chassis ID :f41f-c2c5-e180
Port ID type :interfaceName
Port ID :Gi1/0/1
Port description :GigabitEthernet1/0/1
System name :tsa-2960-sw01
System description :Cisco IOS Software, C2960S Software (C2960S-UNIVERSALK9-M), Version 12.2(55)SE7, RELEASE SOFTWARE (fc1)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2013 by Cisco Systems, Inc.
Compiled Mon 28-Jan-13 10:28 by prod_rel_team
System capabilities supported :bridge router
System capabilities enabled :bridge
Management address type :ipV4
Management address : 192.168.0.240
Expired time :102s

Port VLAN ID(PVID) :1
Protocol identity :

Auto-negotiation supported :Yes
Auto-negotiation enabled :Yes
OperMau :speed(1000)/duplex(Full)

Power port class :PD
PSE power supported :No
PSE power enabled :No
PSE pairs control ability:No
Power pairs :Unknown
Port power classification:Unknown

Link aggregation supported:No
Link aggregation enabled :No
Aggregation port ID :0
Maximum frame Size :0

MED Device information
Device class :Network Connectivity

HardwareRev :WS-C2960S-48LPS-L (PowerPC):F0
FirmwareRev :NA
SoftwareRev :12.2(55)SE7
SerialNum :NA
Manufacturer name :Cisco Systems, Inc.
Model name :WS-C2960S-48LPS-L
Asset tracking identifier :NA

Media policy type :Voice
Unknown Policy :Unknown
VLAN tagged :No
Media policy VlanID :0
Media policy L2 priority :0
Media policy Dscp :0

Power Type :PSE
PoE PSE power source :PSE
Port PSE Priority :Low
Port Available power value:0

Location format :Civic Address LCI
Location information:what(LLDP-MED Endpoint) country( )
Ca type Ca value
GigabitEthernet0/0/2 has 0 neighbors

GigabitEthernet0/0/3 has 0 neighbors

GigabitEthernet0/0/4 has 0 neighbors

GigabitEthernet0/0/5 has 0 neighbors

GigabitEthernet0/0/6 has 0 neighbors

GigabitEthernet0/0/7 has 0 neighbors

GigabitEthernet0/0/8 has 0 neighbors

GigabitEthernet0/0/9 has 0 neighbors

GigabitEthernet0/0/10 has 0 neighbors

cisco_ios_show_version.template Add Licensing

ISSUE TYPE
  • Feature Idea
TEMPLATE USING
Value VERSION (.+?)
Value ROMMON (\S+)
Value HOSTNAME (\S+)
Value UPTIME (.+)
Value RUNNING_IMAGE (\S+)
Value List HARDWARE (\S+\d\S+)
Value List SERIAL (\S+)
Value CONFIG_REGISTER (\S+)

Start
  ^.*Software\s.+\),\sVersion\s${VERSION},*\s+RELEASE.*
  ^ROM: ${ROMMON}
  ^\s*${HOSTNAME}\s+uptime\s+is\s+${UPTIME}
  ^[sS]ystem\s+image\s+file\s+is\s+"(.*?):${RUNNING_IMAGE}"
  ^[Pp]rocessor\s+board\s+ID\s+${SERIAL}
  ^[Cc]isco\s+${HARDWARE}.+
  ^[Cc]onfiguration\s+register\s+is\s+${CONFIG_REGISTER}
  ^Switch Port -> Stack


Stack
  ^[Ss]ystem [Ss]erial [Nn]umber\s+:\s+${SERIAL}
  ^[Mm]odel\s+[Nn]umber\s+:\s+${HARDWARE}\s*
  ^[Cc]onfiguration\s+register\s+is\s+${CONFIG_REGISTER}
SAMPLE COMMAND OUTPUT
Cisco IOS Software, C2900 Software (C2900-UNIVERSALK9-M), Version 15.1(4)M4, RELEASE SOFTWARE (fc1)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2012 by Cisco Systems, Inc.
Compiled Tue 20-Mar-12 18:57 by prod_rel_team

ROM: System Bootstrap, Version 15.0(1r)M16, RELEASE SOFTWARE (fc1)

BLAH_R1 uptime is 5 weeks, 1 day, 17 hours, 31 minutes
System returned to ROM by reload at 19:20:09 EST Wed Aug 8 2018
System restarted at 19:21:28 UTC Wed Aug 8 2018
System image file is "flash:c2900-universalk9-mz.SPA.151-4.M4.bin"
Last reload type: Normal Reload
Last reload reason: Reload Command



This product contains cryptographic features and is subject to United
States and local country laws governing import, export, transfer and
use. Delivery of Cisco cryptographic products does not imply
third-party authority to import, export, distribute or use encryption.
Importers, exporters, distributors and users are responsible for
compliance with U.S. and local country laws. By using this product you
agree to comply with applicable laws and regulations. If you are unable
to comply with U.S. and local laws, return this product immediately.

A summary of U.S. laws governing Cisco cryptographic products may be found at:
http://www.cisco.com/wwl/export/crypto/tool/stqrg.html

If you require further assistance please contact us by sending email to
[email protected].

Cisco CISCO2921/K9 (revision 1.0) with 479232K/45056K bytes of memory.
Processor board ID XXXXXXXX
3 Gigabit Ethernet interfaces
1 terminal line
1 Virtual Private Network (VPN) Module
DRAM configuration is 64 bits wide with parity enabled.
255K bytes of non-volatile configuration memory.
250880K bytes of ATA System CompactFlash 0 (Read/Write)


License Info:

License UDI:

-------------------------------------------------
Device#   PID                   SN
-------------------------------------------------
*0        CISCO2921/K9          XXXXXXXX     



Technology Package License Information for Module:'c2900' 

-----------------------------------------------------------------
Technology    Technology-package           Technology-package
              Current       Type           Next reboot  
------------------------------------------------------------------
ipbase        ipbasek9      Permanent      ipbasek9
security      securityk9    Permanent      securityk9
uc            uck9          Permanent      uck9
data          None          None           None

Configuration register is 0x2102
SUMMARY

I would like to collect the licensing information from the show version output. I am happy to work on this addition is this something that you would be willing to accept a PR for ?

Test files for aruba os need renamed.

ISSUE TYPE
  • Bug Report
  • Documentation Report
SUMMARY

In all other case that I can tell there is a 1 to 1 of template names to test names.
It looks like the test folders and files for aruba os are incorrectly named. Interface is shortened to int.

Template Names

templates/aruba_os_show_ip_interface_brief.template
templates/aruba_os_show_ipv6_interface_brief.template

Current Test Name
aruba_os/show_ip_int_brief/aruba_os_show_ip_int_brief.raw

EXPECTED RESULTS

Expexcted to see test parsed/raw files named.

aruba_os/show_ip_int_brief/aruba_os_show_ip_interface_brief.parsed
aruba_os/show_ip_int_brief/aruba_os_show_ip_interface_brief.raw

aruba_os/show_ip_int_brief/aruba_os_show_ipv6_interface_brief.parsed
aruba_os/show_ip_int_brief/aruba_os_show_ipv6_interface_brief.raw

show cdp neighbors for cisco_ios returns string instead of structured list

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value NEIGHBOR (\S+)
Value LOCAL_INTERFACE (\S+\s\S+)
Value CAPABILITY ([\w\s]+?)
Value PLATFORM (\S+\s\S+|\S+)
Value NEIGHBOR_INTERFACE (\S+\s\S+)

Start
  ^Device.*ID -> CDP

CDP
  ^${NEIGHBOR}\s+${LOCAL_INTERFACE}\s+\d+\s+${CAPABILITY}\s{2}\s+${PLATFORM}\s+${NEIGHBOR_INTERFACE} -> Record
SAMPLE COMMAND OUTPUT
sh cdp neighbors 
Capability Codes: R - Router, T - Trans Bridge, B - Source Route Bridge
                  S - Switch, H - Host, I - IGMP, r - Repeater, P - Phone, 
                  D - Remote, C - CVTA, M - Two-port Mac Relay 

Device ID        Local Intrfce     Holdtme    Capability  Platform  Port ID
hostname_1
                 Gig 1/1/2         133             R S I  C6807-XL  Gig 1/18
hostname_2
                 Gig 1/1/1         153             R S I  C6807-XL  Gig 1/17
hostname_3
                 Gig 1/1/3         155             R S I  C6807-XL  Gig 1/17
hostname_4
                 Gig 1/1/4         155             R S I  C6807-XL  Gig 1/18
hostname_5
                 Gig 1/0/6         175             T B I  AIR-CAP27 Gig 0

Total cdp entries displayed : 5
SUMMARY

Usage of net template doesn't return structured output for 'show cdp neighbors'.

STEPS TO REPRODUCE
from netmiko import Netmiko

execut python script: 

device = {
    'device_type': 'cisco_ios',
    'host': 'hostname',
    'username': 'username',
    'password': getpass(),
}

command = 'show cdp neighbors'
net_conn = Netmiko(**device)
   output = net_conn.send_command(command, use_textfsm=True)
net_conn.disconnect()

print(type(output))
EXPECTED RESULTS
<type 'list'>
ACTUAL RESULTS
<type 'unicode'>

cisco_xr_show_cdp_neighbors_detail.template shows remote and local interface incorrectly

ISSUE TYPE
  • Bug Report
TEMPLATE USING

cisco_xr_show_cdp_neighbors_detail.template


SAMPLE COMMAND OUTPUT

Device ID: RCMT-RSDVR01
SysName :
Entry address(es):
IPv4 address: 172.19.0.3
Platform: cisco WS-C3850-48T, Capabilities: Router Switch IGMP
Interface: TenGigE0/0/0/6
Port ID (outgoing port): TenGigabitEthernet4/0/24
Holdtime : 131 sec

Version :
Cisco IOS Software, IOS-XE Software, Catalyst L3 Switch Software (CAT3K_CAA-UNIVERSALK9-M), Version 03.07.05E RELEASE SOFTWARE (fc1)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2017 by Cisco Systems, Inc.
Compiled Fri 10-Feb-17 07:59 by prod_rel_team

advertisement version: 2
VTP Management Domain: 'RCMT-RSDVR'
Duplex: full


SUMMARY

The output above is done from a Cisoc ASR9010 with a Cisco IOS device as it's neighbor. As you can see from the output. The local interface is shown next to "Interface and remote interface is shown on "outgoing interface"

STEPS TO REPRODUCE
EXPECTED RESULTS

Simple, Values for Remote and local need to be swapped

ACTUAL RESULTS

Difference between Start and Record Start?

Hi there,

I've recently started looking into Ansible and in the process came across your project. I'd love to contribute once I get up and running. In the meantime I've been going through some of the code and was wondering what is the difference between "Start" and "Record Start", e.g as seen in the cisco_ios_show_cdp_neighbors_detail.template file.

I found an explanation for "Record" in this blog post but am yet to find one for "Record Start".

Thanks in advance.

Need help on parsing the show platform diag output

Need help on parsing this output 

raw output of the command show platform diag 

Chassis type: CSR1000V

Slot: R0, CSR1000V
  Running state               : ok, active
  Internal state              : online
  Internal operational state  : ok
  Physical insert detect time : 00:00:35 (4d16h ago)
  Software declared up time   : 00:00:35 (4d16h ago)

Slot: F0, CSR1000V
  Running state               : ok, active
  Internal state              : online
  Internal operational state  : ok
  Physical insert detect time : 00:00:35 (4d16h ago)
  Software declared up time   : 00:00:59 (4d16h ago)
  Hardware ready signal time  : 00:00:51 (4d16h ago)
  Packet ready signal time    : 00:01:06 (4d16h ago)

i have gave  my try to parse this out put 

TextFsm template for the above show platform diag output 

Value Ct (.*)
Value Slotno ((.*)[A-Z]\d+(.*))
Value rs (.+)
Value is (.+)
Value ios (.+)
Value pidt (.*)


Value sdut (.*)
Value hrst (.*)
Value prst (.*)

Start
  ^Chassis type: ${Ct}.* -> Continue.Record
  ^Slot: ${Slotno}\, -> Next.Record
  ^.*Running state\s+\:${rs}
  ^.*Internal state\s+\:${is}
  ^.*Internal operational state\s+\:${ios}
  ^.*Physical insert detect time\s+${pidt}
  ^.*Software declared up time\s+${sdut}
  ^.*Hardware ready signal time\s+${hrst}
  ^.*Packet ready signal time\s+${prst} -> Continue.Record

i want the table header to be 

Running state  Internal state Internal operational state Physical insert detect time Software declared up time Hardware ready signal time Packet ready signal time
and the respective values in the next row

Note  :  
the slot and the respective e details varies here as mentioned in the raw output .

show_platform-diag.txt

arista route template

Hi,

I noticed that there is no arista_eos_show_ip_route.template entry and I tried to create one but unsuccessful. Has anyone done this before and please advise on what I am missing or doing wrong?
When the playbook is run, there are no results. Without the template, doing a "show ip route" shows the routes just not in structured format. Below is the config and the results.

Thanks in advance!

Entry in the index file:

arista_eos_show_ip_route.template, .*, arista_eos, sh[[ow]] i[[p]] ro[[ute]]

arista_eos_show_ip_route.template:

Value Filldown Protocol (\S)
Value Type (\S+)
Value Filldown Network (\d+.\d+.\d+.\d+)
Value Filldown Mask (\d+)
Value Distance (\d+)
Value Metric (\d+)
Value Next_Hop (\d+.\d+.\d+.\d+)
Value Interface (\S+)

Start
^${Protocol}\s+${Type}\s+${Network}/${Mask}\s[${Distance}/${Metric}]\svia\s${Next_Hop},\s${Interface} -> Record

EOF

YAML FILE


  • name: GET ROUTES (EOS)
    hosts: eos
    gather_facts: no
    connection: local

    tasks:

    • name: GET ROUTES
      ntc_show_command:
      connection=ssh
      platform=arista_eos
      command='show ip route'
      host={{ inventory_hostname }}
      username={{ username }}
      password={{ password }}
      register: route_eos
      tags: route_eos

    • debug: var=route_eos

RESULTS:

PLAY [AUTO CONFIGURE PORT DESCRIPTIONS (EOS)] **********************************

TASK [GET ROUTES] **************************************************************
ok: [a7124]

TASK [debug] *******************************************************************
ok: [a7124] => {
"route_eos": {
"changed": false,
"response": [],
"response_list": []
}
}

PLAY RECAP *********************************************************************
a7124 : ok=2 changed=0 unreachable=0 failed=0

New Template Request

ISSUE TYPE
  • Feature Idea
SUMMARY

Can you add templates for show interface description for Cisco devices

STEPS TO REPRODUCE

Output should be similar to show interface status

cisco_ios_show_vlan.template not recorded complete list of interfaces

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value Required VLAN_ID (\d+)
Value NAME (\S+)
Value STATUS (\S+)
Value List INTERFACES ([\w\./]+)

Start
  ^$$
  ^\w+\s+[NnAaMmEe]{4}.*$$ -> VLANS

VLANS
  ^\d+ -> Continue.Record
  ^${VLAN_ID}\s+${NAME}\s+${STATUS}\s*$$
  ^${VLAN_ID}\s+${NAME}\s+${STATUS}\s+${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){3}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){4}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){5}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){6}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){7}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){8}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){9}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){10}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){11}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){12}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){13}${INTERFACES} -> Continue
  ^\s+${INTERFACES},* -> Continue
  ^\s+\S+\s+${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){2}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){3}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){4}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){5}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){6}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){7}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){8}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){9}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){10}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){11}${INTERFACES} -> Continue
  ^\d+
  ^\s+
  ^-+
  ^\S+\s+[TtYyPpEe]{4} -> Done
  ^.+ -> Error

Done
  ^.*
SAMPLE COMMAND OUTPUT
VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
1    default                          active    Gi1/0/2, Gi1/0/3, Gi1/0/4, Gi1/0/7, Gi1/0/12, Gi1/0/16, Gi1/0/17, Gi1/0/18, Gi1/0/19, Gi1/0/22, Gi1/0/23, Gi1/0/29, Gi1/0/30, Gi1/0/31, Gi1/0/32, Gi1/0/33, Gi1/0/34, Gi1/0/35, Gi1/0/36, Gi1/0/37, Gi1/0/38, Gi1/0/39, Gi1/0/40, Gi1/0/41, Gi1/0/42, Gi1/0/43, Gi1/0/44, Gi1/0/45, Gi1/0/46, Gi1/0/50, Gi1/0/51, Gi1/0/52, Gi2/0/2, Gi2/0/3, Gi2/0/4, Gi2/0/6, Gi2/0/7, Gi2/0/8, Gi2/0/9, Gi2/0/13, Gi2/0/14, Gi2/0/15, Gi2/0/16, Gi2/0/17, Gi2/0/18, Gi2/0/19, Gi2/0/21
                                                Gi2/0/22, Gi2/0/23, Gi2/0/24, Gi2/0/25, Gi2/0/26, Gi2/0/27, Gi2/0/28, Gi2/0/29, Gi2/0/30, Gi2/0/31, Gi2/0/32, Gi2/0/33, Gi2/0/34, Gi2/0/35, Gi2/0/36, Gi2/0/37, Gi2/0/38, Gi2/0/39, Gi2/0/40, Gi2/0/41, Gi2/0/42, Gi2/0/43, Gi2/0/44, Gi2/0/45, Gi2/0/46, Gi2/0/47, Gi2/0/48, Gi2/0/49, Gi2/0/50, Gi2/0/51, Gi2/0/52
32   vlan_32                          active
35   vlan_35                          active
36   vlan_36                          active
37   vlan_37                          active
38   vlan_38                          active
39   vlan_39                          active
40   vlan_40                          active
41   vlan_41                          active
50   vlan_50                          active
1002 vlan_1002                        act/unsup
1003 vlan_1003                        act/unsup
1004 vlan_1004                        act/unsup
1005 vlan_1005                        act/unsup
2100 vlan_2100                        active
2101 vlan_2101                        active    Gi1/0/6, Gi1/0/15
2102 vlan_2102                        active
2103 vlan_2103                        active
2104 vlan_2104                        active    Gi2/0/10, Gi2/0/11, Gi2/0/12, Gi2/0/20
2111 vlan_2111                        active
2112 vlan_2112                        active    Gi1/0/21
3350 vlan_3350                        active
3351 vlan_3351                        active    Gi1/0/10, Gi1/0/28
3363 vlan_3363                        active    Gi1/0/1, Gi1/0/11, Gi2/0/1
3364 vlan_3364                        active
3365 vlan_3365                        active
3366 vlan_3366                        active
3367 vlan_3367                        active
3368 vlan_3368                        active
3369 vlan_3369                        active
3370 vlan_3370                        active
3371 vlan_3371                        active
3373 vlan_3373                        active    Gi1/0/8
3374 vlan_3374                        active    Gi1/0/20
3428 vlan_3428                        active
3460 vlan_3460                        active
3468 vlan_3468                        active
3469 vlan_3469                        active    Gi1/0/26, Gi1/0/27
3470 vlan_3470                        active
3471 vlan_3471                          
3472 vlan_3472                        active

VLAN Type  SAID       MTU   Parent RingNo BridgeNo Stp  BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------
1    enet  100001     1500  -      -      -        -    -        0      0
32   enet  100032     1500  -      -      -        -    -        0      0
35   enet  100035     1500  -      -      -        -    -        0      0
36   enet  100036     1500  -      -      -        -    -        0      0
37   enet  100037     1500  -      -      -        -    -        0      0
38   enet  100038     1500  -      -      -        -    -        0      0
39   enet  100039     1500  -      -      -        -    -        0      0
40   enet  100040     1500  -      -      -        -    -        0      0
41   enet  100041     1500  -      -      -        -    -        0      0
50   enet  100050     1500  -      -      -        -    -        0      0
1002 fddi  101002     1500  -      -      -        -    -        0      0
1003 tr    101003     1500  -      -      -        -    -        0      0
1004 fdnet 101004     1500  -      -      -        ieee -        0      0
1005 trnet 101005     1500  -      -      -        ibm  -        0      0
2100 enet  102100     1500  -      -      -        -    -        0      0
2101 enet  102101     1500  -      -      -        -    -        0      0
2102 enet  102102     1500  -      -      -        -    -        0      0
2103 enet  102103     1500  -      -      -        -    -        0      0
2104 enet  102104     1500  -      -      -        -    -        0      0
2111 enet  102111     1500  -      -      -        -    -        0      0
2112 enet  102112     1500  -      -      -        -    -        0      0
3350 enet  103350     1500  -      -      -        -    -        0      0
3351 enet  103351     1500  -      -      -        -    -        0      0
3363 enet  103363     1500  -      -      -        -    -        0      0
3364 enet  103364     1500  -      -      -        -    -        0      0
3365 enet  103365     1500  -      -      -        -    -        0      0
3366 enet  103366     1500  -      -      -        -    -        0      0
3367 enet  103367     1500  -      -      -        -    -        0      0
3368 enet  103368     1500  -      -      -        -    -        0      0
3369 enet  103369     1500  -      -      -        -    -        0      0
3370 enet  103370     1500  -      -      -        -    -        0      0
3371 enet  103371     1500  -      -      -        -    -        0      0
3373 enet  103373     1500  -      -      -        -    -        0      0
3374 enet  103374     1500  -      -      -        -    -        0      0
3428 enet  103428     1500  -      -      -        -    -        0      0
3460 enet  103460     1500  -      -      -        -    -        0      0
3468 enet  103468     1500  -      -      -        -    -        0      0
3469 enet  103469     1500  -      -      -        -    -        0      0
3470 enet  103470     1500  -      -      -        -    -        0      0
3471 enet  103471     1500  -      -      -        -    -        0      0
3472 enet  103472     1500  -      -      -        -    -        0      0


Remote SPAN VLANs
------------------------------------------------------------------------------


Primary Secondary Type              Ports
------- --------- ----------------- ------------------------------------------
SUMMARY

When the list of interfaces in the "Ports" column contains more than 12 interfaces in a single line, there only the first 12 interfaces will be recorded

STEPS TO REPRODUCE

python /textfsm.py ~/ntc-templates/templates/cisco_ios_show_vlan.template /tmp/show_vlan

EXPECTED RESULTS

The complete list of interfaces in Vlan1 should be recorded

ACTUAL RESULTS

Only 24 interfaces in Vlan1 were recorded

FSM Template:
Value Required VLAN_ID (\d+)
Value NAME (\S+)
Value STATUS (\S+)
Value List INTERFACES ([\w\./]+)

Start
  ^$$
  ^\w+\s+[NnAaMmEe]{4}.*$$ -> VLANS

VLANS
  ^\d+ -> Continue.Record
  ^${VLAN_ID}\s+${NAME}\s+${STATUS}\s*$$
  ^${VLAN_ID}\s+${NAME}\s+${STATUS}\s+${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){3}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){4}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){5}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){6}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){7}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){8}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){9}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){10}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){11}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){12}${INTERFACES},* -> Continue
  ^\d+\s+(?:\S+\s+){13}${INTERFACES} -> Continue
  ^\s+${INTERFACES},* -> Continue
  ^\s+\S+\s+${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){2}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){3}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){4}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){5}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){6}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){7}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){8}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){9}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){10}${INTERFACES},* -> Continue
  ^\s+(?:\S+\s+){11}${INTERFACES} -> Continue
  ^\d+
  ^\s+
  ^-+
  ^\S+\s+[TtYyPpEe]{4} -> Done
  ^.+ -> Error

Done
  ^.*


FSM Table:
['VLAN_ID', 'NAME', 'STATUS', 'INTERFACES']
['1', 'default', 'active', ['Gi1/0/2', 'Gi1/0/3', 'Gi1/0/4', 'Gi1/0/7', 'Gi1/0/12', 'Gi1/0/16', 'Gi1/0/17', 'Gi1/0/18', 'Gi1/0/19', 'Gi1/0/22', 'Gi1/0/23', 'Gi1/0/29', 'Gi2/0/22', 'Gi2/0/23', 'Gi2/0/24', 'Gi2/0/25', 'Gi2/0/26', 'Gi2/0/27', 'Gi2/0/28', 'Gi2/0/29', 'Gi2/0/30', 'Gi2/0/31', 'Gi2/0/32', 'Gi2/0/33']]
['32', 'vlan_32', 'active', []]
['35', 'vlan_35', 'active', []]
['36', 'vlan_36', 'active', []]
['37', 'vlan_37', 'active', []]
['38', 'vlan_38', 'active', []]
['39', 'vlan_39', 'active', []]
['40', 'vlan_40', 'active', []]
['41', 'vlan_41', 'active', []]
['50', 'vlan_50', 'active', []]
['1002', 'vlan_1002', 'act/unsup', []]
['1003', 'vlan_1003', 'act/unsup', []]
['1004', 'vlan_1004', 'act/unsup', []]
['1005', 'vlan_1005', 'act/unsup', []]
['2100', 'vlan_2100', 'active', []]
['2101', 'vlan_2101', 'active', ['Gi1/0/6', 'Gi1/0/15']]
['2102', 'vlan_2102', 'active', []]
['2103', 'vlan_2103', 'active', []]
['2104', 'vlan_2104', 'active', ['Gi2/0/10', 'Gi2/0/11', 'Gi2/0/12', 'Gi2/0/20']]
['2111', 'vlan_2111', 'active', []]
['2112', 'vlan_2112', 'active', ['Gi1/0/21']]
['3350', 'vlan_3350', 'active', []]
['3351', 'vlan_3351', 'active', ['Gi1/0/10', 'Gi1/0/28']]
['3363', 'vlan_3363', 'active', ['Gi1/0/1', 'Gi1/0/11', 'Gi2/0/1']]
['3364', 'vlan_3364', 'active', []]
['3365', 'vlan_3365', 'active', []]
['3366', 'vlan_3366', 'active', []]
['3367', 'vlan_3367', 'active', []]
['3368', 'vlan_3368', 'active', []]
['3369', 'vlan_3369', 'active', []]
['3370', 'vlan_3370', 'active', []]
['3371', 'vlan_3371', 'active', []]
['3373', 'vlan_3373', 'active', ['Gi1/0/8']]
['3374', 'vlan_3374', 'active', ['Gi1/0/20']]
['3428', 'vlan_3428', 'active', []]
['3460', 'vlan_3460', 'active', []]
['3468', 'vlan_3468', 'active', []]
['3469', 'vlan_3469', 'active', ['Gi1/0/26', 'Gi1/0/27']]
['3470', 'vlan_3470', 'active', []]
['3472', 'vlan_3472', 'active', []]

ios show standby brief active/standby state

To handle IP addresses, I think active/standby fields should be \S instead of \w.

Value ACTIVE (\S+)
Value STANDBY (\S+)

Interface Grp Pri P State Active Standby Virtual IP
Vl1111 200 150 P Standby 133.33.16.2 local 133.33.16.1
Vl1112 300 150 P Standby 132.31.16.32 local 132.31.16.33

cisco_asa_show_vpn-sessiondb_detail_l2l.template not parsing

ISSUE TYPE
  • Bug Report
TEMPLATE USING
cisco_asa_show_vpn-sessiondb_detail_l2l.template
SAMPLE COMMAND OUTPUT
'\nSession Type: LAN-to-LAN Detailed\n\nConnection   : p.p.p.p\nIndex        : 508                    IP Addr      : p.p.p.p\nProtocol     : IKE IPsec\nEncryption   : 3DES                   Hashing      : SHA1\nBytes Tx     : 0                      Bytes Rx     : 12360\nLogin Time   : 06:59:55 PDT Sat Jul 21 2018\nDuration     : 3h:33m:32s\nIKE Tunnels: 1\nIPsec Tunnels: 1\n\nIKE:\n  Tunnel ID    : 508.1\n  UDP Src Port : 500                    UDP Dst Port : 500\n  IKE Neg Mode : Main                   Auth Mode    : preSharedKeys\n  Encryption   : 3DES                   Hashing      : SHA1\n  Rekey Int (T): 28800 Seconds          Rekey Left(T): 15987 Seconds\n  D/H Group    : 2\n  Filter Name  : acl_Tarzana\n  IPv6 Filter  : \n\nIPsec:\n  Tunnel ID    : 508.2\n  Local Addr   : x.x.x.x.0/255.255.252.0/0/0\n  Remote Addr  : y.y.y.y/255.255.255.255/0/0\n  Encryption   : 3DES                   Hashing      : SHA1                   \n  Encapsulation: Tunnel                 \n  Rekey Int (T): 28800 Seconds          Rekey Left(T): 15987 Seconds          \n  Idle Time Out: 30 Minutes             Idle TO Left : 29 Minutes             \n  Bytes Tx     : 0                      Bytes Rx     : 12360                  \n  Pkts Tx      : 0                      Pkts Rx      : 206                    \n  \nNAC:\n  Reval Int (T): 0 Seconds              Reval Left(T): 0 Seconds\n  SQ Int (T)   : 0 Seconds              EoU Age(T)   : 12813 Seconds\n  Hold Left (T): 0 Seconds              Posture Token: \n  Redirect URL : \n\nConnection 
SUMMARY

Not getting formatted data back, only a long string

STEPS TO REPRODUCE
output = net_conn.send_command("show vpn-sessiondb detail l2l", use_textfsm=True)
EXPECTED RESULTS

expected formatted data like I get from the following command
output = net_conn.send_command("show running-config tunnel-group", use_textfsm=True)

[{'name': 'x.x.x.x',
'type': 'ipsec-l2l',
'dhcp_selection': [],
'dhcp_server': [],
'authorization': '',
'authorization_intfc': '',
'authorization_grp': '',
'accounting_grp': '',
'ipv4_pool_intfc': '',
'ipv4_pool_name': '',
'authentication_intfc': '',
'authentication_pri_grp': '',
'authentication_sec_grp': '',
'authentication_svr': '',
'authenticated_user': '',
'group_policy': 'gp-lab1',
'ipv6_pool_intfc': '',
'ipv6_pool_name': '',
'nat_intfc': '',
'scep_enroll': '',
'sec_authentication_grp_intfc': '',
'sec_authentication_pri_grp': '',
'sec_authentication_sec_grp': '',
'sec_authentication_use_pri_user': '',
'sec_cert_codes': '',
'sec_cert_fallback': '',
'pri_cert_codes': '',
'pri_cert_fallback': '',
'strip_grp': '',
'strip_realm': '',
'ikev1_psk': '',
'chain': '',
'client_os': [],
'update_url': [],
'revs': [],
'trust_point': '',
'ikev1_user_auth_intfc': [],
'ikev1_user_auth_type': [],
'ikev2_local_auth_cert': '',
'ikev2_remote_auth_type': [],
'peer_id_validate': '',
'radius_with_expiry': '',
'ppp_auth_type': [],
'webvpn_auth': '',
'webvpn_custom': '',
'dns_grp': '',
'webvpn_grp_alias': [],
'webvpn_grp_alias_state': [],
'webvpn_grp_url': [],
'webvpn_grp_url_state': [],
'nbns_svr': [],
'nbns_master': [],
'nbns_timeout': [],
'nbns_retry': [],
'override_svc_download': '',
'pri_prefill_user_type': [],
'sec_prefill_user_type': [],
'proxy_auth': '',
'radius_reject_msg': '',
'saml_id_provider': '',
'without_csd': ''},

ACTUAL RESULTS
'\nSession Type: LAN-to-LAN Detailed\n\nConnection   : 69.238.162.252\nIndex        : 508                    IP Addr      : 69.238.162.252\nProtocol     : IKE IPsec\nEncryption   : 3DES                   Hashing      : SHA1\nBytes Tx     : 0                      Bytes Rx     : 12360\nLogin Time   : 06:59:55 PDT Sat Jul 21 2018\nDuration     : 3h:33m:32s\nIKE Tunnels: 1\nIPsec Tunnels: 1\n\nIKE:\n  Tunnel ID    : 508.1\n  UDP Src Port : 500                    UDP Dst Port : 500\n  IKE Neg Mode : Main                   Auth Mode    : preSharedKeys\n  Encryption   : 3DES                   Hashing      : SHA1\n  Rekey Int (T): 28800 Seconds          Rekey Left(T): 15987 Seconds\n  D/H Group    : 2\n  Filter Name  : acl_Tarzana\n  IPv6 Filter  : \n\nIPsec:\n  Tunnel ID    : 508.2\n  Local Addr   : 166.124.120.0/255.255.252.0/0/0\n  Remote Addr  : 170.220.248.71/255.255.255.255/0/0\n  Encryption   : 3DES                   Hashing      : SHA1                   \n  Encapsulation: Tunnel                 \n  Rekey Int (T): 28800 Seconds          Rekey Left(T): 15987 Seconds          \n  Idle Time Out: 30 Minutes             Idle TO Left : 29 Minutes             \n  Bytes Tx     : 0                      Bytes Rx     : 12360                  \n  Pkts Tx      : 0                      Pkts Rx      : 206                    \n  \nNAC:\n  Reval Int (T): 0 Seconds              Reval Left(T): 0 Seconds\n  SQ Int (T)   : 0 Seconds              EoU Age(T)   : 12813 Seconds\n  Hold Left (T): 0 Seconds              Posture Token: \n  Redirect URL : \n\nConnection 

show interface status for cisco_nxos returns incorrect 'name' and 'port' objects if there are spaces in the description.

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value PORT (.*?)
Value NAME (\S+(?:\s\w+\s\w+)?)
Value STATUS (\w+?)
Value VLAN (\w+|\d+?)
Value DUPLEX (full|auto|half)
Value SPEED (.*?)
Value TYPE (.*?)

Start
  ^${PORT}\s+${NAME}\s+${STATUS}\s+${VLAN}\s+${DUPLEX}\s+${SPEED}\s+${TYPE}$$ -> Record
SAMPLE COMMAND OUTPUT
show int status

--------------------------------------------------------------------------------
Port          Name               Status    Vlan      Duplex  Speed   Type
--------------------------------------------------------------------------------
PORT          DESCRI PTION       STATUS    VLAN      DUPLEX  SPEED   TYPE       
SUMMARY

When run, part of the "Name" ends up in the "Port" field, and the rest of the "Name" is added to the "Name" field

STEPS TO REPRODUCE
import sys, getpass
from netmiko import ConnectHandler

try:
    username = raw_input("Username: ")
    password = getpass.getpass("Password: ")
    enable = getpass.getpass("Enable: ")
    #Test Switch
    device = {
        'device_type': 'cisco_nxos',
        'ip':   ip,
        'username': username,
        'password': password,
        'secret': enable,
    }
    command = 'show interface status'
    net_connect = ConnectHandler(**device)
    net_connect.enable()
    active_iface = net_connect.send_command(command, use_textfsm=True)
    net_connect.disconnect()
    for i in active_iface: print(i,)
except Exception as e:
    print('Error on line {}'.format(sys.exc_info()[-1].tb_lineno), type(e).__name__, e)
EXPECTED RESULTS
({'status': 'STATUS', 'name': 'DESCRI PTION', 'duplex': 'DUPLEX', 'type': 'TYPE', 'vlan': 'VLAN', 'speed': 'SPEED', 'port': 'PORT'},)
ACTUAL RESULTS
({'status': 'STATUS', 'name': 'PTION', 'duplex': 'DUPLEX', 'type': 'TYPE', 'vlan': 'VLAN', 'speed': 'SPEED', 'port': 'PORT        DESCRI'},)

Unable to parse out subinterface information from Cisco IOS content

did not find anything closely related to this issue

Here is the envifonment
Claudias-iMac:textfsm-example claudia$ pip freeze
et-xmlfile==1.0.1
graphviz==0.8.2
jdcal==1.3
netaddr==0.7.19
openpyxl==2.5.1
textfsm==0.4.1
xlrd==1.1.0

also had same issue with
textfsm==0.3.2

ISSUE TYPE
  • Template Creation Help
TEMPLATE USING

Using the latest "stock" ntc template for cisco_ios_show_interfaces.template

Value Required INTERFACE (\S+)
Value LINK_STATUS (\w+)
Value PROTOCOL_STATUS (.*)
Value HARDWARE_TYPE ([\w ]+)
Value ADDRESS ([a-zA-Z0-9]+.[a-zA-Z0-9]+.[a-zA-Z0-9]+)
Value BIA ([a-zA-Z0-9]+.[a-zA-Z0-9]+.[a-zA-Z0-9]+)
Value DESCRIPTION (.*)
Value IP_ADDRESS (\d+\.\d+\.\d+\.\d+\/\d+)
Value MTU (\d+)
Value DUPLEX (.+?)
Value SPEED (.+?)
Value BANDWIDTH (\d+\s+\w+)
Value DELAY (\d+\s+\w+)
Value ENCAPSULATION (\w+)
Value QUEUE_STRATEGY (.*)
Value INPUT_RATE (\d+)
Value OUTPUT_RATE (\d+)

Start
  ^${INTERFACE} is ${LINK_STATUS}.*protocol is ${PROTOCOL_STATUS}
  ^\s+Hardware is ${HARDWARE_TYPE} -> Continue
  ^.*address is ${ADDRESS}.*bia ${BIA}
  ^\s+Description: ${DESCRIPTION}
  ^\s+Internet address is ${IP_ADDRESS}
  ^\s+MTU ${MTU}.*BW ${BANDWIDTH}.*DLY ${DELAY}
  ^\s+Encapsulation ${ENCAPSULATION}
  ^\s+Queueing strategy: ${QUEUE_STRATEGY}
  ^\s+${DUPLEX}, ${SPEED}, media type
  ^.*input rate ${INPUT_RATE}
  ^.*output rate ${OUTPUT_RATE} -> Record
SAMPLE COMMAND OUTPUT
!!show int
GigabitEthernet0/0 is up, line protocol is up 
  Hardware is MV96340 Ethernet, address is 000f.352d.2381 (bia 000f.352d.2381)
  Description: Connects to LAN
  MTU 1500 bytes, BW 100000 Kbit/sec, DLY 100 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation 802.1Q Virtual LAN, Vlan ID  1., loopback not set
  Keepalive set (10 sec)
  Full Duplex, 100Mbps, media type is T
  output flow-control is XON, input flow-control is XON
  ARP type: ARPA, ARP Timeout 04:00:00
  Last input 00:00:24, output 00:00:00, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/40 (size/max)
  30 second input rate 95000 bits/sec, 57 packets/sec
  30 second output rate 90000 bits/sec, 54 packets/sec
     338297234 packets input, 728401053 bytes, 0 no buffer
     Received 3192290 broadcasts (8982 IP multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
     0 watchdog, 0 multicast, 0 pause input
     336857668 packets output, 917906120 bytes, 0 underruns
     0 output errors, 0 collisions, 2 interface resets
     135 unknown protocol drops
     0 babbles, 0 late collision, 0 deferred
     7 lost carrier, 0 no carrier, 0 pause output
     0 output buffer failures, 0 output buffers swapped out
GigabitEthernet0/0.6 is up, line protocol is up 
  Hardware is MV96340 Ethernet, address is 000f.352d.2381 (bia 000f.352d.2381)
  Description: LAN
  Internet address is 192.27.6.129/26
  MTU 1500 bytes, BW 100000 Kbit/sec, DLY 100 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation 802.1Q Virtual LAN, Vlan ID  6.
  ARP type: ARPA, ARP Timeout 04:00:00
  Keepalive set (10 sec)
  Last clearing of "show interface" counters never
GigabitEthernet0/0.44 is up, line protocol is up 
  Hardware is MV96340 Ethernet, address is 000f.352d.2381 (bia 000f.352d.2381)
  Description: Wireless LAN
  Internet address is 192.22.44.193/26
  MTU 1500 bytes, BW 100000 Kbit/sec, DLY 100 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation 802.1Q Virtual LAN, Vlan ID  44.
  ARP type: ARPA, ARP Timeout 04:00:00
  Keepalive set (10 sec)
  Last clearing of "show interface" counters never
GigabitEthernet0/0.188 is up, line protocol is up 
  Hardware is MV96340 Ethernet, address is 000f.352d.2381 (bia 000f.352d.2381)
  Description: Voice LAN
  Internet address is 192.24.188.65/26
  MTU 1500 bytes, BW 100000 Kbit/sec, DLY 100 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation 802.1Q Virtual LAN, Vlan ID  188.
  ARP type: ARPA, ARP Timeout 04:00:00
  Keepalive set (10 sec)
  Last clearing of "show interface" counters never
GigabitEthernet0/0.666 is up, line protocol is up 
  Hardware is MV96340 Ethernet, address is 000f.352d.2381 (bia 000f.352d.2381)
  Description: Native Vlan
  MTU 1500 bytes, BW 100000 Kbit/sec, DLY 100 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation 802.1Q Virtual LAN, Vlan ID  888.
  ARP type: ARPA, ARP Timeout 04:00:00
  Keepalive set (10 sec)
  Last clearing of "show interface" counters never
GigabitEthernet0/1 is administratively down, line protocol is down 
  Hardware is MV96340 Ethernet, address is 000f.352d.2382 (bia 000f.352d.2382)
  Description: NOT IN USE 
  MTU 1500 bytes, BW 1000000 Kbit/sec, DLY 10 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation ARPA, loopback not set
  Keepalive set (10 sec)
  Auto Duplex, Auto Speed, media type is T
  output flow-control is XON, input flow-control is XON
  ARP type: ARPA, ARP Timeout 04:00:00
  Last input never, output never, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/40 (size/max)
  5 minute input rate 0 bits/sec, 0 packets/sec
  5 minute output rate 0 bits/sec, 0 packets/sec
     0 packets input, 0 bytes, 0 no buffer
     Received 0 broadcasts (0 IP multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
     0 watchdog, 0 multicast, 0 pause input
     0 packets output, 0 bytes, 0 underruns
     0 output errors, 0 collisions, 0 interface resets
     0 unknown protocol drops
     0 babbles, 0 late collision, 0 deferred
     2 lost carrier, 0 no carrier, 0 pause output
     0 output buffer failures, 0 output buffers swapped out
FastEthernet0/1/0 is up, line protocol is up 
  Hardware is FastEthernet, address is b838.6148.8780 (bia b838.6148.8780)
  Description: connection to Provider
  MTU 1500 bytes, BW 10000 Kbit/sec, DLY 100 usec, 
     reliability 255/255, txload 2/255, rxload 2/255
  Encapsulation 802.1Q Virtual LAN, Vlan ID  1., loopback not set
  Keepalive set (10 sec)
  Full-duplex, 100Mb/s, 100BaseTX/FX
  ARP type: ARPA, ARP Timeout 04:00:00
  Last input 00:00:00, output 00:00:00, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 1063
  Queueing strategy: Class-based queueing
  Output queue: 0/1000/0 (size/max total/drops)
  30 second input rate 96000 bits/sec, 63 packets/sec
  30 second output rate 111000 bits/sec, 67 packets/sec
     338645504 packets input, 2415768496 bytes
     Received 0 broadcasts (401278 IP multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
     0 watchdog
     0 input packets with dribble condition detected
     350115018 packets output, 1559928782 bytes, 0 underruns
     0 output errors, 0 collisions, 4 interface resets
     0 unknown protocol drops
     0 babbles, 0 late collision, 0 deferred
     3 lost carrier, 0 no carrier
     0 output buffer failures, 0 output buffers swapped out
FastEthernet0/1/0.50 is up, line protocol is up 
  Hardware is FastEthernet, address is b838.6148.8780 (bia b838.6148.8780)
  Description: AVPN Circuit 
  Internet address is 192.20.194.29/30
  MTU 1500 bytes, BW 10000 Kbit/sec, DLY 100 usec, 
     reliability 255/255, txload 2/255, rxload 2/255
  Encapsulation 802.1Q Virtual LAN, Vlan ID  50.
  ARP type: ARPA, ARP Timeout 04:00:00
  Keepalive set (10 sec)
  Last clearing of "show interface" counters never
FastEthernet0/1/1 is administratively down, line protocol is down 
  Hardware is FastEthernet, address is b838.6148.8781 (bia b838.6148.8781)
  Description: NOT IN USE 
  MTU 1500 bytes, BW 100000 Kbit/sec, DLY 100 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation ARPA, loopback not set
  Keepalive set (10 sec)
  Auto-duplex, Auto Speed, 100BaseTX/FX
  ARP type: ARPA, ARP Timeout 04:00:00
  Last input never, output never, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/40 (size/max)
  5 minute input rate 0 bits/sec, 0 packets/sec
  5 minute output rate 0 bits/sec, 0 packets/sec
     0 packets input, 0 bytes
     Received 0 broadcasts (0 IP multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
     0 watchdog
     0 input packets with dribble condition detected
     0 packets output, 0 bytes, 0 underruns
     0 output errors, 0 collisions, 1 interface resets
     0 unknown protocol drops
     0 babbles, 0 late collision, 0 deferred
     0 lost carrier, 0 no carrier
     0 output buffer failures, 0 output buffers swapped out
Loopback0 is up, line protocol is up 
  Hardware is Loopback
  Description: Loopback Interface
  Internet address is 192.20.0.144/32
  MTU 1514 bytes, BW 8000000 Kbit/sec, DLY 5000 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation LOOPBACK, loopback not set
  Keepalive set (10 sec)
  Last input never, output never, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/0 (size/max)
  5 minute input rate 0 bits/sec, 0 packets/sec
  5 minute output rate 0 bits/sec, 0 packets/sec
     2292 packets input, 457464 bytes, 0 no buffer
     Received 0 broadcasts (0 IP multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
     0 packets output, 0 bytes, 0 underruns
     0 output errors, 0 collisions, 0 interface resets
     0 unknown protocol drops
     0 output buffer failures, 0 output buffers swapped out
Tunnel0 is up, line protocol is up 
  Hardware is Tunnel
  Interface is unnumbered. Using address of FastEthernet0/1/0.50 (192.20.194.29)
  MTU 17912 bytes, BW 100 Kbit/sec, DLY 50000 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation TUNNEL, loopback not set
  Keepalive not set
  Tunnel source 192.20.194.29 (FastEthernet0/1/0.50), destination 192.20.18.147
   Tunnel Subblocks:
      src-track:
         Tunnel0 source tracking subblock associated with FastEthernet0/1/0.50
          Set of tunnels with source FastEthernet0/1/0.50, 4 members (includes iterators), on interface <OK>
  Tunnel protocol/transport PIM/IPv4
  Tunnel TOS/Traffic Class 0xC0,  Tunnel TTL 255
  Tunnel transport MTU 1472 bytes
  Tunnel is transmit only
  Tunnel transmit bandwidth 8000 (kbps)
  Tunnel receive bandwidth 8000 (kbps)
  Last input never, output never, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/0 (size/max)
  5 minute input rate 0 bits/sec, 0 packets/sec
  5 minute output rate 0 bits/sec, 0 packets/sec
     0 packets input, 0 bytes, 0 no buffer
     Received 0 broadcasts (0 IP multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
     0 packets output, 0 bytes, 0 underruns
     0 output errors, 0 collisions, 0 interface resets
     0 unknown protocol drops
     0 output buffer failures, 0 output buffers swapped out
Tunnel1 is up, line protocol is up 
  Hardware is Tunnel
  Interface is unnumbered. Using address of FastEthernet0/1/0.50 (192.20.194.29)
  MTU 17912 bytes, BW 100 Kbit/sec, DLY 50000 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation TUNNEL, loopback not set
  Keepalive not set
  Tunnel source 192.20.194.29 (FastEthernet0/1/0.50), destination 192.20.18.148
   Tunnel Subblocks:
      src-track:
         Tunnel1 source tracking subblock associated with FastEthernet0/1/0.50
          Set of tunnels with source FastEthernet0/1/0.50, 4 members (includes iterators), on interface <OK>
  Tunnel protocol/transport PIM/IPv4
  Tunnel TOS/Traffic Class 0xC0,  Tunnel TTL 255
  Tunnel transport MTU 1472 bytes
  Tunnel is transmit only
  Tunnel transmit bandwidth 8000 (kbps)
  Tunnel receive bandwidth 8000 (kbps)
  Last input never, output never, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/0 (size/max)
  5 minute input rate 0 bits/sec, 0 packets/sec
  5 minute output rate 0 bits/sec, 0 packets/sec
     0 packets input, 0 bytes, 0 no buffer
     Received 0 broadcasts (0 IP multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
     0 packets output, 0 bytes, 0 underruns
     0 output errors, 0 collisions, 0 interface resets
     0 unknown protocol drops
     0 output buffer failures, 0 output buffers swapped out
Tunnel2 is up, line protocol is up 
  Hardware is Tunnel
  Interface is unnumbered. Using address of FastEthernet0/1/0.50 (192.20.194.29)
  MTU 17912 bytes, BW 100 Kbit/sec, DLY 50000 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation TUNNEL, loopback not set
  Keepalive not set
  Tunnel source 192.20.194.29 (FastEthernet0/1/0.50), destination 192.29.0.2
   Tunnel Subblocks:
      src-track:
         Tunnel2 source tracking subblock associated with FastEthernet0/1/0.50
          Set of tunnels with source FastEthernet0/1/0.50, 4 members (includes iterators), on interface <OK>
  Tunnel protocol/transport PIM/IPv4
  Tunnel TOS/Traffic Class 0xC0,  Tunnel TTL 255
  Tunnel transport MTU 1472 bytes
  Tunnel is transmit only
  Tunnel transmit bandwidth 8000 (kbps)
  Tunnel receive bandwidth 8000 (kbps)
  Last input never, output never, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/0 (size/max)
  5 minute input rate 0 bits/sec, 0 packets/sec
  5 minute output rate 0 bits/sec, 0 packets/sec
     0 packets input, 0 bytes, 0 no buffer
     Received 0 broadcasts (0 IP multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
     0 packets output, 0 bytes, 0 underruns
     0 output errors, 0 collisions, 0 interface resets
     0 unknown protocol drops
     0 output buffer failures, 0 output buffers swapped out
Tunnel3 is up, line protocol is up 
  Hardware is Tunnel
  Interface is unnumbered. Using address of FastEthernet0/1/0.50 (192.20.194.29)
  MTU 17912 bytes, BW 100 Kbit/sec, DLY 50000 usec, 
     reliability 255/255, txload 1/255, rxload 1/255
  Encapsulation TUNNEL, loopback not set
  Keepalive not set
  Tunnel source 192.20.194.29 (FastEthernet0/1/0.50), destination 192.29.0.3
   Tunnel Subblocks:
      src-track:
         Tunnel3 source tracking subblock associated with FastEthernet0/1/0.50
          Set of tunnels with source FastEthernet0/1/0.50, 4 members (includes iterators), on interface <OK>
  Tunnel protocol/transport PIM/IPv4
  Tunnel TOS/Traffic Class 0xC0,  Tunnel TTL 255
  Tunnel transport MTU 1472 bytes
  Tunnel is transmit only
  Tunnel transmit bandwidth 8000 (kbps)
  Tunnel receive bandwidth 8000 (kbps)
  Last input never, output never, output hang never
  Last clearing of "show interface" counters never
  Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
  Queueing strategy: fifo
  Output queue: 0/0 (size/max)
  5 minute input rate 0 bits/sec, 0 packets/sec
  5 minute output rate 0 bits/sec, 0 packets/sec
     0 packets input, 0 bytes, 0 no buffer
     Received 0 broadcasts (0 IP multicasts)
     0 runts, 0 giants, 0 throttles
     0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
     0 packets output, 0 bytes, 0 underruns
     0 output errors, 0 collisions, 0 interface resets
     0 unknown protocol drops
     0 output buffer failures, 0 output buffers swapped out
SUMMARY

When I try to extract the interface information using this template, it does not pick up the subinterfaces. When I run the same data through the show ip int brief template they are picked up, I've tested the REGEXP and it should pick it up (I believe).

STEPS TO REPRODUCE

here is an example of the data using the ntc standard show ip int brief template and you can see that the subinterfaces are there.

>>> import textfsm
>>> content_fh = open('router-show-commands.txt')
>>> content = content_fh.read()
>>> intbrt = open('cisco_ios_show_ip_int_brief.template')
>>> intbr_table = textfsm.TextFSM(intbrt)
>>> intbr_results = intbr_table.ParseText(content)
>>> intbr_results
[['GigabitEthernet0/0', 'unassigned', 'up', 'up'], ['GigabitEthernet0/0.6', '192.27.6.129', 'up', 'up'], ['GigabitEthernet0/0.44', '192.22.44.193', 'up', 'up'], ['GigabitEthernet0/0.188', '192.24.188.65', 'up', 'up'], ['GigabitEthernet0/0.888', 'unassigned', 'up', 'up'], ['GigabitEthernet0/1', 'unassigned', 'administratively down', 'down'], ['FastEthernet0/1/0', 'unassigned', 'up', 'up'], ['FastEthernet0/1/0.50', '192.20.194.29', 'up', 'up'], ['FastEthernet0/1/1', 'unassigned', 'administratively down', 'down'], ['Loopback0', '192.20.0.144', 'up', 'up'], ['Tunnel0', '192.20.194.29', 'up', 'up'], ['Tunnel1', '192.20.194.29', 'up', 'up'], ['Tunnel2', '192.20.194.29', 'up', 'up'], ['Tunnel3', '192.20.194.29', 'up', 'up']]
>>>
>>> for i in intbr_results:
...   print(i)
...
['GigabitEthernet0/0', 'unassigned', 'up', 'up']
['GigabitEthernet0/0.6', '192.27.6.129', 'up', 'up']
['GigabitEthernet0/0.44', '192.22.44.193', 'up', 'up']
['GigabitEthernet0/0.188', '192.24.188.65', 'up', 'up']
['GigabitEthernet0/0.888', 'unassigned', 'up', 'up']
['GigabitEthernet0/1', 'unassigned', 'administratively down', 'down']
['FastEthernet0/1/0', 'unassigned', 'up', 'up']
['FastEthernet0/1/0.50', '192.20.194.29', 'up', 'up']
['FastEthernet0/1/1', 'unassigned', 'administratively down', 'down']
['Loopback0', '192.20.0.144', 'up', 'up']
['Tunnel0', '192.20.194.29', 'up', 'up']
['Tunnel1', '192.20.194.29', 'up', 'up']
['Tunnel2', '192.20.194.29', 'up', 'up']
['Tunnel3', '192.20.194.29', 'up', 'up']
>>>


If you look at the value maps the REGEX is
from the show int template
'INTERFACE': '(?P\S+)'

from the show ip int br template
'INTF': '(?P\S+)'

so I'm assuming its the downstream logic that may be the issue...I'm just guessing
router-show-commands.txt

>>> int_table.value_map
{'QUEUE_STRATEGY': '(?P<QUEUE_STRATEGY>.*)', 'HARDWARE_TYPE': '(?P<HARDWARE_TYPE>[\\w ]+)', 'INPUT_RATE': '(?P<INPUT_RATE>\\d+)', 'DESCRIPTION': '(?P<DESCRIPTION>.*)', 'LINK_STATUS': '(?P<LINK_STATUS>\\w+)', 'OUTPUT_RATE': '(?P<OUTPUT_RATE>\\d+)', 'DUPLEX': '(?P<DUPLEX>.+?)', 'SPEED': '(?P<SPEED>.+?)', 'PROTOCOL_STATUS': '(?P<PROTOCOL_STATUS>.*)', 'BIA': '(?P<BIA>[a-zA-Z0-9]+.[a-zA-Z0-9]+.[a-zA-Z0-9]+)', 'DELAY': '(?P<DELAY>\\d+\\s+\\w+)', 'BANDWIDTH': '(?P<BANDWIDTH>\\d+\\s+\\w+)', 'ADDRESS': '(?P<ADDRESS>[a-zA-Z0-9]+.[a-zA-Z0-9]+.[a-zA-Z0-9]+)', 'INTERFACE': '(?P<INTERFACE>\\S+)', 'ENCAPSULATION': '(?P<ENCAPSULATION>\\w+)', 'MTU': '(?P<MTU>\\d+)', 'IP_ADDRESS': '(?P<IP_ADDRESS>\\d+\\.\\d+\\.\\d+\\.\\d+\\/\\d+)'}
>>> intbr_table.value_map
{'STATUS': '(?P<STATUS>up|down|administratively down)', 'INTF': '(?P<INTF>\\S+)', 'IPADDR': '(?P<IPADDR>\\S+)', 'PROTO': '(?P<PROTO>up|down)'}
EXPECTED RESULTS

I would expect to see all the interfaces as shown in the ip int brief output but with the additional values.

ACTUAL RESULTS

The parsing only picks up the whole interfaces and does not grab the correct IPs.
I tried the file with just the show interface commands (vs the entire file which has a bunch of show commands). I tried updating the form to grab fewer values. I'm afraid I've used up my meager skills to get this far!

Here is the output using the show interface template. No subinterfaces and its picking up the last subinterface IP for Gi0/0 and applying it to Gi0/1.

Claudias-iMac:textfsm-example claudia$ python
Python 2.7.10 (default, Feb  7 2017, 00:08:15)
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import textfsm
>>> content_fh = open('router-show-commands.txt')
>>> content = content_fh.read()
>>> intt = open('cisco_ios_show_interfaces.template')
>>> int_table = textfsm.TextFSM(intt)
>>> int_result = int_table.ParseText(content)
>>> int_result
[['GigabitEthernet0/0', 'up', 'up ', 'MV96340 Ethernet', '000f.352d.2381', '000f.352d.2381', 'Connects to Fas0/1 on do-z020-6u3550a', '', '1500', 'Full Duplex', '100Mbps', '100000 Kbit', '100 usec', '802', 'fifo', '95000', '90000'], ['GigabitEthernet0/1', 'administratively', 'down ', 'MV96340 Ethernet', '000f.352d.2382', '000f.352d.2382', '*** NOT IN USE ***', '192.24.188.65/26', '1500', 'Auto Duplex', 'Auto Speed', '1000000 Kbit', '10 usec', 'ARPA', 'fifo', '0', '0'], ['FastEthernet0/1/0', 'up', 'up ', 'FastEthernet', 'b838.6148.8780', 'b838.6148.8780', 'connection to AT&T SEE *** SUB-INTERFACE ***', '', '1500', '', '', '10000 Kbit', '100 usec', '802', 'Class-based queueing', '96000', '111000'], ['FastEthernet0/1/1', 'administratively', 'down ', 'FastEthernet', 'b838.6148.8781', 'b838.6148.8781', '*** NOT IN USE ***', '192.20.194.29/30', '1500', '', '', '100000 Kbit', '100 usec', 'ARPA', 'fifo', '0', '0'], ['Loopback0', 'up', 'up ', 'Loopback', '', '', 'Loopback Interface: (Management, OSPF Router ID, DLSW peer, etc.)', '192.20.0.144/32', '1514', '', '', '8000000 Kbit', '5000 usec', 'LOOPBACK', 'fifo', '0', '0'], ['Tunnel0', 'up', 'up ', 'Tunnel', '', '', '', '', '17912', '', '', '100 Kbit', '50000 usec', 'TUNNEL', 'fifo', '0', '0'], ['Tunnel1', 'up', 'up ', 'Tunnel', '', '', '', '', '17912', '', '', '100 Kbit', '50000 usec', 'TUNNEL', 'fifo', '0', '0'], ['Tunnel2', 'up', 'up ', 'Tunnel', '', '', '', '', '17912', '', '', '100 Kbit', '50000 usec', 'TUNNEL', 'fifo', '0', '0'], ['Tunnel3', 'up', 'up ', 'Tunnel', '', '', '', '', '17912', '', '', '100 Kbit', '50000 usec', 'TUNNEL', 'fifo', '0', '0']]
>>> for i in int_result:
...   print(i)
...
['GigabitEthernet0/0', 'up', 'up ', 'MV96340 Ethernet', '000f.352d.2381', '000f.352d.2381', 'Connects to Fas0/1 on do-z020-6u3550a', '', '1500', 'Full Duplex', '100Mbps', '100000 Kbit', '100 usec', '802', 'fifo', '95000', '90000']
['GigabitEthernet0/1', 'administratively', 'down ', 'MV96340 Ethernet', '000f.352d.2382', '000f.352d.2382', '*** NOT IN USE ***', '192.24.188.65/26', '1500', 'Auto Duplex', 'Auto Speed', '1000000 Kbit', '10 usec', 'ARPA', 'fifo', '0', '0']
['FastEthernet0/1/0', 'up', 'up ', 'FastEthernet', 'b838.6148.8780', 'b838.6148.8780', 'connection to AT&T SEE *** SUB-INTERFACE ***', '', '1500', '', '', '10000 Kbit', '100 usec', '802', 'Class-based queueing', '96000', '111000']
['FastEthernet0/1/1', 'administratively', 'down ', 'FastEthernet', 'b838.6148.8781', 'b838.6148.8781', '*** NOT IN USE ***', '192.20.194.29/30', '1500', '', '', '100000 Kbit', '100 usec', 'ARPA', 'fifo', '0', '0']
['Loopback0', 'up', 'up ', 'Loopback', '', '', 'Loopback Interface: (Management, OSPF Router ID, DLSW peer, etc.)', '192.20.0.144/32', '1514', '', '', '8000000 Kbit', '5000 usec', 'LOOPBACK', 'fifo', '0', '0']
['Tunnel0', 'up', 'up ', 'Tunnel', '', '', '', '', '17912', '', '', '100 Kbit', '50000 usec', 'TUNNEL', 'fifo', '0', '0']
['Tunnel1', 'up', 'up ', 'Tunnel', '', '', '', '', '17912', '', '', '100 Kbit', '50000 usec', 'TUNNEL', 'fifo', '0', '0']
['Tunnel2', 'up', 'up ', 'Tunnel', '', '', '', '', '17912', '', '', '100 Kbit', '50000 usec', 'TUNNEL', 'fifo', '0', '0']
['Tunnel3', 'up', 'up ', 'Tunnel', '', '', '', '', '17912', '', '', '100 Kbit', '50000 usec', 'TUNNEL', 'fifo', '0', '0']
>>> exit()
(cat_scripts) Claudias-iMac:textfsm-example claudia$ pip freeze
et-xmlfile==1.0.1
graphviz==0.8.2
jdcal==1.3
netaddr==0.7.19
openpyxl==2.5.1
textfsm==0.4.1
xlrd==1.1.0

License question

NetworkToCode, I am wondering what the licensing is for the TextFSM templates embedded in this project? Can this project please add a LICENSE file to the root of the project to be more clear? (MIT? :P)

Regards!

show ip route IOS vs NXOS

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value Filldown PROTOCOL (\w)
Value Filldown TYPE (\w{0,2})
Value Required,Filldown NETWORK (\d{1,3}.\d{1,3}.\d{1,3}.\d{1,3})
Value Filldown MASK (\d{1,2})
Value DISTANCE (\d+)
Value METRIC (\d+)
Value NEXTHOP_IP (\d{1,3}.\d{1,3}.\d{1,3}.\d{1,3})
Value NEXTHOP_IF ([A-Z][\w\-\.:/]+)
Value UPTIME (\d[\w:\.]+)

Start
  ^Gateway.* -> Routes

Routes
  # For "is (variably )subnetted" line, capture mask, clear all values.
  ^\s+\d{1,3}.\d{1,3}.\d{1,3}.\d{1,3}\/${MASK}\sis -> Clear
  #
  # Match directly connected route with explicit mask
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK}\/${MASK}\sis\sdirectly\sconnected,\s${NEXTHOP_IF} -> Record
  #
  # Match directly connected route (mask is inherited from "is subnetted")
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK}\sis\sdirectly\sconnected,\s${NEXTHOP_IF} -> Record
  #
  # Match regular routes, with mask, where all data in same line
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK}\/${MASK}\s\[${DISTANCE}/${METRIC}\]\svia\s${NEXTHOP_IP}(,\s${UPTIME})?(,\s${NEXTHOP_IF})? -> Record
  #
  # Match regular route, all one line, where mask is learned from "is subnetted" line
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK}\s\[${DISTANCE}\/${METRIC}\]\svia\s${NEXTHOP_IP}(,\s${UPTIME})?(,\s${NEXTHOP_IF})? -> Record
  #
  # Match route with no via statement (Null via protocol)
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK}\/${MASK}\s\[${DISTANCE}/${METRIC}\],\s${UPTIME},\s${NEXTHOP_IF} -> Record
  #
  # Match "is a summary" routes (often Null0)
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK}\/${MASK}\sis\sa\ssummary,\s${UPTIME},\s${NEXTHOP_IF} -> Record
  #
  # Match regular routes where the network/mask is on the line above the rest of the route
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK}\/${MASK} -> Next
  #
  # Match regular routes where the network only (mask from subnetted line) is on the line above the rest of the route
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK} -> Next
  #
  # Match the rest of the route information on line below network (and possibly mask)
  ^\s+\[${DISTANCE}\/${METRIC}\]\svia\s${NEXTHOP_IP}(,\s${UPTIME})?(,\s${NEXTHOP_IF})? -> Record
  #
  # Match load-balanced routes
  ^\s+\[${DISTANCE}\/${METRIC}\]\svia\s${NEXTHOP_IP} -> Record
  #
  # Clear all variables on empty lines
  ^\s* -> Clearall

EOF
SAMPLE COMMAND OUTPUT
route_output = net_conn.send_command("show ip route vrf xxx y.y.y.y", use_textfsm=True)
SUMMARY

When using textfsm for to show the ip route with a hostname, I get different results with IOS vs NXOS.

With IOS, it return a string. With NXOS, it returns a list of dictionaries, as I would expect.

FYI... I'm using Netmiko and not sure if it's related to that module vs using textFSM independently.

STEPS TO REPRODUCE

route_output = net_conn.send_command("show ip route vrf xxx y.y.y.y", use_textfsm=True)

EXPECTED RESULTS

NXOS - returning a list of dictionaries
[{'protocol': 'ospf-800',
'type': 'intra',
'network': '10.25.176.0',
'mask': '24',
'distance': '110',
'metric': '2',
'nexthop_ip': '10.1.12.29',
'nexthop_if': 'Vlan1806',
'uptime': '11w1d',
'nexthop_vrf': '',
'tag': '',
'segid': '',
'tunnelid': '',
'encap': ''},
{'protocol': 'ospf-800',
'type': 'intra',
'network': '10.25.176.0',
'mask': '24',
'distance': '110',
'metric': '2',
'nexthop_ip': '10.1.24.29',
'nexthop_if': 'Vlan1871',
'uptime': '11w1d',
'nexthop_vrf': '',
'tag': '',
'segid': '',
'tunnelid': '',
'encap': ''}]

ACTUAL RESULTS


IOS - returning a string

'Routing entry for 10.25.0.0/16\n  Known via "ospf 100", distance 110, metric 29, type inter area\n  Last update from 10.1.64.5 on Vlan1298, 7w0d ago\n  Routing Descriptor Blocks:\n  * 10.1.64.5, from 10.1.77.2, 7w0d ago, via Vlan1298\n      Route metric is 29, traffic share count is 1'


python3 support

ISSUE TYPE
  • Bug Report
  • Feature Idea
  • Template Creation Help
  • Documentation Report
TEMPLATE USING

SAMPLE COMMAND OUTPUT

SUMMARY

Can this be used with python 3?

STEPS TO REPRODUCE
EXPECTED RESULTS
ACTUAL RESULTS

cisco_xr_show_interfaces.template line 4 regex incorrect

ISSUE TYPE
  • Bug Report
TEMPLATE USING
cisco_xr_show_interfaces.template

Line in regex that is incorrect
 ^\s+Internet\s+Address\s+is\s+${IP_ADDRESS}
SAMPLE COMMAND OUTPUT
TenGigE0/0/2/3 is up, line protocol is up 
  Interface state transitions: 1
  Hardware is TenGigE, address is e0ac.f121.3733 (bia e0ac.f121.3733)
  Layer 1 Transport Mode is LAN
  Description: TEST DESCRIPTION
  Internet address is 172.16.1.0/31
  MTU 9178 bytes, BW 10000000 Kbit (Max: 10000000 Kbit)
     reliability 255/255, txload 0/255, rxload 2/255
  Encapsulation ARPA,
  Full-duplex, 10000Mb/s, link type is force-up
  output flow control is on, input flow control is on
  loopback not set,
  ARP type ARPA, ARP timeout 04:00:00
  Last input 00:00:00, output 00:00:00
  Last clearing of "show interface" counters never
  30 second input rate 107543000 bits/sec, 14399 packets/sec
  30 second output rate 21008000 bits/sec, 11364 packets/sec
     153451697561 packets input, 132611285629421 bytes, 4 total input drops
     0 drops for unrecognized upper-level protocol
     Received 1 broadcast packets, 61346651 multicast packets
              1 runts, 0 giants, 0 throttles, 0 parity
     8 input errors, 3 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
     121503394577 packets output, 30543269332397 bytes, 0 total output drops
     Output 1 broadcast packets, 60855096 multicast packets
     0 output errors, 0 underruns, 0 applique, 0 resets
     0 output buffer failures, 0 output buffers swapped out
     1 carrier transitions
SUMMARY

The current regex for Value IP_ADDRESS tries to match address with a capital A. In the below line

Internet address is 172.16.1.0/31

I have checked XR verison 4.x, 5.x and 6.x. All versions currently use address with lowercase a.

STEPS TO REPRODUCE
Using the current template produces no results.
EXPECTED RESULTS

Changing the regex to instead look for a lowercase will fix this issue. example below.

Current
^\s+Internet\s+Address\s+is\s+${IP_ADDRESS}
Purposed
^\s+Internet\s+address\s+is\s+${IP_ADDRESS}

ACTUAL RESULTS
With the current version the IP_ADDRESS value does not match. Since this line doesn't match the template does not match an entries and you end not getting any information.

New template cisco_ios_show_snmp_user.template

ISSUE TYPE
  • Feature Idea
TEMPLATE USING
Value Required USER_NAME (\w+)
Value ENGINE_ID (\w+)
Value STORAGE_TYPE (\w+)
Value STORAGE_TYPE_ACTIVE (\w+)
Value AUTHENTICATION_PROTOCOL (\w+)
Value PRIVACY_PROTOCOL (\w+)
Value GROUP_NAME (\w+)

Start
  ^User\s+name:\s+${USER_NAME}$$
  ^Engine\s+ID:\s+${ENGINE_ID}$$
  ^storage-type:\s${STORAGE_TYPE}\s+${STORAGE_TYPE_ACTIVE}$$
  ^Authentication\s+Protocol:\s+${AUTHENTICATION_PROTOCOL}$$
  ^Privacy\s+Protocol:\s+${PRIVACY_PROTOCOL}$$
  ^Group-name:\s+${GROUP_NAME}$$ -> Record
SAMPLE COMMAND OUTPUT
TESTSW#show snmp user 

User name: user_snmp1
Engine ID: 80000009030000451DEC1085
storage-type: nonvolatile        active
Authentication Protocol: SHA
Privacy Protocol: AES128
Group-name: managerpriv

User name: user_snmp2
Engine ID: 80000009030000451DEC1085
storage-type: nonvolatile        active
Authentication Protocol: SHA
Privacy Protocol: AES128
Group-name: managerpriv
SUMMARY
STEPS TO REPRODUCE
- name: Read snmp users
  ios_command:
    commands:
      - show snmp user
  register: res_snmpuser
  changed_when: false

- set_fact:
    snmp_users: "{{ res_snmpuser.stdout[0] | parse_cli_textfsm(textfsm_template_dir ~ '/cisco_ios_show_snmp_user.template') }}"
  changed_when: false
  delegate_to: localhost

- debug:
    msg: "{{ snmp_users | to_nice_yaml() }}"
  delegate_to: localhost
  changed_when: false
  tags: [print_action]
EXPECTED RESULTS
ACTUAL RESULTS
    -   AUTHENTICATION_PROTOCOL: SHA
        ENGINE_ID: 80000009030000451DEC1085
        GROUP_NAME: managerpriv
        PRIVACY_PROTOCOL: AES128
        STORAGE_TYPE: nonvolatile
        STORAGE_TYPE_ACTIVE: active
        USER_NAME: user_snmp1
    -   AUTHENTICATION_PROTOCOL: SHA
        ENGINE_ID: 80000009030000451DEC1085
        GROUP_NAME: managerpriv
        PRIVACY_PROTOCOL: AES128
        STORAGE_TYPE: nonvolatile
        STORAGE_TYPE_ACTIVE: active
        USER_NAME: user_snmp2

hp_procurve_show_vlans.template empty output

The HP Procurve Show Vlans template regex is unable to handle the addition of the pipe separator used for separating the Name and Status colums (example below) which results in null returned. The following change to the regex resolves this issue (adding \S+\s+ to capture and ignore the pipe and white space):

Line 11:
^\s+${VLAN_ID}\s+${NAME}\s+\S+\s+${STATUS}\s+${VOICE}\s+${JUMBO} -> Record

Original Line 11:
^\s+${VLAN_ID}\s+${NAME}\s+${STATUS}\s+${VOICE}\s+${JUMBO} -> Record

  VLAN ID Name                             | Status     Voice Jumbo
  ------- -------------------------------- + ---------- ----- -----
  1       DEFAULT_VLAN                     | Port-based No    No  


Problem with parsing ASA ACL

ISSUE TYPE
  • Bug Report
TEMPLATE USING
cisco_asa_show_access-list.template
SAMPLE COMMAND OUTPUT
extfsm.TextFSMError: Error: "Did not match any rules". Rule Line: 68. Input Line: access-list out40-if line 14 extended permit icmp any4 any4 time-exceeded log informational interval 300 (hitcnt=3085438) 0x19b0643c .


SUMMARY

I have wite python script with netmiko module

STEPS TO REPRODUCE

import netmiko
import warnings
import sys

# main function
if __name__ == '__main__':
     
     warnings.simplefilter("ignore", DeprecationWarning)
     sys.path.append('d:\\appl\\Reports')
     from devices_info import device_asa
     
     address="9.148.2.23"

     connection=netmiko.ConnectHandler( ip = address,
                                        device_type="cisco_asa",
                                        username = device_asa["username"],
                                        password = device_asa["password"],
                                        secret = device_asa["password"]
                                        )

     result = connection.find_prompt()
    
     
     result = connection.send_command("show access-list out40-if", use_textfsm=True)
     print(result)
     connection.disconnect()

Original access list:

access-list out40-if remark NT00004C12;************ Firewall Filter block Private IP address**************
access-list out40-if extended deny ip any 192.168.0.0 255.255.0.0
access-list out40-if extended deny ip any 127.0.0.0 255.0.0.0
access-list out40-if extended deny ip any 172.16.0.0 255.240.0.0
access-list out40-if extended deny ip any host 255.255.255.255
access-list out40-if extended deny ip any host 0.0.0.0
access-list out40-if extended deny ip 192.168.0.0 255.255.0.0 any
access-list out40-if extended deny ip 127.0.0.0 255.0.0.0 any
access-list out40-if extended deny ip 10.0.0.0 255.0.0.0 any
access-list out40-if extended deny ip 172.16.0.0 255.240.0.0 any
access-list out40-if extended deny ip host 255.255.255.255 any
access-list out40-if extended deny ip host 0.0.0.0 any
access-list out40-if remark NT00004C16;************ Allow ICMP *************
access-list out40-if extended permit icmp any4 any4 time-exceeded log
access-list out40-if extended permit icmp any4 any4 unreachable log
access-list out40-if extended permit icmp any4 any4 echo log
access-list out40-if extended permit icmp any4 any4 echo-reply log
access-list out40-if extended permit icmp any4 9.148.0.0 255.255.0.0 echo
access-list out40-if extended permit icmp any4 9.148.0.0 255.255.0.0 echo-reply
access-list out40-if extended permit icmp any4 9.148.0.0 255.255.0.0 unreachable
access-list out40-if extended permit icmp any4 9.148.0.0 255.255.0.0 time-exceeded
access-list out40-if extended permit icmp any4 9.147.0.0 255.255.0.0 echo-reply
access-list out40-if extended permit icmp any4 9.147.0.0 255.255.0.0 echo
access-list out40-if extended permit icmp any4 9.147.0.0 255.255.0.0 unreachable
access-list out40-if extended permit icmp any4 9.151.0.0 255.255.0.0 echo-reply
access-list out40-if extended permit icmp any4 9.147.0.0 255.255.0.0 time-exceeded
access-list out40-if extended permit icmp any4 9.151.0.0 255.255.0.0 echo
access-list out40-if extended permit icmp any4 9.151.0.0 255.255.0.0 unreachable
access-list out40-if extended permit icmp any4 9.151.0.0 255.255.0.0 time-exceeded
access-list out40-if extended deny icmp any any
access-list out40-if remark NT00004C0E; ************ Firewall Appl Filter block NetBios and SMTP **************
access-list out40-if extended deny udp any any eq snmp
access-list out40-if extended deny tcp any any eq 445
access-list out40-if extended deny tcp any any eq netbios-ssn
access-list out40-if extended deny tcp any any eq 135
access-list out40-if remark ************ Deny all ********************
access-list out40-if extended deny ip any any
EXPECTED RESULTS
ACTUAL RESULTS
sers\pergamen\PycharmProjects\Network\venv\Scripts\python.exe D:/appl/appl/Networkaccess/ssh/netmiko/Cisco-ASA--netmiko-showver.py
Traceback (most recent call last):
  File "D:/appl/appl/Networkaccess/ssh/netmiko/Cisco-ASA--netmiko-showver.py", line 32, in <module>
    result = connection.send_command("show access-list out40-if", use_textfsm=True)
  File "C:\Users\pergamen\PycharmProjects\Network\venv\lib\site-packages\netmiko\cisco\cisco_asa_ssh.py", line 60, in send_command
    output = super(CiscoAsaSSH, self).send_command(*args, **kwargs)
  File "C:\Users\pergamen\PycharmProjects\Network\venv\lib\site-packages\netmiko\base_connection.py", line 1194, in send_command
    command=command_string.strip())
  File "C:\Users\pergamen\PycharmProjects\Network\venv\lib\site-packages\netmiko\utilities.py", line 239, in get_structured_data
    textfsm_obj.ParseCmd(raw_output, attrs)
  File "C:\Users\pergamen\PycharmProjects\Network\venv\lib\site-packages\netmiko\_textfsm\_clitable.py", line 261, in ParseCmd
    self.table = self._ParseCmdItem(self.raw, template_file=template_files[0])
  File "C:\Users\pergamen\PycharmProjects\Network\venv\lib\site-packages\netmiko\_textfsm\_clitable.py", line 291, in _ParseCmdItem
    for record in fsm.ParseText(cmd_input):
  File "C:\Users\pergamen\PycharmProjects\Network\venv\lib\site-packages\textfsm.py", line 885, in ParseText
    self._CheckLine(line)
  File "C:\Users\pergamen\PycharmProjects\Network\venv\lib\site-packages\textfsm.py", line 908, in _CheckLine
    if self._Operations(rule, line):
  File "C:\Users\pergamen\PycharmProjects\Network\venv\lib\site-packages\textfsm.py", line 986, in _Operations
    % (rule.new_state, rule.line_num, line))
textfsm.TextFSMError: Error: "Did not match any rules". Rule Line: 68. Input Line: access-list out40-if line 14 extended permit icmp any4 any4 time-exceeded log informational interval 300 (hitcnt=3085438) 0x19b0643c .

Process finished with exit code 1

cisco_wlc_ssh update name to cisco_wlc?

ISSUE TYPE
  • Feature Idea
TEMPLATE USING
cisco_wlc_ssh*
SAMPLE COMMAND OUTPUT

SUMMARY

Other systems are jumping in and working in conjunction with NTC templates. Specifically Netmiko integration in this issue. The name for wireless is typically cisco_wlc in Netmiko, which then does not find an NTC template in the home directory. As a work around the device_type of cisco_wlc_ssh does work, but seems a little out of the ordinary to use with Netmiko since it is SSH by using it.

Would like to remove the _ssh suffix on the cisco_wlc_ssh names to assist with this. Are there other non-ssh templates for this?

Cisco ASA - Missing capture of Software Compile Date

ISSUE TYPE
  • Bug Report
TEMPLATE USING

cisco_asa_show_version.template

Value VERSION (\S+)
Value DEVICE_MGR_VERSION (\S+)
Value IMAGE (\S+)
Value HOSTNAME (\S+)
Value UPTIME (.+)
Value HARDWARE (.+)
Value MODEL (\S+)
Value FLASH (\S+)
Value List INTERFACES (\S+)
Value LICENSE_MODE (.+)
Value LICENSE_STATE (.+)
Value MAX_INTF (\d+)
Value MAX_VLANS (\d+)
Value FAILOVER (\S+)
Value CLUSTER (\S+)
Value SERIAL (\S+)
Value LAST_MOD (.+)

Start
  ^.*Software\sVersion\s${VERSION}
  ^Device.+\s${DEVICE_MGR_VERSION}
  ^System image file.+"${IMAGE}"
  ^${HOSTNAME} up ${UPTIME}
  ^Hardware:\s+${HARDWARE},
  ^Model Id:\s+${MODEL}
  ^Internal.+Flash,\s${FLASH}
  ^ \d+:.\S+\s${INTERFACES}.*
  ^License mode:\s${LICENSE_MODE}
  ^.+License State:\s${LICENSE_STATE}
  ^Maximum Physical.+:\s${MAX_INTF}
  ^Maximum VLANs.+:\s${MAX_VLANS}
  ^Failover\s+:\s${FAILOVER}
  ^Cluster\s+:\s${CLUSTER}
  ^Serial Number:\s${SERIAL}
  ^.+last modified by\s${LAST_MOD}
SAMPLE COMMAND OUTPUT

Cisco Adaptive Security Appliance Software Version 9.8(3)21 <context>
Firepower Extensible Operating System Version 2.4(1.103)
Device Manager Version 7.8(2)

Compiled on Tue 07-Aug-18 23:18 PDT by builders

fw002 up 114 days 18 hours
failover cluster up 700 days 16 hours

Hardware:   FPR4K-SM-12

License mode: Smart Licensing

Licensed features for this user context:
Failover                          : Active/Active  
Encryption-DES                    : Enabled        
Encryption-3DES-AES               : Enabled        
Carrier                           : Disabled       
AnyConnect Premium Peers          : 0              
Other VPN Peers                   : 500            
AnyConnect for Mobile             : Enabled        
AnyConnect for Cisco VPN Phone    : Enabled        
Advanced Endpoint Assessment      : Enabled        
Cluster                           : Enabled        
              

Failover cluster licensed features for this user context:
Failover                          : Active/Active  
Encryption-DES                    : Enabled        
Encryption-3DES-AES               : Enabled        
Carrier                           : Disabled       
AnyConnect Premium Peers          : 0              
Other VPN Peers                   : 500            
AnyConnect for Mobile             : Enabled        
AnyConnect for Cisco VPN Phone    : Enabled        
Advanced Endpoint Assessment      : Enabled        
Cluster                           : Enabled        

Configuration last modified by thatperson at 09:15:45.959 EST Mon Dec 12 2018
SUMMARY

One thing that will be helpful is the ability to capture the Software Compile date, this is a better way to judge the age of the code rather than looking specifically at the code version. Code version alone doesn't quite give you how old it is.

STEPS TO REPRODUCE

Just a new capture.

EXPECTED RESULTS

Proposing adding the following to a PR coming soon.

Value COMPILE_DATE (\d+-\w+-\d+)

^Compiled on \w+\s+{COMPILE_DATE}.*

Cisco ASA show route template error

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value Filldown PROTOCOL (C|S|R|B|D|O|i|L)
Value Filldown TYPE (\w{0,2})
Value Required,Filldown NETWORK (\d+\.\d+\.\d+\.\d+|\S+)
Value Filldown MASK (\d+\.\d+\.\d+\.\d+)
Value DISTANCE (\d+)
Value METRIC (\d+)
Value NEXTHOPIP (\d+\.\d+\.\d+\.\d+)
Value NEXTHOPIF (\S+)
Value UPTIME (\d+:\d+:\d+)

Start
  ^Gateway -> ROUTES

ROUTES
  # Match regular routes with all data in same line
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK}\s+${MASK}\s\[${DISTANCE}\/${METRIC}\]\svia\s${NEXTHOPIP}(,\s${UPTIME}){0,1}(,\s${NEXTHOPIF}){0,1} -> Record
  #
  # Clear all non Filldown variables when line started with network that is variably subnetted
  ^\s+[0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3}.[0-9]{1,3}${MASK} -> Clear
  ^${PROTOCOL}(\s|\*)${TYPE}\s+${NETWORK}\s\[${DISTANCE}\/${METRIC}\]\svia\s${NEXTHOPIP}(,\s${UPTIME}){0,1}(,\s${NEXTHOPIF}){0,1} -> Record
  #
  # Match load-balanced routes
  ^\s+\[${DISTANCE}\/${METRIC}\]\s+via\s+${NEXTHOPIP},\s+${NEXTHOPIF} -> Record
  #
  # Match directly connected routes
  ^${PROTOCOL}\s${TYPE}\s+${NETWORK}\sis\sdirectly\sconnected,\s${NEXTHOPIF} -> Record
  ^${PROTOCOL}(\*){0,1}\s${TYPE}\s+${NETWORK}\s+${MASK}\sis\sdirectly\sconnected,\s${NEXTHOPIF} -> Record
  #
  # Clear all variables on empty lines
  ^\s* -> Clearall
  #^${TYPE} -> Continue.Record
  #^${TYPE}\s+${NETWORK}\s+${MASK}\s+\[\d+\/\d+\]\s+via\s+${GATEWAY}\,\s+${INTFC}\s* -> Record
  #^\s+\[\d+\/\d+\]\s+via\s+${GATEWAY}\,\s+${INTFC} -> Record

EOF
SAMPLE COMMAND OUTPUT
Routing Table: BUSINESS
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2, V - VPN
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, + - replicated route
Gateway of last resort is 10.200.0.2 to network 0.0.0.0

D EX     10.118.64.0 255.255.255.0 [170/3840] via 10.200.0.2, 2w2d, TRUST
                                 [170/3840] via 10.200.0.1, 2w2d, TRUST
SUMMARY

The UPTIME variable is not correctly placed in the template, and is causing uptime to populate into nexthopif, and uptime to be blank.

STEPS TO REPRODUCE
from netmiko import Netmiko

params = {
    'ip': 'testdevice',
    'device_type': 'cisco_asa',
    'username': 'testuser',
    'password': 'testpass',
    'secret': 'testpass'
}

device = Netmiko(**params)

routes = device.send_command('show route', use_textfsm=True)

print(routes)

EXPECTED RESULTS
{
            "protocol": "D",
            "type": "EX",
            "network": "10.118.64.0",
            "mask": "255.255.255.0",
            "distance": "170",
            "metric": "3840",
            "nexthopip": "10.200.0.1",
            "nexthopif": "TRUST",
            "uptime": "3w1d",
        }
ACTUAL RESULTS
{
            "protocol": "D",
            "type": "EX",
            "network": "10.118.64.0",
            "mask": "255.255.255.0",
            "distance": "170",
            "metric": "3840",
            "nexthopip": "10.200.0.1",
            "nexthopif": "3w1d",
            "uptime": "",
        }

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.