Script to backup Cisco switches via telnet / tftp
Viewed 1,037 time(s) |
Add this post to Your Favorite Posts | Print This Post
| A couple of days ago, I have released a small perl script to back up Cisco IOS based switches via telnet.
I know there are a couple of similar scripts available on the internet, but most of them either use the “expect” functionality (which does not work all the time), or use SendKeys (which only works when the application has the ‘focus’, and thus cannot be safely scripted.), or are commercial tools.
So I decided to write a quick and dirty (free) script myself, which is purely based on a basic tcp socket connection.
I know, this script only works with telnet (clear text), but at least you can backup your switches (and if you have a dedicated management network, it may be ok to use telnet after all). Furthermore, you can safely schedule the script to run in the background, lean back, and enjoy other things …
The script will simply connect to each host in a given text file, log in, and send the configuration + the vlan configuration to a remote tftp server.
You can read more about this script (and download the script / a precompiled binary) at http://www.corelan.be:8800/index.php/my-free-tools/networking/cisco-switch-backup-utility/
© 2009, Peter Van Eeckhoutte. All rights reserved. Terms of Use are applicable to all content on this blog. If you want to use/reuse parts of the content on this blog, you must provide a link to the original content on this blog.
