scp命令時提示WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!

來源:互聯網
上載者:User

今天用scp命令複製時,提示如下錯誤:
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@    WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!     @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
IT IS POSSIBLE THAT SOMEONE IS DOING SOMETHING NASTY!
Someone could be eavesdropping on you right now (man-in-the-middle attack)!
It is also possible that the RSA host key has just been changed.
The fingerprint for the RSA key sent by the remote host is
25:ab:2e:55:30:11:a0:84:d8:45:2f:5b:e2:47:eb:1e.
Please contact your system administrator.
Add correct host key in /root/.ssh/known_hosts to get rid of this message.
Offending key in /root/.ssh/known_hosts:1
RSA host key for 192.168.1.240 has changed and you have requested strict checking.
Host key verification failed.
lost connection

開始我以為是命令錯誤,仔細一看,原來是密鑰驗證錯誤,可能是我的帳號資訊做過更改。
 

找到該使用者家目錄下的如下的ssh串連檔案夾:
1. cd ~/.ssh/
2. vi known_hosts
3. 找到和遠程主機ip一致的密鑰儲存資訊,直接dd刪除,然後:x儲存退出
4. 重新串連,輸入密碼,發現串連成功

問題解決

本文出自 “原下” 部落格

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.