一 灾难恢复
Configuration Summary
......
boot: the ROM moniter
do you wish to change the configuration? y/n [n]: y
enable "diagnostic mod" ? y/n [n]:
......
change console baud rate ? y/n [n]: y
enter rate : 0 = 9600, 1 = 4800, 2 = 1200, 3 = 2400
4 = 19200, 5 = 38400, 6 = 57600, 7 = 115200 [0]: 7
change the boot characteristics? y/n [n]:
enable are:
breakabout has effect
console baud: 115200
boot: the ROM Moniter
do you wish change the configuation? y/n [n]:
rommon 1 > xmodem -?
xmodem: illegal option -- ?
usage: xmodem [-cyrx]
-c CRC 16
-y ymodem-batch protocol
-r copy p_w_picpath to dram for launch
-x do not launch on download completion
Do you wish to continue? y/n [n]: y
Ready to receive file c2600-is-mz.122-10a.bin ...
(注意: 在路由器重起的时候要把原来的console baud改为9600 bit/s)
IP_ADDRESS
IP_SUBNET_MASK
DEFAULT_GATEWAY
TFTP_SERVER
TFTP_FEILE
②使用tftpdnld(很简单,但我把输出也抄了上来)
rommon 1 > tftpdnld
IP_ADDRESS:172.16.0.12;
IP_SUBNET_MASK=255.255.255.0
DEFAULT_GATEWAY=172.16.0.1
TFTP_SERVER=172.31.0.4
TFTP_FILE=recovery/original_2003_Jan_22/c2600-mz.121-5
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 recovery/original_2003_Jan_22/c2600-mz.121-5 from
172.31.0.4 !!!!!!!!!!!!.!!!!!!!!!!!!!!!!!!!.!!
File reception completed.
Copying file recovery/original_2003_Jan_22/c2600-mz.121-5 to flash.
Erasing flash at 0x607c0000
program flash location 0x60440000
Router# configure terminal
Router(config)# boot system flash IOS_filename
Router(config)# boot system tftp IOS_filename tftp_address
Router(config)#boot system rom
[Ctr-Z]
Router# copy running-config startup-config
Cisco 2000
Cisco 2500
Cisco 3000
Cisco 4000
Cisco AccessPro
Cisco 7000 (RP)
Cisco AGS
Cisco IGS(IGS?让我想起《三国战记》和《西游释厄传》了)
Cisco STS-10x
下列Cisco 产品使用confreg工具:
CIsco 1003 Cisco 7200
Cisco 1007 Cisco uBR 7200
Cisco 1005 Cisco 7500
Cisco 1600 Cisco 12000(传说中的一万两千型Internet路由器Grrr...)
Cisco 1700 Cisco LS1010
Cisco 2600 Catalyst 5500 (RSM)
Cisco 3600 Catalyst 8510-CSR
Cisco 4500 Catalyst 8510-MSR
Cisco 4700 Catalyst 8540-CSR
Cisco AS5x00 Catalyst 8540-MSR
按照下面的步骤恢复Cisco路由器上的密码:
使用o/r命令(不支持confreg的机器上)配置寄存器码的第六位(与原始值一起.注意是从第0位开始的).例如,如果原始码为0x2102,那么配置第六位为0x2142(hexdecimal0x2102=0010,0001,0000,0010,0x2142=0010,0001,0100,0010)
> 0x2142
(P.S/ 0x2142使机器从闪存中启动,0x2141从ROM中启动.如果系统配有闪存,并且没有受到损坏,0x42是最好的设置.只有在闪存被擦除或者没有闪存的情况下,才能使用0x41.如果值为0x41,只能查看或者清除配置文件,但不能更改口令.闪存擦了或坏了怎么半?)
要改变口令(例如,口令是加密的):
Router#copy startup-config running-config
在Cisco IOS 10.3以前的版本中使用
Router#config memory
(注意:因为路由器在启动中没有加载配置文件,现在的所有接口都是关闭的)
Router#config terminal
Router(config)#enable secret newpassword
Router(config)#enable password newpassword
Router(config)#line con 0
Router(config)#login
Router(config)#password newpassword
Router#copy running-config startup-config
Router#config terminal
Router(config)#config-register 0xvalue(默认0x2102)
Router#copy running-config statrup-config
⑦重启机器后一切OK!
Bits Hex Binary Description