Router boot process, configuration register and password recovery
Sign in to read this lesson
Besides RAM, NVRAM and flash, a router has ROM, which holds POST, the bootstrap code and ROMMON. At boot, POST checks the hardware, the bootstrap finds IOS in flash (or on TFTP) and loads it into RAM, then the startup-config is copied from NVRAM to the running-config; if there is none, setup starts. The configuration register and boot system commands are used when looking for IOS. The default configuration register is 0x2102. For password recovery you enter confreg 0x2142 in ROMMON: the router boots ignoring the startup-config, you change the password, set the register back to 0x2102 and save.
What you will learn
- Memories: ROM (POST, bootstrap, ROMMON), flash (IOS image), NVRAM (startup-config), RAM (running IOS and running-config).
- Boot: POST → bootstrap → locate IOS and load it into RAM (flash or TFTP) → startup-config → running-config (otherwise setup) → CLI.
- IOS lookup: configuration register →
boot systemcommands → the first IOS in flash → TFTP → ROMMON. To pick an image:boot system flash0:<file>. - The configuration register is 0x2102 by default (IOS from flash, configuration from NVRAM). 0x2142 ignores the startup-config: it is for password recovery. Verify with
show version. - Password recovery: Ctrl+Break →
confreg 0x2142in ROMMON →reset→copy startup-config running-config→ new password →config-register 0x2102→copy running-config startup-config.
The lesson has 5 key points, an explanation and 5 questions. It opens with a package.