一、按住交换机前面板左下方的MODE键,而后打开交换机电源。ide
二、进入BOOT模式,输入“flash_init”,初始化FLASH信息:3d
switch:flash_initblog
[3]、输入“load_helper”命令:内存
switch:load_helper路由
(部分型号交换机不需执行该命令。查看进入BOOT模式后,信息提示是否有“load_helper”。若有,需输入。没有不需输入。)terminal
例:信息提示显示为get
flash_initflash
load_helperit
bootclass
须要输入“load_helper”命令
如上图显示,就不须要输入“load_helper”命令
四、执行“dir flash:”命令:
执行“dir flash:”命令后咱们应该能够看到VLAN.DAT,IOS镜像,以及config.text 文件。交换机密码恢复的重点就是保存这个密码的config.text文件。
switch:dir flash:
五、对保存密码的config.text文件执行文件名替换:
switch:rename flash:/config.text flash:/config.old
六、离开BOOT模式,启动交换设备:
switch:boot
七、交换设备启动后,进入交换机的特权模式,拷贝配置文件到内存中
switch# copy flash:config.old system:running-config
八、改变口令
switch#config terminal
switch(config)#enable password [密码]
九、保存配置:
switch#write mem
十、更改回/删除配置文件[可省略,因交换机配置就是从config.old拷贝出]
switch# rename flash:/config.old flash:/config.text
switch# delete flash:/config.old
PS: Cisco官方模拟器Packet Tracer(PT)目前暂时只能模拟路由器的密码恢复,没法模拟交换机的密码恢复。