The ECDSA host key has changed

Hi, I'm very new to this and hoping someone can help.

whilst I was trying to figure out how to create an ssl certificate mostly from forum posts online. I ended up adding a stackscript? which I guess replaced my Ubuntu 16.04 disk. Anyway long story short, I messed up and decided to start again.

I deleted the Linode and created a new one, but this time as I tried to connect to the linode from the terminal I received this message;

WARNING: POSSIBLE DNS SPOOFING DETECTED!

The ECDSA host key for znode1 has changed,

and the key for the corresponding IP address . is unchanged. This could either mean that

DNS SPOOFING is happening or the IP address for the host

and its host key have changed at the same time.

Offending key for IP in /Users/endaksi1/.ssh/known_hosts:3

I'm not quite sure how to fix this, any help would be much appreciated.

1 Reply

If you delete a server and recreate it, the new server will auto-generate new ssh keys.

The above error appears, because your desktop system still has the old server ssh pub key in the known_hosts file, which conflicts because the old and the new server have the same name (or are being accessed via the same name/domain).

The solution, is to delete the old pub key from the known_hosts and let your ssh client grab the new key from the new server.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct