Python SSH script to extract Cisco switches information in preparation for network migration
I have a list of Cisco Nexus5548 IP addresses and FQDNs. I need help with a Python script to SSH to each and extract the following in order to import it into an Excel column format: IP Name Port Number Port Description Port Type Vlans Optic Type Medium Type 172.x.x.x hqcr1-swx-x E1/x The actual port description (Access or Trunk) 300-305,2276,… 1g-sr, 10g-sr, 1g-glct (copper fiber, or twinax) This is what I have so far: import paramiko, getpass, time devices = {'device1': {'ip': 'xx.xx.xx.xx'}} 'device2': {'ip': 'xx.xx.xx.xx'}} commands = ['show version\n', 'show run\n'] username = input('Usern
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.