使用樹莓派時遇到的些許問題

好久沒上博客了,最近由於使用樹莓派,就在網上買了一塊樹莓派3b的板子來折騰,在這個過程中,遇到了一些問題,這些問題既浪費時間又不是啥技術問題,很是浪費時間,所以我在這裏貼出我遇到的這幾個問題,希望能給有需要的朋友提供些許便利。

1、打開putty出現的問題

raspbery pi 連接putty出現:connect refused or connect time out.
首先打開sudo raspi-config 出現interfacing Options 選擇Select 然後OK就行了.

the server's host key is not cached in the registry. You have no guarantee the server is the computer you think it is.
 the server's ras2 key fingerprint is: ssh-ras 2048 84:63:05:1b:f0:89:4e:7c:9a:9b:74:9a:f9:d5:f6 if you trrust this host, hit yes to add the key to PuTT's cache and carry on connecting. If you want to carry on connecting just once, without adding the key to the cache, hit NO. If you do not trust this host, hit Cancel to abandon the connection.

2、raspberry pi 連接SSH Secure shell 出現的問題
Server rasponeded "Algorithm negotiation failed".
Key exchange with the remote host failed. This can happen for example. if the remote host computer does not support the selected algorithms.
服務器增加了“算法協商失敗”。
與遠程主機的密鑰交換失敗。 例如,這可能發生。 如果遠程主機不支持所選算法。

解決辦法:
 在raspberry pi 中通過 sudo vim /etc/ssh/sshd_config 打開sshd_config配置文件,添加以下各個系統的密匙算法:
Ciphers aes128-cbc,aes192-cbc,aes256-cbc,aes128-ctr,aes192-ctr,aes256-ctr,3des-cbc,arcfour128,arcfour256,arcfour,blowfish-cbc,cast128-cbc

MACs hmac-md5,hmac-sha1,[email protected],hmac-ripemd160,hmac-sha1-96,hmac-md5-96

KexAlgorithms diffie-hellman-group1-sha1,diffie-hellman-group14-sha1,diffie-hellman-group-exchange-sha1,diffie-hellman-group-exchange-sha256,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group1-sha1,[email protected]

重啓sshd服務後,可正常連接。
重啓命令:sudo service ssh restart

3、再次登錄SSH Service shell時(已更改配置文件sshd_config)後,出現you are connecting to the host "172.20.10.4" for the first time. The host has provided you its identification, a host public key.
The fingerprint of the host public key is:
"xefer-fakab-rofot-bumup-ranar-dinir-nirih-zygub-pefav-fuzik-raxy

You can save th host key to the local database by clicking Yes.You can continue without saving the host key by clicking No.You can also cancel the connection by clicking Cancle.
Do you want to save the new host key to the local database?

解決辦法:將主機的公鑰的指紋記錄下來保存就OK了。這是sshd_config中你更改後的密匙算法爲你分配的指紋(據我推測,不太確定哦)。

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章