CCNA online course

Cisco Device Boot Sequence: Routers and Switches

Learn how Cisco routers and switches start: POST, bootstrap, IOS loading, configuration register behavior, startup-config, running-config, and boot troubleshooting.

The Cisco boot sequence is the ordered process a router or switch follows after power is applied. The device initializes hardware, starts its low-level firmware, finds and loads Cisco IOS, and then loads the saved configuration.

Understanding these stages helps with initial deployment, password recovery, IOS image recovery, software upgrades, and fault isolation. It also helps you determine whether a failure involves hardware, the operating system, or configuration data.

What the Boot Sequence Must Accomplish

Startup can be divided into three broad functions:

  1. Hardware initialization: Power is applied and diagnostics verify that essential hardware can operate.
  2. Operating-system loading: Firmware and a boot loader locate an IOS image and place it into RAM.
  3. Configuration loading: IOS reads the saved startup configuration and applies it as the running configuration.

A device can succeed at one stage and fail at another. For example, a router may pass POST and load IOS successfully but start without its expected interfaces or passwords because the startup configuration is missing or bypassed.

Memory and Storage Roles

Cisco devices use several memory areas. Exact hardware designs vary, especially between router and switch families, but the following roles are useful for CCNA-level troubleshooting.

Memory or Storage TypeVolatileTypical ContentsRole During Boot
ROM or boot ROMNoPOST, bootstrap functions, and recovery firmwareStarts hardware diagnostics and begins the boot process
Flash memoryNoIOS image files and other device filesCommon source for the IOS image
NVRAMNoTraditionally, the startup configurationProvides the saved configuration during normal startup
RAM or DRAMYesRunning IOS, processes, tables, buffers, and running configurationWorking memory used after IOS starts
Configuration registerNo, as a boot-control settingA hexadecimal startup-control value on applicable routersInfluences image loading and startup-configuration behavior

Important distinction: Flash and NVRAM retain data when power is removed. RAM does not. A change made only to the running configuration is lost after a reload unless it is copied to startup-config.

Standard Cisco Router Boot Sequence

  1. Power is applied. The device begins hardware initialization.
  2. POST runs. Power-On Self-Test checks critical components such as the CPU, memory, and interfaces. LEDs and console messages may report the progress or a failure.
  3. Bootstrap code starts. Firmware in ROM initializes enough of the device to begin finding an operating-system image.
  4. Boot instructions are evaluated. The device uses configured boot system statements, boot variables, or the platform's default image-search behavior.
  5. An IOS image is located. Flash is the normal source, although supported platforms may use another local source or a network-based recovery method.
  6. IOS is loaded into RAM. A compressed image may be decompressed as part of loading. IOS then initializes its processes and hardware interfaces.
  7. Startup configuration is read. IOS locates the saved configuration, traditionally in NVRAM, and copies it into RAM as the running configuration.
  8. The CLI becomes available. The administrator receives an IOS prompt. If no usable startup configuration exists, the device may offer setup mode or start with default settings.
StageWhat HappensPrimary Storage or ComponentExpected ResultFailure Outcome
Power-onElectrical power reaches the deviceHardwareStartup beginsNo lights, console output, or operation
POSTCritical hardware is testedROM firmware and hardwareDiagnostics passBoot interruption, error messages, or fault LEDs
BootstrapLow-level startup code takes controlROM or boot ROMBoot process continuesBoot loader or ROMMON prompt
Image discoveryBoot targets and local storage are checkedFlash and boot settingsA usable IOS image is selectedRepeated search, invalid-file errors, or recovery mode
IOS loadingThe image is decompressed when necessary and placed in RAMFlash and RAMIOS startsMemory, integrity, or compatibility error
Configuration loadingSaved configuration is copied into RAMNVRAM or platform-equivalent storageRunning configuration is populatedSetup mode, default prompt, or unconfigured device
CLI readinessIOS presents the command-line interfaceRAMAdministrator can operate the deviceLimited recovery environment or repeated reboot

POST and Hardware Diagnostics

POST means Power-On Self-Test. It is an early diagnostic process performed after power is applied and before normal IOS operation. POST checks enough of the CPU, memory, interfaces, and other critical components to determine whether startup can continue.

A failed diagnostic can stop the boot sequence before IOS is available. Use a console connection to capture messages, and observe status LEDs when console output is unavailable or incomplete. A hardware failure should not be treated as an IOS or configuration problem until POST results have been considered.

Bootstrap, Boot Loader, and ROMMON

Bootstrap code is low-level startup firmware. Its job is to initialize the device sufficiently to locate and start the network operating system.

A boot loader is a low-level environment that can locate an IOS image, select a boot target, inspect storage, and perform recovery tasks. On many routers, the recovery environment is called ROMMON, short for ROM Monitor.

Normal booting transfers control from the bootstrap or boot loader to IOS. Recovery booting stops in the boot loader or ROMMON instead, usually because no usable image can be loaded or because a boot setting explicitly requests recovery behavior. From that environment, a technician may inspect flash, select another image, or use a supported recovery-transfer method.

IOS Image Discovery and Loading

Flash is the normal location for a Cisco IOS image. The device may use one or more configured boot system statements, a platform boot variable, or a default search sequence. Boot settings can contain a filename and a storage location such as flash:.

At a conceptual level, an IOS image can be stored in compressed form to reduce storage requirements. During startup, the device may decompress it while loading it into RAM. The image must be valid for the platform and compatible with available flash and RAM.

Fallback behavior depends on the platform and software release. A device may try another configured local image, search another supported local location, use network-based image retrieval when it is supported and configured, or enter ROMMON when no image can be loaded.

Router-Oriented Boot Configuration

configure terminal
boot system flash:<ios-image-filename>
end
copy running-config startup-config

Use the exact filename shown by dir flash: or show flash:. Confirm platform compatibility before changing a boot target.

Configuration Register and Boot Modes

The configuration register is a hexadecimal boot-control value used especially on Cisco routers. Its fields influence how the device loads IOS and whether it reads the startup configuration.

ValueTypical UseStartup-Config BehaviorBoot ResultAdministrative Caution
0x2102Normal operationReads the saved configurationNormal IOS boot and configuration loadingCommon normal setting; verify the value on the specific platform
0x2142Password-recovery workflowBypasses the saved configuration during startupIOS can start without applying the saved passwords and settingsUse only with authorization, then restore normal behavior
Boot field set for ROMMON entryRecovery or diagnostic startupConfiguration behavior depends on the remaining register fieldsDevice enters ROMMON instead of normal IOS bootDo not change boot fields permanently without a recovery plan

The exact interpretation of register fields is platform-dependent, but the CCNA-level distinction is important: normal boot behavior uses a value such as 0x2102, while 0x2142 is commonly used to bypass startup-config during an authorized password-recovery process. Verify both the active and next-reload values before making permanent changes.

Setting Normal Router Behavior

configure terminal
config-register 0x2102
end
copy running-config startup-config
reload

The changed register value normally takes effect after a reload. A reload interrupts service, so confirm the maintenance plan and console or remote-access path first.

Temporarily Bypassing Startup Configuration

configure terminal
config-register 0x2142
end
reload

This setting causes an applicable router to start without applying startup-config. After the authorized recovery work, restore the normal register value, merge or restore the intended configuration, save it, and reload if required.

Startup-Config and Running-Config

startup-config is the saved configuration read during a normal boot. running-config is the active configuration currently held in RAM and used by IOS.

During normal initialization, IOS copies startup-config into RAM and uses it as running-config. If startup-config is absent, erased, unreadable, or intentionally bypassed, IOS can still load while the expected configuration does not. Interfaces, routing protocols, local accounts, and management settings may therefore be absent.

show startup-config
show running-config

Compare the two outputs when diagnosing unexpected startup behavior. To preserve intentional running-configuration changes, save them with copy running-config startup-config.

Setup Mode and First-Time Startup

When IOS loads successfully but no usable startup configuration is found, the device may display an initial configuration dialog, commonly called setup mode. It asks a series of questions to create a basic configuration.

Administrators commonly decline the dialog and configure the device deliberately from the CLI. This gives better control over naming, passwords, interfaces, management access, routing, and saved configuration. Setup behavior can vary by platform and IOS release, so the exact prompts are not universal.

Cisco Switch Boot Sequence

A switch follows the same broad logical order: POST, boot loader execution, IOS image selection, IOS startup, and configuration loading. The difference is that switch families may use platform-specific boot loaders, image variables, package files, or install-mode mechanisms.

Do not assume every Catalyst family uses identical commands or file formats. Some platforms boot a single image directly, while others use package files and an install procedure that establishes the boot target. The conceptual sequence remains the same, but storage conventions, boot variables, recovery commands, and image-management steps differ.

Boot FunctionRouter TreatmentSwitch TreatmentPlatform-Specific Notes
Hardware diagnosticsPOST checks critical router hardwarePOST checks critical switch hardwareConsole messages and LEDs vary
Low-level startupBootstrap and boot loader start image discoveryPlatform boot loader starts image discoveryNames and available commands differ
Image selectionboot system statements and local flash are commonBoot variables, image variables, or package settings may be usedInspect the platform's active boot settings
IOS loadingImage loads into RAM and startsImage or package set starts according to platform modeBundle and install modes are not interchangeable
Configuration loadingSaved configuration is appliedSaved configuration is appliedStorage implementation may differ from classic NVRAM

Boot Sequence Verification

Use show commands on an operational device to establish what should happen at the next reload and what happened during the current startup.

show version
show boot
dir flash:
show flash:
show running-config | include boot
show startup-config
show running-config
  • show version identifies the running IOS image and commonly displays the configuration-register setting.
  • show boot displays boot variables or boot targets on many platforms.
  • dir flash: and show flash: list files so you can verify that the expected image exists.
  • show running-config | include boot reveals configured boot system statements where applicable.
  • show startup-config confirms whether a saved configuration is available.
  • Console output during reload can confirm the selected image, decompression, configuration loading, and any recovery prompt.

Exact command output varies by platform and IOS release. Record the current image, boot target, flash contents, startup configuration status, and register value before making changes.

Practical Examples

Example: Normal Router Startup

Power is applied, POST verifies the hardware, and ROM bootstrap code begins image discovery. A configured boot instruction points to an IOS image in flash. The image is loaded and decompressed into RAM. IOS then reads startup-config from NVRAM and applies it as running-config. After initialization, the administrator receives the IOS CLI prompt with the saved hostname, interfaces, passwords, and other settings.

Example: First Boot With No Saved Configuration

A router passes POST and loads IOS, but startup-config does not exist. IOS may offer the initial configuration dialog. The administrator can decline setup mode and use the CLI, then save the completed configuration as startup-config.

Example: Password-Recovery Preparation

On an applicable router, an authorized technician uses config-register 0x2142 and reloads. IOS starts without applying startup-config, allowing recovery work without immediately enforcing the saved credentials. Afterward, the technician restores the normal value, typically 0x2102, and saves the configuration.

Example: Missing IOS Image

If flash contains no valid compatible image, the device may stop at a boot loader or ROMMON prompt. The decision process is to inspect storage, verify boot instructions, obtain or restore a supported image using an available recovery method, and return the device to normal boot behavior.

Example: Incorrect Boot Target

A boot instruction may reference a filename that was removed or changed during an upgrade. Compare the configured filename with the actual output of dir flash:. Correct the boot instruction to reference a valid compatible image and save the configuration.

Common Boot Failures and Recovery Concepts

SymptomLikely CauseVerification MethodRecovery Direction
Device stops at ROMMON or boot loader promptNo usable image, invalid boot target, recovery boot setting, corrupt or unsupported imageInspect storage, boot variables, boot system statements, register, and image compatibilityCorrect the target or restore a valid supported image, then return to normal boot settings
IOS loads but expected configuration is absentMissing or unsaved startup-config, bypass register setting, or unreadable saved storageCompare startup and running configurations; inspect the register and console messagesRestore or create the intended startup-config and set normal startup behavior
Device repeatedly requests a nonexistent fileStale boot system statement or incorrect boot variableCompare configured filenames with the flash directoryUpdate the boot instruction to a valid image and save it
Upgrade prevents normal bootIncomplete copy, incompatible image, insufficient resources, or missing install-mode procedureVerify image integrity, platform support, storage, RAM, and package settingsUse a supported image and the correct platform-specific installation procedure
No useful early console output or hardware fault LEDsPower, console, or hardware/POST problemCheck cabling, power, console settings, LEDs, and POST messagesResolve the physical or hardware issue before IOS troubleshooting

Console access is foundational for boot troubleshooting because network access may not exist before IOS and its configuration have loaded. Recovery commands and transfer methods differ by platform, so use the device-specific procedure and preserve a known-good image whenever possible.

Router-versus-Switch Troubleshooting Rules

  • The logical stages are comparable, but commands are not universally interchangeable.
  • Router configuration-register behavior, including 0x2102 and 0x2142, is primarily discussed for applicable router platforms.
  • Switches may use boot variables, package files, or install-mode settings instead of classic router-style boot system commands.
  • Storage names, image formats, package requirements, and recovery environments vary by platform and release.
  • Always identify the exact hardware family and software mode before applying a recovery or upgrade command.

Exam-Relevant Notes

  • POST is an early hardware diagnostic, not the IOS loading step.
  • Bootstrap and boot loader code start the process of finding an IOS image; IOS is the network operating system.
  • Flash commonly stores IOS images, NVRAM traditionally stores startup-config, and RAM stores running IOS and running-config.
  • Normal startup copies startup-config into RAM as running-config.
  • 0x2102 is the common normal router configuration-register value; 0x2142 bypasses startup-config for password recovery on applicable routers.
  • A device can load IOS successfully and still operate without its intended configuration.
  • A ROMMON prompt generally indicates that normal IOS booting did not complete or that recovery behavior was selected.