How to Use the ROM Monitor—Typical Tasks
This section provides the following procedures:
Note This section does not describe how to perform all possible ROM monitor tasks. Use the command help to list and perform any tasks that are not described in this document. See the “Displaying Commands and Command Syntax in ROM Monitor Mode (?, help, -?)” section.
Entering ROM Monitor Mode
This section provides two ways to enter ROM monitor mode:
Prerequisites
Connect a terminal or PC to the router console port. For help, see the hardware installation guide for your router.
Using the Break Key Sequence to Interrupt the System Reload and Enter ROM Monitor Mode
This section describes how to enter ROM monitor mode by reloading the router and entering the Break key sequence.
Note Bit 8 controls the console Break key (see Table 1):
- Setting bit 8 (Factory default) causes the processor to ignore the console Break key.
- Clearing bit 8 causes the processor to interpret Break as a command to force the router into the ROM monitor mode, halting normal operation.
Break can always be sent in the first 60 seconds while the router is rebooting, regardless of the configuration register settings.
SUMMARY STEPS
1. enable
2. reload
3. Press Ctrl - Break.
DETAILED STEPS
|
|
|
Step 1 |
enable
Router> enable |
Enables privileged EXEC mode.
- Enter your password if prompted.
|
Step 2 |
reload
Router# reload |
Reloads the operating system. |
Step 3 |
Immediately press Ctrl - Break.
Router# send break |
Interrupts the router reload and enters ROM monitor mode.
|
Examples
This section provides an example of the reload command:
Sample Output for the reload Command
Use break key sequence to enter rom monitor
Proceed with reload? [confirm]
*Sep 23 15:54:25.871: %SYS-5-RELOAD: Reload requested by console. Reload Reason: Reload command.
Note Clearing bit 8 causes the processor to interpret Break as a command to force the router into the ROM monitor mode, halting normal operation.
*** System received an abort due to Break Key ***
signal= 0x3, code= 0x0, context= 0x431aaf40
PC = 0x4008b5dc, Cause = 0x20, Status Reg = 0x3400c102
What to Do Next
– Enter the i or reset command, which restarts the booting process and loads the system image.
– Enter the cont command to continue the booting process and load the system image.
Setting the Configuration Register to Boot to ROM Monitor Mode
This section describes how to enter ROM monitor mode by setting the configuration register to boot to ROM monitor mode at the next system reload or power-cycle. For more information about the configuration register, see Changing the Configuration Register Settings.
Caution
Do not set the configuration register using the
config-register
0x0 command after you have set the baud rate. To set the configuration register without affecting the baud rate, use the current configuration register setting by entering the show ver | inc configuration command, and then replacing the last (rightmost) number with a 0 in the configuration register command.
SUMMARY STEPS
1. enable
2. configure terminal
3. config-register 0x0
4. exit
5. write memory
6. reload
DETAILED STEPS
|
|
|
Step 1 |
enable
Router> enable |
Enables privileged EXEC mode.
- Enter your password if prompted.
|
Step 2 |
configure terminal
Router# configure terminal |
Enters global configuration mode. |
Step 3 |
config-register 0x0
Router(config)# config-register 0x0 |
Changes the configuration register settings.
- The 0x0 setting forces the router to boot to the ROM monitor at the next system reload.
|
Step 4 |
exit
Router(config)# exit |
Exits global configuration mode. |
Step 5 |
write memory
Router# write memory |
Sets to boot the system image from flash memory. |
Step 6 |
reload
Router# reload <output deleted> rommon 1> |
Reloads the operating system.
- Because of the 0x0 configuration register setting, the router boots to ROM monitor mode.
|
Examples
The following example shows how to set the configuration register to boot to ROM monitor mode:
Router# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)# config-register 0x0
*Sep 23 16:01:24.351: %SYS-5-CONFIG_I: Configured from console by console
Building configuration...
Proceed with reload? [confirm]
*Sep 23 16:01:41.571: %SYS-5-RELOAD: Reload requested by console. Reload Reason: Reload command.
System Bootstrap, Version 12.4(13r)T, RELEASE SOFTWARE (fc1)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 2006 by cisco Systems, Inc.
Initializing memory for ECC
Router platform with 262144 Kbytes of main memory
Main memory is configured to 64 bit mode with ECC enabled
Readonly ROMMON initialized
Displaying Commands and Command Syntax in ROM Monitor Mode (?, help, -?)
This section describes how to display ROM monitor commands and command syntax options.
SUMMARY STEPS
1. ?
or
help
2. command -?
DETAILED STEPS
|
|
|
Step 1 |
? or help
rommon 1 > ?
rommon 1 > help |
Displays a summary of all available ROM monitor commands. |
Step 2 |
command -?
rommon 16 > display -? |
Displays syntax information for a ROM monitor command. |
Examples
This section shows the help command example:
alias set and display aliases command
boot boot up an external process
break set/show/clear the breakpoint
confreg configuration register utility
cont continue executing a downloaded image
context display the context of a loaded image
cookie display contents of motherboard cookie PROM in hex
dev list the device table
dir list files in file system
frame print out a selected stack frame
help monitor builtin command help
history monitor command history
iomemset set IO memory percent
meminfo main memory information
repeat repeat a monitor command
rommon-pref Select ROMMON
set display the monitor variables
showmon display currently selected ROM monitor
stack produce a stack trace
sync write monitor environment to NVRAM
sysret print out info from last system return
tftpdnld tftp image download
unset unset a monitor variable
hwpart Read HW resources partition
Displaying Files in a File System (dir)
To display a list of the files and directories in the file system, use the dir command, as shown in the following examples. You might need to enter the reset command before viewing the flash memory directory.
System Bootstrap, Version 12.4(20100226:194457) [petechiu-v150rm7 138], DEVELOPMENT SOFTWARE Copyright (c) 1994-2010 by cisco Systems, Inc.
Total memory size = 1024 MB
Field Upgradeable ROMMON Integrity test _______________________________________
ROM: Digitally Signed Development Software
CGR-2010/K9 platform with 1048576 Kbytes of main memory Main memory is configured to 72 bit mode with ECC enabled
Upgrade ROMMON initialized
program load complete, entry point: 0x80803000, size: 0x1b340
2 47089944 -rw- cgr2010-universalk9-mz.SPA.151-1.T
rommon 5 > dir usbflash1:
program load complete, entry point: 0x80903000, size: 0x4c440
dir: cannot open device "usbflash1:"
Loading a System Image (boot)
This section describes how to load a system image using the boot ROM monitor command.
Prerequisites
Determine the filename and location of the system image that you want to load. Two images can be downloaded for Cisco CGR 2010: cgr2010-universalk9-mz.SPA.151-1.T and cgr2010-universalnovpnk9-mpe-mz.SPA.151-1.T.
SUMMARY STEPS
1. boot
or
boot flash: [ filename ]
or
boot filename tftpserver
or
boot [ filename ]
or
boot usbflash: [ filename ]
DETAILED STEPS
|
|
|
Step 1 |
boot or boot flash: [ filename ] or boot filename tftpserver or boot [ filename ] or boot usbflash :[ filename ]
ROMMON > boot
ROMMON > boot flash:
ROMMON > boot someimage 172.16.30.40
ROMMON > boot someimage
ROMMON > boot usbflash0:someimage |
In the following order, the examples here direct the router to:
- Boot the first image in flash memory.
- Boot the first image or a specified image in flash memory.
Note In IOS, flash0 will alias onto flash. But Rommon does not support aliasing. So, the boot system command should always use flash0:.
- Boot the specified image over the network from the specified TFTP server (hostname or IP address).
- Boot from the boothelper image because it does not recognize the device ID. This form of the command is used to boot a specified image from a network (TFTP) server.
- Boot the image stored on the USB flash device.
Note Platforms can boot from USB in ROM monitor with or without a compact flash device. It is not necessary to use a bootloader image from the compact flash device. Partitions, such as usbflash0:2:image_name, are not supported on USB flash drives. The boot usbflash<x>: command will boot the first file on the device, if it is a valid image. You can override the default boothelper image setting by setting the BOOTLDR Monitor environment variable to point to another image. Any system image can be used for this purpose.
- Options for the boot command are -x (load image but do not execute) and -v (verbose).
|
Examples
The following example shows how to load boot flash memory and the resulting command text output:
Please reset before booting
System Bootstrap, Version 12.4(20100226:194457) [petechiu-v150rm7 138], DEVELOPMENT SOFTWARE Copyright (c) 1994-2010 by cisco Systems, Inc.
Total memory size = 1024 MB
Field Upgradeable ROMMON Integrity test _______________________________________
ROM: Digitally Signed Development Software
CGR-2010/K9 platform with 1048576 Kbytes of main memory Main memory is configured to 72 bit mode with ECC enabled
Upgrade ROMMON initialized
program load complete, entry point: 0x80803000, size: 0x1b340
program load complete, entry point: 0x80803000, size: 0x1b340
Digitally Signed Development Software
program load complete, entry point: 0x81000000, size: 0x2ce85e0
Self decompressing the image : ################################################]
smart init is sizing iomem
-----------------------------------------------
Rounded IOMEM up to: 44Mb.
Using 4 percent iomem. [44Mb/1024Mb]
Use, duplication, or disclosure by the Government is
subject to restrictions as set forth in subparagraph
(c) of the Commercial Computer Software - Restricted
Rights clause at FAR sec. 52.227-19 and subparagraph
(c) (1) (ii) of the Rights in Technical Data and Computer
Software clause at DFARS sec. 252.227-7013.
San Jose, California 95134-1706
Cisco IOS Software, CGR2010 Software (CGR2010-UNIVERSALK9-MZ), Version 15.1-1.T
Copyright (c) 1986-2009 by Cisco Systems, Inc.
Compiled Mon 30-Nov-09 06:13 by stshen
Note The following warning message does not appear if the proper CompactFlash card is installed in the ISR.
WARNING: Unsupported compact flash detected. Use of this card during normal
operation can impact and severely degrade performance of the system.
Please use supported high temperature compact flashcards only.
This product contains cryptographic features and is subject to United
States and local country laws governing import, export, transfer and
use. Delivery of Cisco cryptographic products does not imply
third-party authority to import, export, distribute or use encryption.
Importers, exporters, distributors and users are responsible for
compliance with U.S. and local country laws. By using this product you
agree to comply with applicable laws and regulations. If you are unable
to comply with U.S. and local laws, return this product immediately.
A summary of U.S. laws governing Cisco cryptographic products may be found at:
http://www.cisco.com/wwl/export/crypto/tool/stqrg.html
If you require further assistance please contact us by sending email to
Cisco CISCOCGR2010/K9 (revision 1.0) with 1003520K/45056K bytes of memory.
Processor board ID FHH1338P00R
2 Gigabit Ethernet interfaces
32 Low-speed serial(sync/async) interfaces
DRAM configuration is 64 bits wide with parity enabled.
255K bytes of non-volatile configuration memory.
250880K bytes of ATA System CompactFlash 0 (Read/Write)
SETUP: new interface NVI0 placed in "shutdown" state
Press RETURN to get started!
*Mar 1 00:00:03.603: %IOS_LICENSE_IMAGE_APPLICATION-6-LICENSE_LEVEL: Module nad
*Mar 1 00:00:03.695: %IOS_LICENSE_IMAGE_APPLICATION-6-LICENSE_LEVEL: Module na9
*Dec 3 18:11:39.235: %IFMGR-7-NO_IFINDEX_FILE: Unable to open nvram:/ifIndex-ty
*Dec 3 18:11:57.355: %HWIC_SERIAL-6-STARTUP: GRWIC Serial initialized
*Dec 3 18:11:59.335: %HWIC_SERIAL-6-STARTUP: GRWIC Serial initialized
*Dec 3 18:12:01.315: %HWIC_SERIAL-6-STARTUP: GRWIC Serial initialized
*Dec 3 18:12:03.291: %HWIC_SERIAL-6-STARTUP: GRWIC Serial initialized
*Dec 3 18:12:06.863: initialized snmp mgmt interface
*Dec 3 18:12:07.131: %LINK-3-UPDOWN: Interface GigabitEthernet0/0, changed stap
*Dec 3 18:12:07.131: %LINK-3-UPDOWN: Interface GigabitEthernet0/1, changed stap
*Dec 3 18:12:07.131: %LINK-3-UPDOWN: Interface Serial0/0/0, changed state to dn
*Dec 3 18:12:07.131: %LINK-3-UPDOWN: Interface Serial0/0/1, changed state to up
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/0/2, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/0/3, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/0/4, changed state to up
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/0/5, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/0/6, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/0/7, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/1/0, changed state to up
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/1/1, changed state to up
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/1/2, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/1/3, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/1/4, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/1/5, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/1/6, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/1/7, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/2/0, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/2/1, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/2/2, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/2/3, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/2/4, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/2/5, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/2/6, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/2/7, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/3/0, changed state to up
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/3/1, changed state to up
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/3/2, changed state to dn
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/3/3, changed state to up
*Dec 3 18:12:07.135: %LINK-3-UPDOWN: Interface Serial0/3/4, changed state to dn
*Dec 3 18:12:07.139: %LINK-3-UPDOWN: Interface Serial0/3/5, changed state to dn
*Dec 3 18:12:07.139: %LINK-3-UPDOWN: Interface Serial0/3/6, changed state to dn
*Dec 3 18:12:07.139: %LINK-3-UPDOWN: Interface Serial0/3/7, changed state to dn
*Dec 3 18:12:08.291: %LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEtp
*Dec 3 18:12:08.291: %LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEtp
*Dec 3 18:12:08.291: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0n
*Dec 3 18:12:08.295: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0p
*Dec 3 18:12:08.295: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0n
*Dec 3 18:12:08.295: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0n
*Dec 3 18:12:08.295: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0p
*Dec 3 18:12:08.295: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0n
*Dec 3 18:12:08.295: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0n
*Dec 3 18:12:08.295: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/0n
*Dec 4 10:12:09.435 PST: %SYS-6-CLOCKUPDATE: System clock has been updated fro.
*Dec 4 10:12:11.187 PST: %LINEPROTO-5-UPDOWN: Line protocol on Interface NVI0,p
*Dec 4 10:12:11.455 PST: %LINK-5-CHANGED: Interface Serial0/0/1, changed staten
*Dec 4 10:12:11.455 PST: %LINK-5-CHANGED: Interface Serial0/0/2, changed staten
*Dec 4 10:12:11.455 PST: %LINK-5-CHANGED: Interface Serial0/0/3, changed staten
*Dec 4 10:12:11.455 PST: %LINK-5-CHANGED: Interface Serial0/0/4, changed staten
*Dec 4 10:12:11.455 PST: %LINK-5-CHANGED: Interface Serial0/0/5, changed staten
*Dec 4 10:12:11.455 PST: %LINK-5-CHANGED: Interface Serial0/0/6, changed staten
*Dec 4 10:12:11.455 PST: %LINK-5-CHANGED: Interface Serial0/0/7, changed staten
*Dec 4 10:12:11.455 PST: %LINK-5-CHANGED: Interface Serial0/1/1, changed staten
*Dec 4 10:12:11.455 PST: %LINK-5-CHANGED: Interface Serial0/1/2, changed staten
*Dec 4 10:12:12.455 PST: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serian
*Dec 4 10:12:12.455 PST: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serian
*Dec 4 10:12:12.455 PST: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serian
*Dec 4 10:12:12.879 PST: %LINEPROTO-5-UPDOWN: Line protocol on Interface Gigabn
*Dec 4 10:12:13.079 PST: %LINEPROTO-5-UPDOWN: Line protocol on Interface Gigabn
*Dec 4 10:12:16.291 PST: %LINK-3-UPDOWN: Interface GigabitEthernet0/0, changedn
*Dec 4 10:12:16.311 PST: %LINK-3-UPDOWN: Interface GigabitEthernet0/1, changedn
*Dec 4 10:12:17.283 PST: %SYS-5-CONFIG_I: Configured from memory by console
*Dec 4 10:12:17.819 PST: %SYS-5-RESTART: System restarted --
Cisco IOS Software, CGR2010 Software (CGR2010-UNIVERSALK9-MZ), Version 15.1-1.T
Copyright (c) 1986-2009 by Cisco Systems, Inc.
Compiled Mon 30-Nov-09 06:13 by stshen
*Dec 4 10:12:17.827 PST: %SNMP-5-COLDSTART: SNMP agent on host uut is undergoit
*Dec 4 10:12:19.087 PST: %SSH-5-ENABLED: SSH 2.0 has been enabled
*Dec 4 10:12:19.223 PST: %LINK-5-CHANGED: Interface Serial0/2/1, changed staten
*Dec 4 10:12:19.223 PST: %LINK-5-CHANGED: Interface Serial0/2/2, changed staten
*Dec 4 10:12:19.347 PST: %LINK-5-CHANGED: Interface Serial0/2/3, changed staten
*Dec 4 10:12:19.347 PST: %LINK-5-CHANGED: Interface Serial0/2/4, changed staten
*Dec 4 10:12:19.347 PST: %LINK-5-CHANGED: Interface Serial0/2/5, changed staten
*Dec 4 10:12:19.347 PST: %LINK-5-CHANGED: Interface Serial0/2/6, changed staten
*Dec 4 10:12:19.347 PST: %LINK-5-CHANGED: Interface Serial0/2/7, changed staten
*Dec 4 10:12:19.347 PST: %LINK-5-CHANGED: Interface Serial0/3/2, changed staten
*Dec 4 10:12:19.347 PST: %LINK-5-CHANGED: Interface Serial0/3/3, changed staten
*Dec 4 10:12:19.347 PST: %LINK-5-CHANGED: Interface Serial0/3/4, changed staten
*Dec 4 10:12:20.347 PST: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serian
*Dec 4 10:12:20.347 PST: %LINEPROTO-5-UPDOWN: Line protocol on Interface NVI0,n
What to Do Next
If you want to configure the router to load a specified image at the next system reload or power-cycle, see the following documents:
Modifying the Configuration Register
This section describes how to modify the configuration register using the confreg ROM monitor command. You can also modify the configuration register setting from the Cisco IOS CLI using the config-register command in global configuration mode.
Caution
Do not set the configuration register using the
config-register
0x0 command after setting the baud rate. To set the configuration register without affecting the baud rate, use the current configuration register setting by entering the show ver | inc configuration command and then replacing the last (rightmost) number with a 0 in the configuration register command.
Restrictions
The modified configuration register value is automatically written into NVRAM, but the new value does not take effect until you reset or power-cycle the router.
SUMMARY STEPS
1. confreg [ value ]
DETAILED STEPS
|
|
|
Step 1 |
confreg [ value ]
rommon > confreg 0x2102 |
Changes the configuration register settings while in ROM monitor mode.
- Optionally, enter the new hexadecimal value for the configuration register. The value range is from 0x0 to 0xFFFF.
- If you do not enter the value, the router prompts for each bit of the 16-bit configuration register.
|
Examples
In the following example, the configuration register is set to boot the system image from flash memory:
rommon 3 > confreg 0x2102
In the following example, no value is entered; therefore, the system prompts for each bit in the register:
(Virtual Configuration Register: 0x2102)
load rom after netboot fails
boot: image specified by the boot system commands
or default to: cisco2-CISCOCGR2010/K9
do you wish to change the configuration? y/n [n]: y
enable "diagnostic mode"? y/n [n]: y
enable "use net in IP bcast address"? y/n [n]: y
disable "load rom after netboot fails"? y/n [n]: y
enable "use all zero broadcast"? y/n [n]: y
enable "break/abort has effect"? y/n [n]: y
enable "ignore system config info"? y/n [n]: y
change console baud rate? y/n [n]: y
0=9600, 1=4800, 2=1200, 3=2400, 4=19200, 5=38400, 6=57600, 7=115200
change the boot characteristics? y/n [n]: y
1 = the boot helper image
(Virtual Configuration Register: 0xc440)
use net in IP bcast address
ignore system config info
do you wish to change the configuration? y/n [n]: <cr>
You must reset or power cycle for new config to take effect
Obtaining Information on USB Flash Devices
This section describes how to obtain information on USB devices that are installed in the router. For instructions on booting from a USB flash device, see the “Loading a System Image (boot)” section.
SUMMARY STEPS
1. dir usbflash [x]:
2. dev
DETAILED STEPS
|
|
|
Step 1 |
dir usbflash [x]:
rommon > dir usbflash1: |
Displays the contents of the USB flash device, including directories, files, permissions, and sizes.
- 0 —USB flash device inserted in port 0
- 1 —USB flash device inserted in port 1
|
Step 2 |
dev
ROMMON > dev |
Shows the targeted USB flash devices that are inserted in the router and the valid device names that may or may not be currently inserted. |
Examples
Sample Output for the dir usbFlash Command
In some cases, you need to use the reset command first.
Please reset before executing this command
System Bootstrap, Version 12.4(20100226:194457) [petechiu-v150rm7 138], DEVELOPMENT SOFTWARE Copyright (c) 1994-2010 by cisco Systems, Inc.
Total memory size = 1024 MB
Field Upgradeable ROMMON Integrity test _______________________________________
ROM: Digitally Signed Development Software
CGR-2010/K9 platform with 1048576 Kbytes of main memory Main memory is configured to 72 bit mode with ECC enabled
Upgrade ROMMON initialized
Upgrade ROMMON initialized
program load complete, entry point: 0x80903000, size: 0x4c440
dir: cannot open device "usbflash:"
Note The Cisco CGR 2010 in this example does not have USB flash.
Modifying the I/O Memory (iomemset)
This section describes how to modify the I/O memory percentage setting using the memory-size iomemset command.
Note Use the iomemset command only if it is needed for temporarily setting the I/O memory percentage from ROM monitor mode. Using this command improperly can adversely affect the functioning of the router.
The Cisco IOS software can override the I/O memory percentage if the memory-size iomem command is set in the NVRAM configuration. If the Cisco IOS command is present in the NVRAM configuration, the I/O memory percentage set in the ROM monitor with the iomemset command is used only the first time the router is booted up. Subsequent reloads use the I/O memory percentage set using the memory-size iomem command that is saved in the NVRAM configuration.
If you need to set the router I/O memory permanently using a manual method, use the memory-size iomem Cisco IOS command. If you set the I/O memory percentage from the Cisco IOS software, you must restart the router for I/O memory to be properly set.
SUMMARY STEPS
1. iomemset i/o-memory percentage
DETAILED STEPS
|
|
|
Step 1 |
iomemset i/o-memory percentage
rommon> iomemset 15 |
- Reallocates the percentage of DRAM used for I/O memory and processor memory.
|
Examples
In the following example, the percentage of DRAM used for I/O memory is set to 15:
rommon 2 > iomemset
usage: iomemset [smartinit | 5 | 10 | 15 | 20 | 25 | 30 | 40 | 50 ]
rommon 3 >
rommon 3 > iomemset 15
Invoking this command will change the io memory percent
*****WARNING:IOS may not keep this value*****
Do you wish to continue? y/n: [n]: y
------------------------------------------
Current Memory configuration is:
On-board: Size = 1024 MB: Start Phy Addr = 0x00000000_00000000
-------------------------------------------------
Main memory size: 1024 MB in 72 bit mode.
Available main memory starts at 0x81000000, size 1032192KB
Manufacturer's JEDEC ID code:
Upgrading of ROM Monitor command Using Cisco IOS
This section describes how to upgrade the ROM Monitor using Cisco IOS. The upgrade rom-monitor command results in a power-on reset of the router and the CLI will ask if you want to continue. If you answer yes, the CLI will proceed with the upgrade.
Router# upgrade rom-monitor ?
file the name of the SREC file
preference Select ROMMON to be booted on reload
Router# upgrade rom-monitor file ?
archive: SREC file to use
Router# upgrade rom-monitor file flash:CGR2010_RM2_0227.srec?
flash:CGR2010_RM2_0227.srec
Router# upgrade rom-monitor file flash:CGR2010_RM2_0227.srec Platform Field Upgradeable ROMMON LOAD test ___________________________________________
RSA Signature Verification Passed...
ROM: Digitally Signed Development Software
This command will result in a 'power-on reset' of the router!
ROMMON image upgrade in progress.
Erasing boot flash eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
Programming boot flash pppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppp
System Bootstrap, Version 12.4(20100218:213341) [ypatel-cgs2010_RM2 109], DEVELOPMENT SOFTWARE Copyright (c) 1994-2010 by cisco Systems, Inc.
Total memory size = 1024 MB
Running new upgrade for first time
System Bootstrap, Version 12.4(20100226:194457) [petechiu-v150rm7 138], DEVELOPMENT SOFTWARE Copyright (c) 1994-2010 by cisco Systems, Inc.
Total memory size = 1024 MB
Field Upgradeable ROMMON Integrity test _______________________________________
ROM: Digitally Signed Development Software
CGR-2010/K9 platform with 1048576 Kbytes of main memory Main memory is configured to 72 bit mode with ECC enabled
Upgrade ROMMON initialized
Downloading the System Image (tftpdnld)
This section describes how to download a Cisco IOS software image from a remote TFTP server to the router flash memory using the tftpdnld command in ROM monitor mode.
Caution
Use the
tftpdnld command only for disaster recovery because it can erase all existing data in flash memory before it downloads a new software image to the router.
Before you can enter the tftpdnld command, you must set the ROM monitor environment variables.
Prerequisites
Connect the TFTP server to a fixed network port on your router.
Restrictions
- LAN ports on network modules or interface cards are not active in ROM monitor mode. Therefore, only a fixed port on your router can be used for a TFTP download. Use a fixed Ethernet port on the router that is either of the two Gigabit Ethernet ports on Cisco routers with those ports.
- You can only download files to the router. You cannot use the tftpdnld command to retrieve files from the router.
SUMMARY STEPS
1. IP_ADDRESS= ip_address
2. IP_SUBNET_MASK= ip_address
3. DEFAULT_GATEWAY= ip_address
4. TFTP_SERVER=ip_address
5. TFTP_FILE=[ directory-path / ]filename
6. FE_PORT=[0 | 1]
7. FE_SPEED_MODE=[0 | 1 | 2 | 3 | 4 | 5]
8. GE_PORT=[0 | 1]
9. GE_SPEED_MODE=[0 | 1 | 2 | 3 | 4 | 5]
10. MEDIA_TYPE=[0 | 1]
11. TFTP_CHECKSUM= [ 0 | 1 ]
12. TFTP_DESTINATION=[ flash: | usbflash0: | usbflash1:]
13. TFTP_MACADDR=MAC_address
14. TFTP_RETRY_COUNT= retry_times
15. TFTP_TIMEOUT= time
16. TFTP_VERBOSE= setting
17. set
18. tftpdnld [ -hr ]
19. y
DETAILED STEPS
|
|
|
Step 1 |
IP_ADDRESS= ip_address
rommon > IP_ADDRESS=172.16.23.32 |
Sets the IP address of the router. |
Step 2 |
IP_SUBNET_MASK= ip_address
rommon > IP_SUBNET_MASK=255.255.255.224 |
Sets the subnet mask of the router. |
Step 3 |
DEFAULT_GATEWAY= ip_address
rommon > DEFAULT_GATEWAY=172.16.23.40 |
Sets the default gateway of the router. |
Step 4 |
TFTP_SERVER=ip_address
rommon > TFTP_SERVER=172.16.23.33 |
Sets the TFTP server from which the software will be downloaded. |
Step 5 |
TFTP_FILE=[ directory-path / ]filename
rommon > TFTP_FILE=archive/rel22/c2801-i-mz |
Sets the name and location of the file that will be downloaded to the router. |
Step 6 |
FE_PORT= [ 0 | 1 ]
rommon > FE_PORT=0 |
(Optional) Sets the input port to use one of the Fast Ethernet ports. |
Step 7 |
FE_SPEED_MODE= [ 0 | 1 | 2 | 3 | 4 ]
rommon > FE_SPEED_MODE=3 |
(Optional) Sets the Fast Ethernet port speed mode, with these options:
- 0—10 Mbps, half-duplex
- 1—10 Mbps, full-duplex
- 2—100 Mbps, half-duplex
- 3—100 Mbps, full-duplex
- 4—Automatic selection (default)
|
Step 8 |
GE_PORT= [ 0 | 1 ]
rommon > GE_PORT=0 |
(Optional) Sets the input port to use one of the Gigabit Ethernet ports. |
Step 9 |
GE_SPEED_MODE= [ 0 | 1 | 2 | 3 | 4 | 5 ]
rommon > GE_SPEED_MODE=3 |
(Optional) Sets the Gigabit Ethernet port speed mode, with these options:
- 0—10 Mbps, half-duplex
- 1—10 Mbps, full-duplex
- 2—100 Mbps, half-duplex
- 3—100 Mbps, full-duplex
- 4—1 Gbps, full-duplex
- 5—Automatic selection (default)
|
Step 10 |
MEDIA_TYPE= [ 0 | 1 ]
rommon > MEDIA_TYPE=1 |
(Optional) Sets the Gigabit Ethernet connection media type, RJ-45 (0) or SFP (1). Small form-factor pluggable (SFP) mode is applicable only if GE_PORT=0 (gig 0/0); RJ-45 mode is available on both gig 0/0 and gig 0/1 (GE_PORT = 0 or 1). |
Step 11 |
TFTP_CHECKSUM= [ 0 | 1 ]
rommon > TFTP_CHECKSUM=0 |
(Optional) Determines whether the router performs a checksum test on the downloaded image.
- 1 —Checksum test is performed (default).
- 0 —No checksum test is performed.
|
Step 12 |
TFTP_DESTINATION= [ flash: | usbflash0: | usbflash1: ]
rommon > TFTP_DESTINATION=usbflash0: |
(Optional) Designates the targeted flash device as compact flash or USB flash.
- flash: —Compact flash device (default).
- usbflash0: —USB flash device inserted in port 0
- usbflash1: —USB flash device inserted in port 1
|
Step 13 |
TFTP_MACADDR= MAC_address
rommon > TFTP_MACADDR=000e.8335.f360 |
(Optional) Sets the Media Access Controller (MAC) address for this router. |
Step 14 |
TFTP_RETRY_COUNT= retry_times
rommon > TFTP_RETRY_COUNT=10 |
(Optional) Sets the number of times that the router attempts Address Resolution Protocol (ARP) and TFTP download. The default is 7. |
Step 15 |
TFTP_TIMEOUT= time
TFTP_TIMEOUT=1800 |
(Optional) Sets the amount of time, in seconds, before the download process times out. The default is 2400 seconds (40 minutes). |
Step 16 |
TFTP_VERBOSE= setting
rommon > TFTP_VERBOSE=2 |
(Optional) Configures how the router displays file download progress, with these options:
- 0 —No progress is displayed.
- 1 —Exclamation points (!!!) are displayed to indicate file download progress. This is the default setting.
- 2 —Detailed progress is displayed during the file download process; for example:
ARP reply for 1.4.0.1 received.
MAC address 00:00:0c:07:ac:01
|
Step 17 |
set
rommon > set |
Displays the ROM monitor environment variables. Verify that you correctly configured the ROM monitor environment variables. |
Step 18 |
tftpdnld [ -h ] [ -r ]
rommon > tftpdnld |
Downloads the system image specified by the ROM monitor environment variables.
- Entering -h displays command syntax help text.
- Entering -r downloads and boots the new software but does not save the software to flash memory.
- Using no option (that is, using neither -h nor -r) downloads the specified image and saves it in flash memory.
|
Step 19 |
y
Do you wish to continue? y/n: [n]: y |
Confirms that you want to continue with the TFTP download. |
Examples
Sample Output for Recovering the System Image (tftpdnld)
rommon 16 > IP_ADDRESS=171.68.171.0
rommon 17 > IP_SUBNET_MASK=255.255.254.0
rommon 18 > DEFAULT_GATEWAY=171.68.170.3
rommon 19 > TFTP_SERVER=171.69.1.129
rommon 20 > TFTP_FILE=c2801-is-mz.113-2.0.3.Q
IP_SUBNET_MASK: 255.255.254.0
DEFAULT_GATEWAY: 171.68.170.3
TFTP_SERVER: 171.69.1.129
TFTP_FILE: c2801-is-mz.113-2.0.3.Q
Invoke this command for disaster recovery only.
WARNING: all existing data in all partitions on flash will be lost!
Do you wish to continue? y/n: [n]: y
Receiving c2801-is-mz.113-2.0.3.Q from 171.69.1.129 !!!!!.!!!!!!!!!!!!!!!!!!!.!!
File reception completed.
Copying file c2801-is-mz.113-2.0.3.Q to flash.
Erasing flash at 0x607c0000
program flash location 0x60440000
Sample Output for the set ROM Monitor Command
IP_SUBNET_MASK=255.255.0.0
TFTP_SERVER=223.255.254.254
TFTP_FILE=jruiz/cgr2010-universalk9-mz.SSA.151-0.17.T
LICENSE_BOOT_LEVEL=datak9,datak9:cgr2010;
CRASHINFO=flash:crashinfo_20070725-212015
RET_2_RTS=09:38:37 PST Fri Dec 4 2009
What to Do Next
If you want to configure the router to load a specified image at the next system reload or power-cycle, see the “ Loading and Managing System Images” section in Cisco IOS Configuration Fundamentals Command Reference .
Troubleshooting Crashes and Hangs (stack, context, frame, sysret, meminfo)
This section lists and describes some ROM monitor commands that can be used to troubleshoot router crashes and hangs.
Most ROM monitor debug commands are functional only when the router crashes or hangs. If you enter a debug command when crash information is not available, the following error message appears:
"xxx: kernel context state is invalid, can not proceed."
The ROM monitor commands in this section are all optional and can be entered in any order.
Router Crashes
A router or system crash is a situation in which the system detects an unrecoverable error and restarts itself. The errors that cause crashes are typically detected by processor hardware, which automatically branches to special error-handling code in the ROM monitor. The ROM monitor identifies the error, prints a message, saves information about the failure, and restarts the system. For detailed information about troubleshooting crashes, see Troubleshooting Router Crashes and Understanding Software-forced Crashes.
Router Hangs
A router or system hang is a situation in which the system does not respond to input at the console port or to queries, such as Telnet and SNMP, sent from the network.
Router hangs occur when:
- The console does not respond
- Traffic does not pass through the router
Router hangs are discussed in detail in Troubleshooting Router Hangs.
ROM Monitor Console Communication Failure
Under certain configuration situations where there is improper configuration, it can be impossible to establish a console connection with the router because of a speed mismatch or other incompatibility. The most obvious symptom is a set of erroneous characters in the console display.
If a ROM monitor failure of this type occurs, you may need to change a jumper setting on the motherboard so that the router can reboot for troubleshooting. Procedures for accessing the motherboard and jumper locations are described in the installation of internal components section of the hardware installation document for your router.
The jumper to be changed is DUART DFLT, which sets the console connection data baud rate to 9600, regardless of user configuration. The jumper forces the data rate to an acceptable value.
Restrictions
Do not manually reload or power-cycle the router unless reloading or power cycling is required for troubleshooting a router crash. System reload or power-cycle can cause important information that is needed for determining the root cause of the problem to be lost.
SUMMARY STEPS
1. stack
or
k
2. context
3. frame [ number ]
4. sysret
5. meminfo
DETAILED STEPS
|
|
|
Step 1 |
stack or k
rommon > stack |
(Optional) Obtains a stack trace.
|
Step 2 |
context
rommon > context |
(Optional) Displays the CPU context at the time of the fault.
- If it is available, the context from kernel mode and process mode of a loaded image is displayed.
|
Step 3 |
frame [ number ]
rommon > frame 4 |
(Optional) Displays an entire individual stack frame.
- The default is 0 (zero), which is the most recent frame.
|
Step 4 |
sysret
rommon > sysret |
(Optional) Displays return information from the last booted system image.
- The return information includes the reason for terminating the image, a stack dump of up to eight frames, and, if an exception is involved, the address at which the exception occurred.
|
Step 5 |
meminfo [-l]
rommon > meminfo |
(Optional) Displays memory information, including:
- Main memory size, starting address, and available range
- Packet memory size
- NVRAM size
Alternatively, using the meminfo -l command provides information on supported DRAM configurations for the router. |
Examples
This section provides the following examples:
Sample Output for the stack ROM Monitor Command
Kernel Level Stack Trace:
Initial SP = 0x642190b8, Initial PC = 0x607a0d44, RA = 0x61d839f8
Frame 0 : FP= 0x642190b8, PC= 0x607a0d44, 0 bytes
Frame 1 : FP= 0x642190b8, PC= 0x61d839f8, 24 bytes
Frame 2 : FP= 0x642190d0, PC= 0x6079b6c4, 40 bytes
Frame 3 : FP= 0x642190f8, PC= 0x6079ff70, 32 bytes
Frame 4 : FP= 0x64219118, PC= 0x6079eaec, 0 bytes
Process Level Stack Trace:
Initial SP = 0x64049cb0, Initial PC = 0x60e3b7f4, RA = 0x60e36fa8
Frame 0 : FP= 0x64049cb0, PC= 0x60e3b7f4, 24 bytes
Frame 1 : FP= 0x64049cc8, PC= 0x60e36fa8, 24 bytes
Frame 2 : FP= 0x64049ce0, PC= 0x607a5800, 432 bytes
Frame 3 : FP= 0x64049e90, PC= 0x607a8988, 56 bytes
Frame 4 : FP= 0x64049ec8, PC= 0x64049f14, 0 bytes
Sample Output for the context ROM Monitor Command
Reg MSW LSW | Reg MSW LSW
------ ---------- ---------- | ----- ---------- ----------
zero : 00000000 00000000 | s0 : 00000000 34018001
AT : 00000000 24100000 | s1 : 00000000 00000001
v0 : 00000000 00000003 | s2 : 00000000 00000003
v1 : 00000000 00000000 | s3 : 00000000 00000000
a0 : 00000000 0000002b | s4 : 00000000 64219118
a1 : 00000000 00000003 | s5 : 00000000 62ad0000
a2 : 00000000 00000000 | s6 : 00000000 63e10000
a3 : 00000000 64219118 | s7 : 00000000 63e10000
t0 : 00000000 00070808 | t8 : ffffffff e7400884
t1 : 00000000 00000000 | t9 : 00000000 00000000
t2 : 00000000 63e10000 | k0 : 00000000 00000000
t3 : 00000000 34018001 | k1 : 00000000 63ab871c
t4 : ffffffff ffff80fd | gp : 00000000 63c1c2d8
t5 : ffffffff fffffffe | sp : 00000000 642190b8
t6 : 00000000 3401ff02 | s8 : 00000000 6429274c
t7 : 00000000 6408d464 | ra : 00000000 61d839f8
HI : ffffffff e57fce22 | LO : ffffffff ea545255
EPC : 00000000 607a0d44 | ErrPC : ffffffff bfc05f2c
Stat : 34018002 | Cause : 00000020
Reg MSW LSW | Reg MSW LSW
------ ---------- ---------- | ----- ---------- ----------
zero : 00000000 00000000 | s0 : 00000000 6401a6f4
AT : 00000000 63e10000 | s1 : 00000000 00000000
v0 : 00000000 00000000 | s2 : 00000000 64049cf0
v1 : 00000000 00000440 | s3 : 00000000 63360000
a0 : 00000000 00000000 | s4 : 00000000 63360000
a1 : 00000000 00070804 | s5 : 00000000 62ad0000
a2 : 00000000 00000000 | s6 : 00000000 63e10000
a3 : 00000000 00000000 | s7 : 00000000 63e10000
t0 : 00000000 00000000 | t8 : ffffffff e7400884
t1 : 00000000 64928378 | t9 : 00000000 00000000
t2 : 00000000 00000001 | k0 : 00000000 644822e8
t3 : ffffffff ffff00ff | k1 : 00000000 61d86d84
t4 : 00000000 6079eee0 | gp : 00000000 63c1c2d8
t5 : 00000000 00000001 | sp : 00000000 64049cb0
t6 : 00000000 00000000 | s8 : 00000000 6429274c
t7 : 00000000 6408d464 | ra : 00000000 60e36fa8
HI : ffffffff e57fce22 | LO : ffffffff ea545255
EPC : 00000000 60e3b7f4 | ErrPC : ffffffff ffffffff
Stat : 3401ff03 | Cause : ffffffff
Sample Output for the frame ROM Monitor Command
Stack Frame 2, SP = 0x642190d0, Size = 40 bytes
[0x642190d0 : sp + 0x000] = 0xffffffff
[0x642190d4 : sp + 0x004] = 0xbfc05f2c
[0x642190d8 : sp + 0x008] = 0xffffffff
[0x642190dc : sp + 0x00c] = 0xffffffff
[0x642190e0 : sp + 0x010] = 0x6401a6f4
[0x642190e4 : sp + 0x014] = 0x00000000
[0x642190e8 : sp + 0x018] = 0x64049cf0
[0x642190ec : sp + 0x01c] = 0x63360000
[0x642190f0 : sp + 0x020] = 0x63360000
[0x642190f4 : sp + 0x024] = 0x6079ff70
Sample Output for the sysret ROM Monitor Command
count: 19, reason: user break
pc:0x801111b0, error address: 0x801111b0
FP: 0x80005ea8, PC: 0x801111b0
FP: 0x80005eb4, PC: 0x80113694
FP: 0x80005f74, PC: 0x8010eb44
FP: 0x80005f9c, PC: 0x80008118
FP: 0x80005fac, PC: 0x80008064
FP: 0x80005fc4, PC: 0xfff03d70
FP: 0x80005ffc, PC: 0x00000000
FP: 0x00000000, PC: 0x00000000
Sample Output for the meminfo ROM Monitor Command
------------------------------------------
Current Memory configuration is:
On-board: Size = 1024 MB: Start Phy Addr = 0x00000000_00000000
-------------------------------------------------
Main memory size: 1024 MB in 72 bit mode.
Available main memory starts at 0x81000000, size 1032192KB
Manufacturer's JEDEC ID code:
You can also use the meminfo -l command to show the supported DRAM configurations for the router. The following is sample output for the command:
The following memory configs are supported:
-------------------------------------------------
Troubleshooting Tips
See the following documents:
Exiting ROM Monitor Mode
This section describes how to exit ROM monitor mode and enter the Cisco IOS command-line interface (CLI). The method that you use to exit ROM monitor mode depends on how your router entered ROM monitor mode:
- If you reload the router and enter the Break key sequence to enter ROM monitor mode when the router would otherwise have booted the system image, you can exit ROM monitor mode by doing either of the following:
– Enter the i command or the reset command, which restarts the booting process and loads the system image.
– Enter the cont command, which continues the booting process and loads the system image.
- If your router entered ROM monitor mode because it could not locate and load the system image, perform the steps in the following procedure.
SUMMARY STEPS
1. dir flash: [directory]
2. boot flash: [directory] [ filename ]
or
boot filename tftpserver
or
boot [ filename ]
DETAILED STEPS
|
|
|
Step 1 |
dir flash: [directory]
rommon > dir flash: |
Displays a list of the files and directories in flash memory.
- Locate the system image that you want the router to load.
- If the system image is not in flash memory, use the second or third option in Step 2.
|
Step 2 |
boot flash: [directory] [ filename ] or boot filename tftpserver or boot [ filename ]
ROMMON > boot flash:myimage
ROMMON > boot someimage 172.16.30.40
ROMMON > boot |
In order, the examples here direct the router to:
- Boot the first image or a specified image in flash memory.
- Boot the specified image over the network from the specified TFTP server (hostname or IP address).
- Boot from the boothelper image because it does not recognize the device ID. This form of the command is used to netboot a specified image.
You can override the default boothelper image setting by setting the BOOTLDR Monitor environment variable to point to another image. Any system image can be used for this purpose. Note Options to the boot command are -x (load image but do not execute) and -v (verbose). |
Examples
Sample Output for the dir flash: Command in ROM Monitor mode
program load complete, entry point: 0x80803000, size: 0x1b340
2 47089944 -rw- cgr2010-universalk9-mz.SSA.151-0.17.T
What to Do Next
If you want to configure the router to load a specified image at the next system reload or power-cycle, see the “ Loading and Managing System Images” section in Cisco IOS Configuration Fundamentals Command Reference .