asíncrono trifásico
4.3 MOTOR DE CORRIENTE CONTINUA
Cisco routers perform the same types of tasks that a typical computer performs when you power it on or reboot (reload) it. Of course, most of us do not think about these details very often. The router performs some somewhat obvious steps, with one of those being tricky—namely, the process of choosing the location of the software to load and use in the router. And that software might not be IOS!
The boot process follows this basic litany:
1 The router performs a power-on self-test (POST) to discover and verify the hardware.
2 The router loads and runs bootstrap code from ROM.
3 The router finds the IOS or other software and loads it.
4 The router finds the configuration file and loads it into running config.
All routers attempt all four steps each time that the router is powered on or reloaded. The POST code and functions cannot be changed by the router administrator. The location of the bootstrap code, the IOS to load, and the configuration file can be changed by the administrator—but you almost always use the default location for the bootstrap code (ROM) and for the initial configuration (NVRAM). So, the location of IOS or other software is the only part that typically is changed.
Three categories of operating systems can be loaded into the router:
•
The full-function IOS image that you have been introduced to in this chapter.•
A limited-function IOS that resides in ROM.•
A different non-IOS operating system that is also stored in ROM, and this can be loaded.This operating system, called ROM Monitor, is used for two purposes—for low-level debugging and for password recovery. Unless you are performing password recovery, you would seldom use ROMMON mode.
54 Chapter 2: Cisco IOS Software Fundamentals
Table 2-6 lists the three operating system categories and their main functions.
So, you need to tell the router whether to use ROMMON, the limited-function IOS, or the full- featured IOS. Of course, most of the time you use the full-featured IOS in Flash memory. However, you might want to use IOS that resides on a TFTP server, or there could be multiple IOS images in Flash memory—and all of these options are configurable.
Two configuration tools tell the router what OS to load. First, the configuration register tells the router whether to use a full-featured IOS, ROMMON, or the limited-feature IOS, which is also
called RXBOOT mode. The configuration register is a 16-bit software register in the router, and
its value is set using the config-register global configuration command. (Some older routers
had a hardware configuration register with jumpers on the processor card, to set bits to a value of 0 or 1.) Figure 2-11 shows an example binary breakdown of the default value for the configuration register, which is hexadecimal 2102.
Figure 2-11 Binary Version of Configuration Register, Value Hex 2102
The boot field is the name of the low-order 4 bits of the configuration register. This field can be
considered a 4-bit value, represented as a single hexadecimal digit. (Cisco represents hexadecimal values by preceding the hex digit(s) with 0x—for example, 0xA would mean a
single hex digit A.) If the boot field is hex 0, ROMMON is loaded. If the boot field is hex 1,
RXBOOT mode is used. For anything else, it loads a full-featured IOS. But which one?
Table 2-6 Three OS Categories for Routers
Operating System Location Where It Is Stored Purpose
Full-featured IOS Typically in Flash memory; can be on TFTP server
Full-featured, normal IOS used in production.
Limited-function IOS ROM Basic IP connectivity, used when Flash memory is broken and you need IP connectivity to copy a new IOS into Flash memory. Called RXBOOT mode.
ROMMONROM Low-level debugging, usually by the Cisco TAC and for password recovery. Called ROM Monitor mode.
15 14 13 12 0 0 1 0 11 10 9 8 0 0 0 1 7 6 5 4 0 0 0 0 3 2 1 0 0 0 1 0
Upgrading Cisco IOS Software and the Cisco IOS Software Boot Process 55
The second method used to determine where the router tries to obtain an IOS image is through
the use of the boot system configuration command. If the configuration register calls for a full-
featured IOS (boot field 2-F), the router reads the configuration file for boot system commands. If there are no boot system commands, the router takes the default action, which is to load the first file in Flash memory. Table 2-7 summarizes the use of the configuration register and the
boot system command at initialization time.
Table 2-7 boot system Command
Value of Boot Field Boot System Commands Result
0x0 Ignored if present ROMMON is loaded.
0x1 Ignored if present IOS from ROM is loaded, also known as RXBOOT mode.
0x2-0xF No boot command The first IOS file in Flash memory is loaded; if that fails, the router broadcasts looking for an IOS on a TFTP server. If that fails, IOS from ROM is loaded.
0x2-0xF boot system ROM IOS from ROM is loaded.
0x2-0xF boot system flash The first file from Flash memory is loaded.
0x2-0xF boot system flashfilename IOS with the name filename is loaded from Flash memory.
0x2-0xF boot system tftp filename 10.1.1.1 IOS with the name filename is loaded from the TFTP server.
0x2-0xF Multiple boot system commands, any variety
An attempt occurs to load IOS based on the first boot command in configuration. If that fails, the second boot command is used, and so on, until one is successful.
56 Chapter 2: Cisco IOS Software Fundamentals
Password Recovery
Start Extra Credit
The password-recovery process relies on the fact that the configuration register can be used to make the router ignore the NVRAM configuration when the router is reloaded. The router will be up, but with a default configuration; this allows a console user to log in, enter privileged mode, and change any encrypted passwords or view any unencrypted passwords. However, there is a “chicken and the egg” problem—to cause the router to ignore NVRAM at boot time, the configuration register must be changed. To do that, you must be in privileged mode—and if you were already there, you could reset any encrypted passwords or view any unencrypted ones. It seems to be a vicious circle.
ROMMON will allow you to change the configuration register without knowing any passwords or even booting the IOS. To enter ROMMON mode, press the Break key during the first 60 seconds after power-on of the router. Then you must set bit 6 in the configuration register to binary 1, which is done by setting the entire config register with a four-digit hexadecimal value. For example, hex 2142 is identical to hex 2102, except that bit 6 is binary 1. Knowing how to reset the config register enables you to boot the router (ignoring NVRAM), allowing the console user to see or change the unencrypted or encrypted passwords, respectively. The process is slightly different for different models of routers, although the concepts are identical. Table 2-8 outlines the process for each type of router. For more information, see http://www.cisco.com/warp/public/474/.
End Extra Credit
Table 2-8 Password Recovery
Step Function
How to Do This for 1600, 2600, 3600, 4500, 7200, 7500
How to Do This for 2000, 2500, 3000, 4000, 7000
1 Turn the router off and then back on again.
Use the power switch. Same as other routers.
2 Press the Break key within the first 60 seconds.
Find the Break key on your console device’s keyboard.
Same as other routers.
3 Change the configuration register so that bit 6 is 1.
Use the ROMMON command confreg, and answer the prompts.
Use the ROMMON command o/r 0x2142.
4 Cause the router to load IOS.
Use the ROMMON reload
command or, if unavailable, power off and on.
Use the ROMMON command initialize.
Upgrading Cisco IOS Software and the Cisco IOS Software Boot Process 57
A few nuances need further explanation. First, the confreg ROMMON command prompts you
with questions that correspond to the functions of the bits in the configuration register. When the
prompt asks, “Ignore system config info[y/n]?”, it is asking you about bit 6. Entering yes sets the
bit to 1. The rest of the questions can be defaulted. The last confreg question asks, “Change boot
characteristics[y/n]?”, which asks whether you want to change the boot field of the config register. You don’t really need to change it, but the published password-recovery algorithm lists that step, which is the only reason that it is mentioned here. Just changing bit 6 to 1 is enough to get the router booted and you into privileged mode to find or change the passwords.
Step Function
How to Do This for 1600, 2600, 3600, 4500, 7200, 7500
How to Do This for 2000, 2500, 3000, 4000, 7000
5 Avoid using setup mode, which will be prompted for at the console.
Just say no. Same as other routers.
6 Enter privileged mode at console.
Press Enter and use the
enable command (no password required).
Same as other routers.
7 Assuming that you still want to use the
configuration in NVRAM, copy it to the running config.
copy startup-config running-config
copy startup-config running-config
8 View startup config to see unencrypted passwords.
Use the exec command
show startup-config.
Same as other routers.
9 Use the appropriate config commands to reset encrypted commands.
For example, use enable secret xyz123 command to set the enable secret password.
Same as other routers.
10 Change the config register back to its original value.
Use the config command
config-reg 0x2102.
Same as other routers.
11 Reload the router after saving the configuration.
Use the copy running- config startup-config and
reload commands.
Same as other routers.
58 Chapter 2: Cisco IOS Software Fundamentals