Fix the Error Warning Remote Host Identification Has Changed in Mac in very easy steps. You can face it in Cloud Servers if Key has changed. We have emulated the error and created an easy guide so that you solve it in very easy steps. Fix for linux is kind of same, except the fact – you can not open the known hosts file in Graphical interface in all distro. In that case, you need to open it with nano or vim text editor in command line. There is absolutely no meaning of working from command line like a blind and delete using the normally advised method.
Fix Warning Remote Host Identification Has Changed : The Reason Behind
Your own server (usually cloud server) is warning and labeling you as Man-in-the-Middle Attack (MITMA)? Actually if you not done anything – like building the image or accidental partial deletion of the known hosts file (or the Key associated with the IP), you must contact web host. Here is a video :
Steps to Fix Warning Remote Host Identification Has Changed
Here is a screen shot too to fix the Warning Remote Host Identification Has Changed :
---
Basic steps are quite easy. Simply copy the $path of known_hosts which you’ll get in the error output on Terminal app or iTerm2. If you do no get the path, it should be
1 2 | /Users/your-username/.ssh/known_hosts # change your-username |
Right click on Finder and click the “Go to Folder” option. The .ssh folder will open. Copy the known_hosts as backup (not shown on video) on desktop (open a new Tab on OS X 10.9 upwards with command + T for easy to work). Right click on the known_hosts file and open it with TextEdit. Find the IP address and delete the whole line – it is visually understandable where the key starts and ends with normal intelligence.
Less is more. There is no meaning of editing from command line when we can see things visually, that way is for server, where no GUI is available :
1 | ssh-keygen -R {ssh.server.ip.address} |