Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/masoud-maghsoudi/python-cisco-switch-interfaces-descriptions
python script to automate adding description to access switch ports based on computer name retrieved from active directory DNS server
https://github.com/masoud-maghsoudi/python-cisco-switch-interfaces-descriptions
cisco netmiko python yaml-configuration
Last synced: 25 days ago
JSON representation
python script to automate adding description to access switch ports based on computer name retrieved from active directory DNS server
- Host: GitHub
- URL: https://github.com/masoud-maghsoudi/python-cisco-switch-interfaces-descriptions
- Owner: masoud-maghsoudi
- License: mit
- Created: 2023-07-07T06:30:05.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-10-04T12:05:05.000Z (over 1 year ago)
- Last Synced: 2023-10-04T20:34:12.667Z (over 1 year ago)
- Topics: cisco, netmiko, python, yaml-configuration
- Language: Python
- Homepage:
- Size: 9.77 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# About Script
## Aim
We want to automate the description setting on Cisco access switch user interfaces throughout the network.
## Mechanism:
This script is written in Python using [netmiko](https://github.com/ktbyers/netmiko) and [dnspython](https://github.com/rthalley/dnspython). Using specified **VLANs** for access users and the **switch** IP addresses in [configuration file](./config.yml) it filters out user interfaces and resolves the active IP address on the port via ARP cache of the corresponding **router** specified in the same configuration file and queries an IP reveres lookup from **Local DNS server** declared in configuration file. after formatting the resolved name it will be set on corresponding switch interface.
For disabled interfaces, we set _Disabled by Admin_ description.
For ports with more than active 1 MAC address, in the case that it has no description we set _Multi User_ description, otherwise we would not change the interface description, but list them all in a report file.## License
MIT
## Author Information
| Author | Masoud Maghsoudi |
| ------ | ------------------------------------- |
| Email | |
| Github | |