ROM Monitor Overview

ROM Monitor

A ROM Monitor is a bootstrap program that

  • initializes the hardware and boots the Cisco IOS XE software when you power on or reload a router

  • displays the ROM Monitor (rommon 1>) prompt when you connect a terminal to the router in ROM Monitor mode, and

  • operates as a separate program from the Cisco IOS XE software for special circumstances such as reinstalling software, resetting passwords, or specifying startup configuration files.

The ROM Monitor software is known by many names. It is sometimes called ROMMON because of the CLI prompt in ROM Monitor mode. The ROM Monitor software is also called the boot software, boot image, or boot helper.

ROM Monitor operation and configuration

During normal operation, users do not use ROM Monitor mode. ROM Monitor mode is used only in special circumstances, such as reinstalling the entire software set, resetting the router password, or specifying a configuration file to use at startup.

Although it is distributed with routers that use the Cisco IOS XE software, ROM Monitor is a separate program from the Cisco IOS XE software. During normal startup, the ROM Monitor initializes the router, and then control passes to the Cisco IOS XE software. After the Cisco IOS XE software takes over, the ROM Monitor is no longer in use.

Two primary connections exist between ROM Monitor and the Cisco IOS XE software: the ROM Monitor environment variables and the configuration register.

The ROM Monitor environment variables define the location of the Cisco IOS XE software and describe how to load it. After the ROM Monitor has initialized the router, it uses the environment variables to locate and load the Cisco IOS XE software.

The configuration register is a software setting that controls how a router starts up. One of the primary uses of the configuration register is to control whether the router starts in ROM Monitor mode or Administration EXEC mode. The configuration register is set in either ROM Monitor mode or Administration EXEC mode as needed. Typically, you set the configuration register using the Cisco IOS XE software prompt when you need to use ROM Monitor mode. When the maintenance in ROM Monitor mode is complete, you change the configuration register so the router reboots with the Cisco IOS XE software.

When the router is in ROM Monitor mode, you can access the ROM Monitor software only from a terminal connected directly to the console port of the card. Because the Cisco IOS XE software (EXEC mode) is not operating, nonmanagement interfaces are not accessible. Basically, all Cisco IOS XE software resources are unavailable. The hardware is available, but no configuration exists to make use of the hardware.

It is important to remember that ROM Monitor mode is a router mode, not a mode within the Cisco IOS XE software. It is best to remember that ROM Monitor software and the Cisco IOS XE software are two separate programs that run on the same router. At any given time, the router runs only one of these programs.

One area that can be confusing when using ROM Monitor and the Cisco IOS XE software is the area that defines the IP configuration for the Management Ethernet interface. Most users are comfortable with configuring the Management Ethernet interface in the Cisco IOS XE software. When the router is in ROM Monitor mode, however, the router does not run the Cisco IOS XE software, so that Management Ethernet interface configuration is not available.

When you want to access other devices, such as a TFTP server, while in ROM Monitor mode on the router, you must configure the ROM Monitor variables with IP access information.


Note


TFTP access variables are currently not supported on the IR8340 platform.

Access ROM Monitor mode

This reference provides the necessary steps to enter ROM Monitor (ROMMON) mode on your device.

Check the Current ROMMON Version

Perform this task to determine the current ROMmon version and review configured variables for troubleshooting, compatibility verification, or system maintenance.

ROMmon (ROM Monitor) is the bootstrap program that initializes the router hardware and loads the Cisco IOS software.

Before you begin

The device must be powered on and you must have access to the CLI in either privileged EXEC mode or ROMmon mode.

Follow these steps to check the ROMmon version and variables:

Procedure


Step 1

Use the show rom-monitor slot command to display the current ROMmon version.

Example:

Router# show rom-monitor r0
==========================================================

System Bootstrap, Version v0.33, DEVELOPMENT SOFTWARE
Copyright (c) 1994-2021 by cisco Systems, Inc.
Compiled Mon Jul 12 18:53:57 2021 by gilchen

Step 2

Use the show romvar command to display all configured ROMmon variables in privileged EXEC mode.

Example:

Router# show romvar
ROMMON variables:
PS1 = rommon ! >
DEVICE_MANAGED_MODE = autonomous
CRYPTO_BI_THPUT = 50000
TEMPLATE = advanced
DISABLE_USB_FLASH = no
DISABLE_CC_AUTH = 1
DISABLE_SD_FLASH = no
PASSWD_RECOVERY = no
ENABLE_BREAK = no
ENABLE_FLASH_PRIMARY_BOOT = no
BAUD = 9600
LICENSE_BOOT_LEVEL =
SKIP_CHIPGUARD = 1
RET_2_RTS =
BOOT = flash:ir8340-universalk9.BLD_POLARIS_DEV_LATEST_20210322_153228.SSA.bin,12;
BSI = 0
RET_2_RCALTS =
RANDOM_NUM = 404654831

If the configuration register is set to 0x0 or 0x1820, a reload operation brings the router to the ROMmon mode prompt (rommon 1>).

Step 3

Alternatively, if the router is in ROMmon mode, use the set command to display the variables.

Example:

rommon 2 > set
BOOT=flash:ir8340-universalk9.BLD_POLARIS_DEV_LATEST_20210710_191629_V17_7_0_60.SSA.bin,12;
BSI=0
CRYPTO_BI_THPUT=50000
DEVICE_MANAGED_MODE=autonomous
LICENSE_BOOT_LEVEL=
PS1=rommon ! >
RANDOM_NUM=1822515242
RET_2_RCALTS=1630484680
RET_2_RTS=
SKIP_CHIPGUARD=1
TEMPLATE=advanced
rommon 3 >

The output provides comprehensive system bootstrap details, including the software version and environmental variables used during the boot process.

ROM Monitor commands

The following table summarizes the commands commonly used in ROM Monitor. For specific instructions on using these commands, refer to the relevant procedure in this document.

Table 1. Commonly Used ROM Monitor Commands

ROMMON Command

Description

boot image

Manually boots a Cisco IOS XE software image.

boot image –o config-file-path

Manually boots the Cisco IOS XE software with a temporary alternative administration configuration file.

confreg

Changes the config-register setting.

dev

Displays the available local storage devices.

dir

Displays the files on a storage device.

reset

Resets the node.

set

Displays the currently set ROM Monitor environmental settings.

sync

Saves the new ROM Monitor environmental settings.

unset

Removes an environmental variable setting.

Examples

The example displays what appears when you enter the ? command on a router:

rommon 3 >?
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
alias set and/or display command aliases
boot boot up an external process
cpuinfo display processor information
confreg configuration register utility
ctchallenge Generate a challenge for dev key install
ctinstkey Parse the response and install dev key
ctiskeyinstalled checks if devkey installed and display it
ctremkey Remove the devkey from Aikido
ctrespsave Store parts of incoming response
dev display the device table
dir list files in a file system
efi_shell launch the UEFI SHELL enviroment
flwr burn new BIOS onto the bootrom
help monitor built-in command(s) help
history display monitor command history
meminfo display main memory information
repeat repeat a monitor command
reset system reset
set display the monitor environment
showmon display currently selected ROM monitor
sync write monitor environment to NVRAM
token display board's unique token identifier
unalias unset an alias
unset unset a variable from the monitor environment
rommon 4 >

Change the ROM Monitor prompt

Changing the prompt is useful if you are working with multiple routers in ROM Monitor at the same time.

Follow these steps to change the ROM Monitor prompt:

Procedure


Use the PS1= command to specify a custom prompt format.

Example:

rommon 4 >PS1="IR8340 rommon ! >"
IR8340 rommon 5 >

This example specifies that the prompt should be "IR8340 rommon ", followed by the line number, and then followed by " > " by the line number.


Display the Configuration Register Setting

Use this task to verify the current configuration register setting and display the current environment variable settings.

Before you begin

The router must be in ROMmon mode to perform this task.

Procedure


Use the showmon command without parameters to display the system bootstrap information and configuration register.

Example:

IR8340 rommon 8 >showmon

System Bootstrap, Version v0.33, DEVELOPMENT SOFTWARE
Copyright (c) 1994-2021 by cisco Systems, Inc.
Compiled Mon Jul 12 18:53:57 2021 by root


!!! DEBUG SECURE-BOOT CPLD Version Installed. For INTERNAL USE ONLY !!!

Current image running : Boot ROM0

Last reset cause (0x00000002): LocalSoft
IR8340-K9 platform with 8388608 Kbytes of main memory

IR8340 rommon 9 >

The configuration register setting is typically labeled as Virtual Configuration Register in the output. You can use the no command if you need to exit a prompt without changing the configuration register settings.


Environment variable settings

Environment variable settings are ROM Monitor configuration parameters that:

  • define the attributes of the ROM Monitor,

  • are entered like commands and are always followed by the equal sign (=), and

  • use capital letters for the variable name, followed by a definition.

Environment variable characteristics

Under normal operating conditions, you do not need to modify these variables. They are cleared or set only when you need to make changes to the way ROM Monitor operates.

Environment variable settings are entered in capital letters, followed by a definition. For example:


IP_ADDRESS=10.0.0.2

Frequently used environmental variables

The following table shows the main ROM Monitor environmental variables. For instructions on how to use these variables, see the relevant instructions in this document. The IR8340 boot loader does not support netboot, so any setting like environment variables IP_ADDRESS, IP_SUBNET_MASK, DEFAULT_GATEWAY, TFTP_SERVER, TFTP_FILE are not used.

Table 2. Frequently Used ROM Monitor Environmental Variables

Environmental variable

Description

BOOT= path/file

Identifies the boot software for a node. This variable is usually set automatically when the router boots.

Display environment variable settings

Procedure


Enter the showmon command to display the current environment variable settings.

Example:

IR8340 rommon 8 >showmon


System Bootstrap, Version v0.33, DEVELOPMENT SOFTWARE
Copyright (c) 1994-2021 by cisco Systems, Inc.
Compiled Mon Jul 12 18:53:57 2021 by root


!!! DEBUG SECURE-BOOT CPLD Version Installed. For INTERNAL USE ONLY !!!

Current image running : Boot ROM0

Last reset cause (0x00000002): LocalSoft
IR8340-K9 platform with 8388608 Kbytes of main memory

IR8340 rommon 9 >

Environment variable settings

Environment variable settings are configuration parameters that:

  • are entered in capital letters followed by a definition,

  • control system boot behavior and hardware configurations, and

  • are configured in ROMmon mode.

The following example shows the environmental variables that can be configured in ROMmon mode:

rommon 1 > confreg 0x0
rommon 1> BOOT_WDOG = DISABLE
rommon 1> BOOT = IR8340-K9_image_name

Save Environment Variable settings

Use this task to save environment variable settings to ensure that your current configuration is preserved and will not be lost when the system is reset or booted.

Environment variables that are not explicitly saved are temporary and will be discarded whenever the system undergoes a reset or boot cycle.

Before you begin

The router must be in ROMmon mode to perform this task.

Procedure


Use the sync command to save the current environment variable settings.

Example:

rommon > sync

Environmental values that are not saved with the sync command are discarded whenever the system is reset or booted.


The current environment variable settings are now saved and will persist through system resets and boots.

Exit ROM Monitor Mode

Use this this task to return the router to normal operational mode from the ROMmon prompt.

To exit ROM Monitor mode, you must change the configuration register to a valid boot value and then reset the router.

Before you begin

The router must be in ROMmon mode (indicated by the rommon > prompt).

Procedure


Step 1

Use the confreg command to initiate the configuration register configuration prompts.

Example:

rommon 1> confreg

Respond to each prompt as instructed by the system to set the desired boot behavior.

Step 2

Use the reset command to reset and initialize the router.

Example:

rommon 2> reset

The router will reboot and attempt to load the Cisco IOS software image based on the new configuration register settings.


Configuration example

This example demonstrates the interactive configuration process using the confreg command in ROM Monitor mode, showing the configuration summary and available options for modifying system boot characteristics.


rommon 3 > confreg 
           Configuration Summary
   (Virtual Configuration Register: 0x0)
enabled are:
 [ 0 ] break/abort has effect
 [ 1 ] console baud: 9600
 boot: ...... the ROM Monitor
do you wish to change the configuration? y/n  [n]:  y
 enable  "diagnostic mode"? y/n  [n]:  
 enable  "use net in IP bcast address"? y/n  [n]:  
 enable  "load rom after netboot fails"? y/n  [n]:  
 enable  "use all zero broadcast"? y/n  [n]:  
 disable "break/abort has effect"? y/n  [n]:  
 enable  "ignore system config info"? y/n  [n]:  
 change console baud rate? y/n  [n]:  
change the boot characteristics? y/n  [n]:  
           Configuration Summary
   (Virtual Configuration Register: 0x0)
enabled are:
 [ 0 ] break/abort has effect
 [ 1 ] console baud: 9600
 boot: ...... the ROM Monitor
do you wish to change the configuration? y/n  [n]:  

Upgrade the ROMmon for a Router

Use this task to ensure the latest ROMmon version is installed and operational on the IR8340-K9 router.

ROMmon upgrades on the IR8340-K9 router are performed automatically when the image is booted because the latest ROMmon version is bundled with the Cisco IOS XE image. An internal algorithm detects if the current running version is older than the bundled version; if it is, the system upgrades it automatically. If the versions are equal, no upgrade is executed. After a successful upgrade, the router reboots automatically to load and execute the new version.

Before you begin

Ensure the desired Cisco IOS XE image is available on the router's storage.

Procedure


Step 1

(Optional) Use the show rom-monitor slot command to view the current ROMmon release numbers on the hardware.

Example:

Router# show rom-monitor r0

Step 2

If autoboot is not enabled, use the boot filesystem:/file-location command at the ROMmon prompt to boot the Cisco IOS XE image.

Example:

rommon 1> boot flash:ir8340-universalk9.bin

The ROMmon upgrade is not permanent until the Cisco IOS XE image is successfully booted. If the configuration register is not set to 0x2102, manual booting is required.

Step 3

After the boot is complete, use the enable command to enter privileged EXEC mode.

Example:

Router> enable

Step 4

Use the show rom-monitor slot command to verify that the ROMmon has been upgraded to the expected version.

Example:

Router# show rom-monitor r0