華為交換機開啟SSH服務


1、創建本地密鑰對

[Core-SW]rsa local-key-pair create
The key name will be: Core-SW_Host
The range of public key size is (512 ~ 2048).
NOTES: If the key modulus is greater than 512,
it will take a few minutes.
Input the bits in the modulus[default = 2048]:
Generating keys…
…+++++
…++
…++++
…++

2、檢查是否存在SSH user(可跳過),系統提示沒有SSH user 存在

[Core-SW]dis ssh user-information
Info: No SSH user exists.

3、創建SSH user

[Core-SW]ssh user test \可以直接敲第二行命令
[Core-SW]ssh user test authentication-type password \認證模式為密碼認證
[Core-SW]ssh user test service-type stelnet \服務類型為stelnet,即SSH

4、創建用戶

[Core-SW]aaa
[Core-SW-aaa]local-user test password cipher xxx(xxx處為你想要設置的密碼)
Info: Add a new user.
[Core-SW-aaa]local-user test privilege level 3 \用戶level最高到15
[Core-SW-aaa]local-user test service-type ?
8021x 802.1x user
bind Bind authentication user
ftp FTP user
http Http user
ppp PPP user
ssh SSH user
telnet Telnet user
terminal Terminal user
web Web authentication user
x25-pad X25-pad user
[Core-SW-aaa]local-user test service-type ssh \開啟該用戶允許使用SSH訪問設備的權限

5、啟用SSH(stelnet)服務

[Core-SW]stelnet server enable
Info: Succeeded in starting the Stelnet server.

6、配置vty界面支持的登錄協議

[Core-SW]user-interface vty 0 4
[Core-SW-ui-vty0-4]authentication-mode aaa
[Core-SW-ui-vty0-4]protocol inbound ssh

本文來自51CTO博客作者舞文潑墨的原創作品


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM