cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1033
Views
0
Helpful
3
Replies

Suppress output in show CDp neighbors

vmiller
Level 7
Level 7

     show cdp neighbor fastethernet1
     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
    ASMxxxx1.xxxxxx.net
                                          Fas 1                134             R S I     WS-C4948E Gig 1/42

 

Anyone have a hack that might supress the .xxxxxx.net piece of the device id in show cdp neighbors ?

it would make some reporting we are trying to do just a bit easier

 

 

thanks

1 Accepted Solution

Accepted Solutions

thiland
Level 3
Level 3

Since you asked for a hack, you could:

  • Ensure you've generated your SSH RSA keys
  • Remove the "ip domain name xxxxxxx.net" command
  • Now it's gone from CDP

 

If you ever need to generate a new SSH key you'll have to add the domain-name back in.

Alternately, depending on how you're doing your reporting, use EEM or the WSMA API to extract just the data you need.

View solution in original post

3 Replies 3

thiland
Level 3
Level 3

Since you asked for a hack, you could:

  • Ensure you've generated your SSH RSA keys
  • Remove the "ip domain name xxxxxxx.net" command
  • Now it's gone from CDP

 

If you ever need to generate a new SSH key you'll have to add the domain-name back in.

Alternately, depending on how you're doing your reporting, use EEM or the WSMA API to extract just the data you need.

Sadly, solution 1 would be career limiting.

the reporting tool is a hand built script. I'll do some more digging on what we might have available.

 

thanks for the prompt response.

This can be done.  I've got an EEM script, authored by Joe Clarke, which strips out the domain and populate relevant information into the interface description.  

 

I am still reading the documentation but you might want to look at Cisco Secure CDP.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Innovations in Cisco Full Stack Observability - A new webinar from Cisco