Login

Navigation

This articles is published 953 days ago and last updated 399 days ago, some information may be out of date.

Cisco Device Enable SSH login

image-20210917090352670.png

設定特權(enable)模式密碼

(Config)#enable secret ccna
開啟vty登入需先設定登入enable模式密碼,否則登入後將無法進入enable模式

設定本機帳號

(config)#username cisco secret ccna
建立帳號 cisco 密碼 nnca

secret 代表密碼加密

產生加密key

(config)#ip domain-name ccna.com
設定domain-nameccna
(config)#crypto key generate rsa
產生rsa金鑰

How many bit in the modulus[512]:1024

使用 1024 bit加密(預設512)

啟用SSH連線

(config)#ip ssh version 2
使用ssh v2協定
(config)#line vty 0 4
開啟0~4vty連線(即最大連線人數5人)
(config-line)#login local
啟用密碼(login)及帳號(local)
(config-line)#transport input ssh
啟用ssh
end
copy running-config startup-config
返回及存檔

測試SSH連線

 #ssh -l cisco 10.255.255.254
另一Cisco裝置測試登入

10.255.255.254 是路由器IP地址

image-20210917075953454.png

或者使用Windows SSH 終端機


參考資料:


站內相關貼文: