As I write this, we’re going through another “snow event”, with a forecast of high winds and 10-20 inches of snow to top the 24-36 inches that fell a few days ago – over 67 inches so far this year, which has broken all snowfall records for Maryland.
One of the network operations team sent out an email this morning asking if there was a way to save the configs on all the devices in the network as a safety step to avoid losing an unsaved config if or when power goes out at a site. I took a quick look at NetMRI, which has an analysis issue specifically for this case. It captures the SNMP timestamp for the time that the configuration was last changed and the time that the configuration was last saved. It creates an issue when a device’s configuration timestamp is later than the timestamp of the last save.
Sure enough, there were five devices with configurations that had not been saved, so it was easy to take care of the problem without hitting all network devices with a ‘write mem’ command. Even easier, NetMRI has a way to run a command on the set of devices in the issue. All it took was to select all the devices in the issue, then click on the button to execute a command on them, and specify ‘write mem’ as the command to be executed. I didn’t use ‘copy run start’ because it requests a confirmation of the operation, requiring another command line input to fully execute. Executing the save operation on all five devices only took a minute to setup and run.
While executing the save operation on five devices wouldn’t take very long using a manual process, it wouldn’t take many more devices before the time savings would become significant, especially as you track which devices you’ve done and which ones remain to be done. For more complex sets of commands, variables may be needed to be used in the commands to be executed. My point is that the simple command execution approach doesn’t always work. Sometimes you need a scripting language that allows you to determine the value of variables to include, such as an interface name or an IP address. A script may need to collect and process data from the current config in order to create the new set of commands to run on the device. This is what can be done with NetMRI that I’ve not seen in many other configuration products.
Re-posted with Permission
NetCraftsmen would like to acknowledge Infoblox for their permission to re-post this article which originally appeared in the Applied Infrastructure blog under http://www.infoblox.com/en/communities/blogs.html