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

Added Cisco IOS show ap cdp neighbors template #1555

Merged

Conversation

TheTeapot418
Copy link
Contributor

ISSUE TYPE
  • New Template Pull Request
COMPONENT

New template : cisco_ios_show_ap_cdp_neighbors

SUMMARY

I found myself having to write this template while doing some automation with a Cisco IOS-XE Catalyst 9800 WLC and thought it would be worth sharing.

@TheTeapot418 TheTeapot418 marked this pull request as ready for review October 30, 2023 21:45
@jvanderaa jvanderaa merged commit 83df6ec into networktocode:master Nov 3, 2023
16 checks passed
@jvanderaa
Copy link
Contributor

Thanks @TheTeapot418

mjbear pushed a commit to mjbear/ntc-templates that referenced this pull request Jan 7, 2024
* Added Cisco IOS show ap cdp neighbors template
@bitboy85
Copy link

Based on this, i expanded it to work with older aireos wlc.

Value AP_NAME (\S+)
Value AP_IP ([a-fA-F0-9:\.]+)
Value NEIGHBOR_NAME (\S+)
Value NEIGHBOR_IP ([a-fA-F0-9:\.]+)
Value NEIGHBOR_PORT ([a-zA-Z0-9\/\.]+)

Start
  ^[a-zA-Z]+\s[a-z]+\s[a-zA-z]+:\s\d+$$
  ^AP\sName\s+AP\sIP\s+Neighbor\sName\s+Neighbor\sIP\s+Neighbor\sPort\s*$$
  ^AP\sName\s+AP\sIP\s+Neighbor\sName\s+Neighbor\sPort\s*$$
  ^-+\s*$$
  ^[- ]+\s*$$
  ^${AP_NAME}\s+${AP_IP}\s+${NEIGHBOR_NAME}\s+${NEIGHBOR_IP}\s+${NEIGHBOR_PORT}\s*$$ -> Record
  ^${AP_NAME}\s+${AP_IP}\s+${NEIGHBOR_NAME}\s+${NEIGHBOR_PORT}\s*
  ^\s+IP\saddress:\s${NEIGHBOR_IP}\s*$$ -> Record
  ^\s*$$
  ^. -> Error

Sample (yes, neighbor ip is in the next line)

AP Name             AP IP                                     Neighbor Name       Neighbor Port
------------------  ----------------------------------------  ------------------  --------------
AP1234.5678           10.10.10.10                            neighborDevice  GigabitEthernet1/0/1
                                                                                                                  IP address: 10.20.20.20

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

Successfully merging this pull request may close these issues.

3 participants