1: 輸入hostname, username 后連接提示: ubuntu The remote system refused the connection.
因為沒有安裝或啟動 ssh. 使用命令 su root 切換至root用戶. 使用命令 ps -e | grep ssh 查看是否啟動 ssh.
如沒有返回 則嘗試使用命令 sudo apt install openssh-server 嘗試安裝ssh.
如提示已安裝, 使用命令 /etc/init.d/ssh start 啟動ssh服務. 再次嘗試連接
//相關命令 停止服務/etc/init.d/ssh stop 重啟服務/etc/init.d/ssh restart
2: could not load host key.
查了下大概是因為鑒證證書的問題 使用命令 ssh-keygen -A 生成key
3: a public key file has not been specified for this session would you like to specify one now
在SecureCRT sessions > properties > Connection > SSH2 取消勾選 PublicKey.

4: Reason: Unable to authenticate using any of the configured authentication methods.
修改sshd_config配置信息 vim /etc/ssh/sshd_config 配置項 PasswordAuthentication 值no改為yes 修改后 使用命令 /etc/init.d/ssh restart 重啟ssh服務.
附上 vim基本命令.
ESC 退出編輯模式. :w 保存文件但不退出vi
:w! 強制保存,不退出vi :wq 保存文件並退出vi
:wq! 強制保存文件並退出vi :q 不保存文件 退出vi
:q! 不保存文件 強制退出vi
5: The server has disconnected with an error. Server message reads: A protocol error occurred. Change of username or service not allowed: (root,ssh-connection) -> (xxxxxx,ssh-connection)
因為SecureCRT設置的用戶名和登錄時輸入的用戶名不一致,在SecureCRT sessions > properties > Connection > SSH2 username 修改一致即可.
到此為止, 終於連接成功了. 學習的過程中有問題要擅於使用搜索引擎. windows10 內置的ubuntu問題太多,已放棄, 改用redhat7.6