An error occurred during remote ssh: Host key verification failed.

When remotely connecting to the local server of gitlab, the following error is reported

zhang@zhang:~$ ssh [email protected]
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@    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:myLJF20nDSLYg0yhDG3VWAQPLiOzT4V7J6jLKNAOD1A.
Please contact your system administrator.
Add correct host key in /home/zhang/.ssh/known_hosts to get rid of this message.
Offending ECDSA key in /home/zhang/.ssh/known_hosts:6
  remove with:
  ssh-keygen -f "/home/zhang/.ssh/known_hosts" -R "192.168.50.188"
ECDSA host key for 192.168.50.188 has changed and you have requested strict checking.
Host key verification failed.

Execute the following command

zhang@zhang:~$ ssh-keygen -R 192.168.50.188

-R is followed by the remote IP. You can log in again after execution.

Guess you like

Origin blog.csdn.net/JosephThatwho/article/details/104353052