Changing Configuration Register Settings

Now that you understand a little more about configuration register settings, let’s take a look at how current register settings can be identified, and then changed.
The easiest way to determine a router’s current configuration register setting is by using the show version command. The configuration register setting will appear at the end of the command’s output, as shown below.

Router#show version
Cisco Internetwork Operating System Software
IOS (tm) 2500 Software (C2500-D-L), Version 12.0(5), RELEASE SOFTWARE (fc1)
Copyright (c) 1986-1999 by cisco Systems, Inc.
Compiled Tue 15-Jun-99 20:08 by phanguye
Image text-base: 0x0000144C, data-base: 0x00637308
ROM: System Bootstrap, Version 5.2(8a), RELEASE SOFTWARE
BOOTFLASH: 3000 Bootstrap Software (IGS-RXBOOT), Version 10.2(8a), RELEASE SOFTW
ARE (fc1)
Router uptime is 2 hours, 50 minutes
System restarted by power-on
System image file is "flash:d1205.bin"
cisco 2500 (68030) processor (revision A) with 16384K/2048K bytes of memory.
Processor board ID 02265778, with hardware revision 00000000
Bridging software.
X.25 software, Version 3.0.0.
1 Ethernet/IEEE 802.3 interface(s)
1 Serial network interface(s)
1 PCbus interface(s)
32K bytes of non-volatile configuration memory.
4096K bytes of processor board System flash (Read/Write)
Configuration register is 0x2102

A router’s configuration register settings can be changed from global configuration mode using the config-register command, followed by the new value. For example, let’s say that we wanted to configure our router such that the break command is enabled at any time. That would involve setting the configuration register value to 0x2002, changing the value of bit 8 from a 1 to a 0.

Router#config t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#config-register ?
<0x0-0xFFFFFFFF> Config register number
Router(config)#config-register 0x2002
Router(config)#^Z
Router#show version
Cisco Internetwork Operating System Software
IOS (tm) 2500 Software (C2500-D-L), Version 12.0(5), RELEASE SOFTWARE (fc1)
Copyright (c) 1986-1999 by cisco Systems, Inc.
Compiled Tue 15-Jun-99 20:08 by phanguye
Image text-base: 0x0000144C, data-base: 0x00637308
Configuration register is 0x2142 (will be 0x2002 at next reload)

The output of the show version command has been truncated. Notice that the configuration register value is still 0x2102, but will be 0x2002 at the next reload. It is not necessary to issue the copy run star command in order to save changes to the configuration register value.

In cases where you cannot access a router because a valid IOS image cannot be found (or you’ve forgotten the router’s password), you will need to change the configuration register value from ROM Monitor mode. Recall that to access ROM Monitor mode, you’ll need to be connected to the router via the console port to issue the break sequence. The sequence of commands to change the configuration register will differ, depending upon whether your ROM Monitor prompt is > (like on a 2500) or rommon 1> (like on a 2600).
To change the configuration register value from ROM Monitor mode on a Cisco 2500, reboot the router and issue the break sequence (Ctrl+Break if using HyperTerminal). This will provide you with the > prompt, as shown below.

19:44:26: %SYS-5-RELOAD: Reload requested
System Bootstrap, Version 5.2(8a), RELEASE SOFTWARE
Copyright (c) 1986-1995 by cisco Systems
2500 processor with 16384 Kbytes of main memory
Abort at 0x10EA880 (PC)
>

In the Cisco 2500’s ROM Monitor mode, the command o shows the current configuration register settings, as well as the purpose of the various bits.

>o
Configuration register = 0x2002 at the last boot
Bit# Configuration register option settings
15 Diagnostic mode disabled
14 IP broadcasts do not have network numbers
13 Boot default ROM software if network boot fails
12-11 Console speed is 9600 baud
10 IP broadcast with ones
08 Break disabled
07 OEM disabled
06 Ignore configuration disabled
03-00 Boot file is cisco2-2500 (or ‘boot system’ command)
>

The command to modify the configuration register value is o/r, followed by the new register value. After pressing enter, use the command i to initialize the router. The i command reloads the router, using the new configuration register setting. In this case, a configuration register value of 0x2102 ensures that the router will boot as per the factory default settings.

>o/r 0x2102
>i

If you issue the break sequence on a Cisco 2600 router, you’ll be presented with the rommon> prompt. Although the commands from this prompt are a little different, they achieve the same result. In the example below, we’re setting the configuration register to 0x2142, which tells the router to ignore the contents of the startup configuration file, since bit 6 has been set. The command to change the configuration register from the rommon> prompt is confreg, followed by the new register value. To reload the router, issue the reset command.

rommon 1>confreg 0x2142
rommon 2>reset

After issuing the reset command, the router will reboot using the new configuration register value of 0x2142.

Common configuration register settings and their meanings:

0x2102 The default configuration register setting. The break command is disabled, the contents of NVRAM are processed, and the router will boot according to the commands stored in NVRAM

0x2101 The break command is disabled. The router will process the contents of NVRAM, but will boot into the RxBoot image stored in ROM.

0x2100 The break command is disabled, and the router will boot into ROM Monitor mode.

0x2142 The break command is disabled, and the router will ignore the contents of NVRAM during the boot process.

0x2002 The break command is enabled, but otherwise the router will boot normally.

Author: Dan DiNicolo

Dan DiNicolo is a freelance author, consultant, trainer, and the managing editor of 2000Trainers.com. He is the author of the CCNA Study Guide found on this site, as well as many books including the PC Magazine titles Windows XP Security Solutions and Windows Vista Security Solutions. Click here to contact Dan.