2017-06-16 102 views
0

直到最近,我才能SSH進入我的流浪漢機器沒有任何問題。但是現在:無法SSH進入流浪客戶

$ ssh -vvv [email protected] -p 2222 OpenSSH_7.2p2 Ubuntu-4ubuntu2.1, OpenSSL 1.0.2g 1 Mar 2016 debug1: Reading configuration data /etc/ssh/ssh_config debug1: /etc/ssh/ssh_config line 19: Applying options for * debug2: resolving "127.0.0.1" port 2222 debug2: ssh_connect_direct: needpriv 0 debug1: Connecting to 127.0.0.1 [127.0.0.1] port 2222. debug1: Connection established. debug1: key_load_public: No such file or directory debug1: identity file /home/user1/.ssh/id_rsa type -1 debug1: key_load_public: No such file or directory debug1: identity file /home/user1/.ssh/id_rsa-cert type -1 debug1: key_load_public: No such file or directory debug1: identity file /home/user1/.ssh/id_dsa type -1 debug1: key_load_public: No such file or directory debug1: identity file /home/user1/.ssh/id_dsa-cert type -1 debug1: key_load_public: No such file or directory debug1: identity file /home/user1/.ssh/id_ecdsa type -1 debug1: key_load_public: No such file or directory debug1: identity file /home/user1/.ssh/id_ecdsa-cert type -1 debug1: key_load_public: No such file or directory debug1: identity file /home/user1/.ssh/id_ed25519 type -1 debug1: key_load_public: No such file or directory debug1: identity file /home/user1/.ssh/id_ed25519-cert type -1 debug1: Enabling compatibility mode for protocol 2.0 debug1: Local version string SSH-2.0-OpenSSH_7.2p2 Ubuntu-4ubuntu2.1 ssh_exchange_identification: read: Connection reset by peer

我在來賓檢查/etc/hosts.allow/etc/hosts.deny。空空如也。我幾乎可以肯定,這與某人重寫/etc/resolv.conf的內容有關。現在的內容是: nameserver 8.8.8.8 nameserver 8.8.4.4 網絡似乎沒有問題,我可以ping通google.com,但不能在客戶端,我不能。但是,通往Vagrant機器的SSH不再有效。有任何想法嗎?

+0

你在服務器日誌中看到什麼錯誤? – Jakuje

+0

我不確定我在尋找合適的人。我做了'tail -f/var/log/audit/audit.log'和'tail -f/var/log/secure',但是當我嘗試SSH進入機器時什麼都看不到。 – Johnny

回答

0

答案並不是我所期望的。在VirtualBox設置>網絡>適配器1中,電纜連接選項被禁用。啓用後,一切恢復正常。