Working with Cisco Routers and Switches with Python

I’ve updated the pyMultiChange.py script. It now is fully functional, with the addition of enable mode functionality. With this script, you can take a list of routers and switches from a text file and execute a series of commands, from a text file, all from SSH. For example:

Here is the usage output, if you don’t select the required arguments:

Here is the usage output, without verbose / debugging mode:

Here is the usage output, with verbose / debugging mode:

 

Finally, here is the code:

I’m going to continue working on building out the pyRouterLib module, as there is so much functionality that could be added to that. I’ll keep you updated on the progress. As always, updates will be posted to my github.

July 27, 2014

Posted In: Cisco Administration Python Scripting, Miscellaneous Hacking, Python Tips, System Administration