原创:厦门微思网络

用户通过Console口登录设备时,如果遗忘了Console口的登录密码,则无法登录设备。此时,可以通过BootLoader菜单清除Console口的用户登录密码。如图1所示,用户PC的串口与设备的Console口已连接,设备已上电。

【技术分享】华为交换机忘记密码怎么恢复?_重启

图1 通过Console口连接设备组网图


操作步骤

1、重启设备。在设备启动过程中,当界面出现Press Ctrl+B to enter BOOT menu提示信息时,请三秒内按下快捷键“Ctrl+B”进入BootLoader主菜单。

Press Ctrl+B to enter BOOT menu: 3
Info: The password is empty. For security purposes, change the password.

New password:
Confirm password:
Warning: The bootloader password will be written to the device.
Continue now? Yes(y) or No(n): y


The password is changed successfully.

       Main Menu                                                              

   1. Default startup                                                          

   2. Serial submenu                                                            

   3. Ethernet submenu                                                        

   4. Startup parameters submenu                                              

   5. List file                                                                

   6. Password manager submenu                                                  

   7. DFX submenu                                                            

   8. Reboot      

Enter your choice(1-8):


2、在BootLoader主菜单中,输入“6”,进入“Password manager submenu”密码管理子菜单。

       Main Menu                                                                

   1. Default startup                                                          

   2. Serial submenu                                                                

   3. Ethernet submenu                                                          

   4. Startup parameters submenu                                                

   5. List file                                                                

   6. Password manager submenu                                                  

   7. DFX submenu                                                              

   8. Reboot      

Enter your choice(1-8): 6 

       Password manager submenu                                                

   1. Modify bootloader password                                                

   2. Clear the console login password

   3. Reset bootloader password                                                

   0. Return                                                                    

Enter your choice(0-3):

3、在密码管理子菜单中,输入“2”,进入“Clear the console login password”清空Console口登录密码菜单。

       Password manager submenu

    1. Modify bootloader password

    2. Clear the console login password

    3. Reset bootloader password

    0. Return

Enter your choice(0-3): 2

Caution: A new console password must be set after the restart.

Continue now? Yes(y) or No(n):

4、在清空Console口登录密码菜单中,输入“y”后,让设备继续启动。

Caution: A new console password must be set after the restart.

Continue now? Yes(y) or No(n): y

Password:     //输入BootLoader密码,然后按Enter键让设备继续启动


5、设备启动后,请在登录后重新设置Console口密码。

<HUAWEI> system-view

[HUAWEI] user-interface console 0

[HUAWEI-ui-console0] authentication-mode password

[HUAWEI-ui-console0] set authentication password

Please configure the login password (8-16)              

Enter Password:       //输入新密码

Confirm Password:     //输入新密码

[HUAWEI-ui-console0] return


6.为了防止重启后配置丢失,请保存配置。

<HUAWEI> save

Warning: The current configuration will be written to the device. Continue? [Y/N]:y 

Now saving the current configuration to the slot 1

Info: Save the configuration successfully.

检查配置结果

配置完成后,后续用户通过Console口登录设备时可以使用新密码登录。