在Ubuntu中配置SSH(解决connecttohostlocalhostport22:。
。。
成功地装ssh需要三步。
下载并安装第⼀个⽂件
hadoopr@ubuntu:~/Downloads$ sudo dpkg -i openssh-client_5.3p1-3ubuntu3_i386.deb
dpkg: warning: downgrading openssh-client from 1:5.3p1-3ubuntu5 to 1:5.3p1-3ubuntu3.
(Reading database ... 127436 files and directories currently installed.)
Preparing to replace openssh-client 1:5.3p1-3ubuntu5 (using openssh-client_5.3p1-3ubuntu3_i386.deb) ...
Unpacking replacement openssh-client ...
Setting up openssh-client (1:5.3p1-3ubuntu3) ...
Processing triggers for man-db ...
下载并安装第⼆个⽂件
hadoopr@ubuntu:~/Downloads$ sudo dpkg -i openssh-server_5.3p1-3ubuntu3_i386.deb
Selecting previously deselected package openssh-server.
(Reading database ... 127436 files and directories currently installed.)
Unpacking openssh-server (from openssh-server_5.3p1-3ubuntu3_i386.deb) ...
Setting up openssh-server (1:5.3p1-3ubuntu3) ...
Creating SSH2 RSA key; this may take some time ...
Creating SSH2 DSA key; this may take some time ...
* Stopping OpenBSD Secure Shell server sshd                                                              [ OK ]
ssh start/running, process 3822
Processing triggers for ureadahead ...
ureadahead will be reprofiled on next reboot
Processing triggers for ufw ...
Processing triggers for man-db ...
下载并安装第三个⽂件
hadoopr@ubuntu:~/Downloads$ sudo dpkg -i ssh_5.3p1-3ubuntu3_all.deb
(Reading database ... 127454 files and directories currently installed.)
connect下载Preparing to replace ssh 1:5.3p1-3ubuntu3 (using ssh_5.3p1-3ubuntu3_all.deb) ...
Unpacking replacement ssh ...
Setting up ssh (1:5.3p1-3ubuntu3) ...
最后试了试,成功。
hadoopr@ubuntu:~/Downloads$ ssh localhost
The authenticity of host 'localhost (::1)' can't be established.
RSA key fingerprint is 0f:f5:b7:32:06:a3:3c:4c:de:fb:04:aa:8a:f2:2d:ee.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'localhost' (RSA) to the list of known hosts.

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。