SSH远程无密码登录设置出现问题Host key verification failed.
本帖最后由 lina791211 于 2012-09-26 15:55:14 编辑 百度不给力,图传不了
现在连接一下百度知道地址:
http://zhidao.baidu.com/question/480818499.html?oldq=1
做Hadoop部署,我先以一个临时用户安装了虚拟机,然后使用root权限建立一个用户名为hadoop的用户,权限如下:
hadoop@master:/home$ ll
总用量 16
drwxr-xr-x 4 root root 4096 9月 26 14:02 ./
drwxr-xr-x 23 root root 4096 9月 24 15:05 ../
drwxr-xr-x 28 hadoop hadoop 4096 9月 26 14:08 hadoop/
drwxr-xr-x 21 snowfigure snowfigure 4096 9月 24 16:47 snowfigure/
hadoop@master:/home$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/hadoop/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/hadoop/.ssh/id_rsa.
Your public key has been saved in /home/hadoop/.ssh/id_rsa.pub.
The key fingerprint is:
f9:3c:8c:79:28:69:a0:9a:cc:aa:d5:9a:e8:16:76:56 hadoop@master
The key's randomart image is:
+--[ RSA 2048]----+
| |
| |
| |
| E . |
| o S |
| o = . . B |
|. * . + + * |
|o* o . . . . |
|@+o |
+-----------------+
hadoop@master:/home$ cd /home/hadoop
hadoop@master:~$ ll .ssh/
总用量 16
drwx------ 2 hadoop hadoop 4096 9月 26 15:41 ./
drwxr-xr-x 28 hadoop hadoop 4096 9月 26 14:08 ../
-rw------- 1 hadoop hadoop 1675 9月 26 15:41 id_rsa
-rw-r--r-- 1 hadoop hadoop 395 9月 26 15:41 id_rsa.pub
hadoop@master:~$ cd /home/hadoop/.ssh/
hadoop@master:~/.ssh$ cp id_rsa.pub authorized_keys
hadoop@master:~/.ssh$ ll
总用量 20
drwx------ 2 hadoop hadoop 4096 9月 26 15:44 ./
drwxr-xr-x 28 hadoop hadoop 4096 9月 26 14:08 ../
-rw-r--r-- 1 hadoop hadoop 395 9月 26 15:44 authorized_keys
-rw------- 1 hadoop hadoop 1675 9月 26 15:41 id_rsa
-rw-r--r-- 1 hadoop hadoop 395 9月 26 15:41 id_rsa.pub
hadoop@master:~/.ssh$ ssh localhost
The authenticity of host 'localhost (127.0.0.1)' can't be established.
ECDSA key fingerprint is 39:ea:53:cb:e9:84:51:08:da:dc:59:e5:d8:98:f1:a7.
Are you sure you want to continue connecting (yes/no)?
Host key verification failed.
hadoop@master:~/.ssh$