-
Host key verification failed.
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ 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 a host key has just been changed.
The fingerprint for the ECDSA key sent by the remote host is
SHA256:----------------------------------------------------------------
Please contact your system administrator.
Add correct host key in /root/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /root/.ssh/known_hosts:2
remove with:
ssh-keygen -f "/root/.ssh/known_hosts" -R ------服务器地址------
ECDSA host key for -----服务器地址------ has changed and you have requested strict checking.
Host key verification failed.
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ 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 a host key has just been changed.
The fingerprint for the ECDSA key sent by the remote host is
SHA256:----------------------------------------------------------------
Please contact your system administrator.
Add correct host key in /root/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /root/.ssh/known_hosts:2
remove with:
ssh-keygen -f "/root/.ssh/known_hosts" -R ------服务器地址------
ECDSA host key for -----服务器地址------ has changed and you have requested strict checking.
Host key verification failed.
问题原因:
之前远程连过一次该服务器地址,之后因为其他原因重装了服务器系统(汗~~),再次重连就报错了。。。
网上查到的原因:
原因是在主机子系统每次成功ssh连接远程操作,都会把你每个你访问过计算机的公钥(public key)都记录在主机的目录/root/.ssh的known_hosts下,当下次访问相同子机服务器时,会核对公钥。如果公钥不同,会发出警告,避免你受到DNS Hijack之类的攻击。
ssh连接上,提示继续,输入yes,会把连接子机的RSA添加到主机known hosts下。
解决办法 :
删除已经保存的。
cd /root/.ssh
vi known_hosts
-
yum 安装jdk
查看:yum search java|grep jdk;
已安装的jdk:yum list installed |grep java;
安装1.8: yum -y install java-1.8.0-openjdk*
注:“”表示将java-1.8.0的所有相关Java程序都安装上。*
查看刚安装的Java版本信息。
输入:java -version 可查看Java版本;
输入:javac 可查看Java的编译器命令用法(可略)。