Linux连接出现Permission denied (publickey,gssapi-with-mic,password

新建的机器或者利旧的机器,当再次连接旧机器时出现以下报错:

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@ 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 ED25519 key sent by the remote host is
SHA256:4O6iAvpvwuiVEXtbSeJFSZdBoxMs01kkzEhZzqyCmXM.
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:8587
Password authentication is disabled to avoid man-in-the-middle attacks.
Keyboard-interactive authentication is disabled to avoid man-in-the-middle attacks.
UpdateHostkeys is disabled because the host key is not trusted.
Authorized users only. All activity may be monitored and reported
root@10.159.115.65: Permission denied (publickey,gssapi-with-mic,password).
[root@hncs-it-ansible01 cloudman]# ssh-keygen -R 10.159.115.65
# Host 10.159.115.65 found: line 3412
# Host 10.159.115.65 found: line 8587
/root/.ssh/known_hosts updated.
Original contents retained as /root/.ssh/known_hosts.old

 

解决方案:重新认证

ssh-keygen -R +输入服务器的IP

posted @ 2022-09-17 14:43  LB_运维技术  阅读(1194)  评论(0编辑  收藏  举报