As of IOS 12.4(23)T you no longer need to rely on a “reload in” command to save you from potentially locking yourself out of a remotely managed router.
You can enter configure mode with “config terminal revert time x” and IOS will save the running configuration to a backup file on flash to revert to after x minutes.
When your changes are successful and you want to cancel the revert you simply exit configuration mode and feed the router “config confirm” to commit your changes persistently. Though obviously you will still need to write your running configuration to NVRAM as per usual!
What is the advantage of this? Well for one you don’t have to wait for the router to reload to get access again and secondly any other services this router is providing eg Voice gateway, transcoding etc will be unaffected.
Lets take a look at how this behaves on the CLI:
Enable Configuration archiving
Router(config)#archive Router(config-archive)#path flash:backups Router(config-archive)#maximum 14 Router(config-archive)#exit Router(config)#exit |
Enter Configure mode with a reversion timer
Router#conf terminal revert timer 2
Rollback Confirmed Change: Backing up current running config to flash:backups-0 Enter configuration commands, one per line. End with CNTL/Z. *Apr 11 02:38:30.5711: %ARCHIVE_DIFF-5-ROLLBK_CNFMD_CHG_START_ABSTIMER: User: console: Scheduled to rollback to config flash:backups-0 in 2 minutes |
Make a configuration change
Router(config)#host Router(config)#hostname RevertMe RevertMe(config)# |
Take note of reversion warnings
*Apr 11 02:39:30.571: %ARCHIVE_DIFF-5-ROLLBK_CNFMD_CHG_WARNING_ABSTIMER: System will rollback to config flash:backups-0 in one minute. Enter “configure confirm” if you wish to keep what you’ve configured |
Reversion takes place
Rollback Confirmed Change: rolling to:flash:backups-0
Total number of passes: 1 *Apr 11 02:40:30.571: %ARCHIVE_DIFF-5-ROLLBK_CNFMD_CHG_ROLLBACK_START: Start rolling to: flash:backups-0 Router(config)# |
Alternatively Commit your changes
Router(config)#hostname RevertMe RevertMe(config)#exit *Apr 11 02:46:08.615: %SYS-5-CONFIG_I: Configured from console by consoleonf RevertMe#configure confirm *Apr 11 02:46:10.899: %ARCHIVE_DIFF-5-ROLLBK_CNFMD_CHG_CONFIRM: User: console: Confirm the configuration change RevertMe#copy running-config startup-config Building configuration… [OK] RevertMe# |