cisco路由器密码恢复
2016-07-06 16:51
330 查看
一.原理
启动寄存器(NVRAM)的数值是修改路由器的模式的一个关键,尽量不要修改!
0x2101:对flash可以读写.
0x2102:正常模式启动.
0x2141:对flash进行合并,如果flash条子是2条,则利用此模式可以合二为一.
0x2142:不读取NVRAM的基本配置模式,用于密码的恢复.
只要启动时将NVRAM的数值修改成0x2142就不会读取密码了,进入系统后修改密码,然后再将NVRAM的数值改回0x2012,保存后重启就可以进入正常的IOS了
R#show version "在version中可以查看到路由器NVRAM的数值"
......
Configuration register is 0x2102 "默认的数值为0x2102"
二.步骤:1.关闭路由器电源
2.启动路由器,按键盘上的Ctrl+Break(中断)键进入rommon模式(最小IOS模式)
rommon 1 > ?
boot boot up an external process
confreg configuration register utility
dir list files in file system
help monitor builtin command help
reset system reset
set display the monitor variables
tftpdnld tftp image download
unset unset a monitor variable
rommon 2 >
3.修改配置寄存器的数值为0x2142
rommon 2 > confreg 0x2142
rommon 3 >
4.修改完成后重启路由器
rommon 4 > reset
5.重启后进入正常IOS模式
--- System Configuration Dialog ---
Continue with configuration dialog? [yes/no]: n
Press RETURN to get started!
R>en
R#
6.copy startup-config running-config "将start的配置copy到run中才能修改原来配置的密码,否则就是修改不读取密码的0x2142的IOS配置了"
7.进入全局模式修改密码
R#configure t
Enter configuration commands, one per line. End with CNTL/Z.
R(config)#enable password 123
R(config)#
8.修改密码后将NVRAM的数值改回原来的0x2102
R#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
R(config)#config-register 0x2102 "不修改的话永远都是读取0x2142的IOS的配置了,而不是正常的0x2102的配置"
9.保存配置
R#write或者copy
run start
10.重新启动路由器
reload "进入到正常的0x2102的IOS模式下"
启动寄存器(NVRAM)的数值是修改路由器的模式的一个关键,尽量不要修改!
0x2101:对flash可以读写.
0x2102:正常模式启动.
0x2141:对flash进行合并,如果flash条子是2条,则利用此模式可以合二为一.
0x2142:不读取NVRAM的基本配置模式,用于密码的恢复.
只要启动时将NVRAM的数值修改成0x2142就不会读取密码了,进入系统后修改密码,然后再将NVRAM的数值改回0x2012,保存后重启就可以进入正常的IOS了
R#show version "在version中可以查看到路由器NVRAM的数值"
......
Configuration register is 0x2102 "默认的数值为0x2102"
二.步骤:1.关闭路由器电源
2.启动路由器,按键盘上的Ctrl+Break(中断)键进入rommon模式(最小IOS模式)
rommon 1 > ?
boot boot up an external process
confreg configuration register utility
dir list files in file system
help monitor builtin command help
reset system reset
set display the monitor variables
tftpdnld tftp image download
unset unset a monitor variable
rommon 2 >
3.修改配置寄存器的数值为0x2142
rommon 2 > confreg 0x2142
rommon 3 >
4.修改完成后重启路由器
rommon 4 > reset
5.重启后进入正常IOS模式
--- System Configuration Dialog ---
Continue with configuration dialog? [yes/no]: n
Press RETURN to get started!
R>en
R#
6.copy startup-config running-config "将start的配置copy到run中才能修改原来配置的密码,否则就是修改不读取密码的0x2142的IOS配置了"
7.进入全局模式修改密码
R#configure t
Enter configuration commands, one per line. End with CNTL/Z.
R(config)#enable password 123
R(config)#
8.修改密码后将NVRAM的数值改回原来的0x2102
R#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
R(config)#config-register 0x2102 "不修改的话永远都是读取0x2142的IOS的配置了,而不是正常的0x2102的配置"
9.保存配置
R#write或者copy
run start
10.重新启动路由器
reload "进入到正常的0x2102的IOS模式下"
相关文章推荐
- ibatis 批处理
- 循环神经网络(RNN, Recurrent Neural Networks)介绍
- U-Boot 的移植入门(2)——nand flash识别与操作
- C++虚函数和纯虚函数
- Linux保存修改vi指令
- iOS app性能优化的那些事(一)
- JMeter基础之-使用技巧
- jmeter 脚本增强(参数化)
- JAVA的节点流和处理流
- Linux lsof命令使用小结
- 带 IK 分词器的 Luke 和 搜索应用服务器solr
- 实现jqgrid 行编辑,级联查询,并点击按钮保存
- 将自己写的Python代码打包放到PyPI上
- 112. Path Sum
- webuploader文件接收服务端
- solution Of 1018. Public Bike Management (30)
- [书目20160706]成功销售实用经典10步骤(美国培训与发展协会实用经典10步系列)
- python vs ruby
- android_结构
- 阿里面经之解答 by cmershen(4)——线程池