Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cisco_nxos_show_vlan does not show ports, thank god cisco_ios_show_vlan works #601

Closed
JoeyG1973 opened this issue Feb 24, 2020 · 2 comments · Fixed by #604
Closed

cisco_nxos_show_vlan does not show ports, thank god cisco_ios_show_vlan works #601

JoeyG1973 opened this issue Feb 24, 2020 · 2 comments · Fixed by #604

Comments

@JoeyG1973
Copy link
Contributor

JoeyG1973 commented Feb 24, 2020

ISSUE TYPE
  • Bug Report
TEMPLATE USING
Value VLAN_ID (\d+)
Value NAME (\S+)
Value STATUS (\S+)

Start
  ^\d+\s+enet\s+CE
  ^${VLAN_ID}\s+${NAME}\s+${STATUS} -> Record
SAMPLE COMMAND OUTPUT
'\nVLAN Name                             Status    Ports\n---- -------------------------------- --------- -------------------------------\n1    default                          active    Po1, Eth1/53, Eth1/54\n\nVLAN Type         Vlan-mode\n---- -----        ----------\n1    enet         CE     \n\nRemote SPAN VLANs\n-------------------------------------------------------------------------------\n\nPrimary  Secondary  Type             Ports\n-------  ---------  ---------------  -------------------------------------------\n\n\n\n'
SUMMARY

show vlan on nxos is not listing interfaces when parsed with platform cisco_nxos. platform cisco_ios appears to work as expected

STEPS TO REPRODUCE
>>> vlans = '\nVLAN Name                             Status    Ports\n---- -------------------------------- --------- -------------------------------\n1    default                          active    Po1, Eth1/53, Eth1/54\n\nVLAN Type         Vlan-mode\n---- -----        ----------\n1    enet         CE     \n\nRemote SPAN VLANs\n-------------------------------------------------------------------------------\n\nPrimary  Secondary  Type             Ports\n-------  ---------  ---------------  -------------------------------------------\n\n\n\n'
>>> parse_output(platform="cisco_nxos", command="show vlan", data=vlans)
[{'vlan_id': '1', 'name': 'default', 'status': 'active'}]

EXPECTED RESULTS

I expected to get the same results when using platform cisco_ios.

[{'vlan_id': '1', 'name': 'default', 'status': 'active', 'interfaces': ['Po1', 'Eth1/53', 'Eth1/54']}]
ACTUAL RESULTS
[{'vlan_id': '1', 'name': 'default', 'status': 'active'}]
@FragmentedPacket
Copy link
Contributor

@JoeyG1973 This should be fixed with #604. Do you mind testing?

@JoeyG1973
Copy link
Contributor Author

I was just about to dig in and fix this myself... let me grab the code and check it out

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants