The next one is 0x2120, which will boot into ROMMON mode. The device will boot normally when that is the setting. The first is 0x2102, and it is the default. There are several different configuration registers that you can use, probably the three most useful. You can use the ‘config-register’ command in global configuration mode, or if you’re at the ROMMON prompt to where the router or a switch hasn’t completed booting yet, you can use the ‘confreg’ command.įor example, we could use ‘config-register 0x2142’ for that setting at global config or ‘confreg 0x2142’ if we were at the ROMMON prompt. It is used to change the way that the router boots from the default.
#Factory reset cisco switch password#
That is how you do a factory reset on your router or your switch.įor password recovery, first, you need to know about the configuration register. If I ‘reload’ now and confirm that, it will take a minute to do the reload, and when it comes back up, I can see it’s running the Setup Wizard because it’s got no configuration.
If I now do a ‘show start’, it will tell me that my startup-config is not present. It will then tell you that this is going to erase the NVRAM file system, which you know is where the startup-config is saved. Now, if I wanted to factory reset this device, the command is ‘write erase’. It’s pretty embarrassing, but it’s a way that you can get back on to that router or that switch again. It’s not good because it does cause an outage. You can ask some in the office to pull the power out and put the power back in. What this is useful for is if you lose connectivity to a device that you’re working on remotely, you can’t get to it anymore. I would lose my unsaved changes, and it would still have the hostname R1. If I rebooted now, it would come back up with a startup-config. I didn’t do the ‘copy run start’ yet, so that’s still ‘hostname R1’ there.
If I do a ‘show startup-config’, you’ll see I haven’t saved it yet. If I break back down to the enable prompt and do a ‘show run’, the hostname is R2. So what I’ll do here is I go to global configuration, and I’ll say ‘hostname R2’, and I’m not doing a ‘copy run start’ yet. If I do a ‘show startup config’, the hostname is also R1 in the startup-config, so that has been saved. If I do a ‘show running-config’, you can see the hostname is R1. There is no startup-config, therefore, the Setup Wizard will run.įor example, we have router R1. Then, reload the device, and it will boot up with a blank configuration. To do a factory reset, we use the ‘write erase’ command at the enable prompt.