Jump to Navigation

214 - Reverse mapping on ssh

If you connect a server with ssh, you get an error message sometimes.

# ssh

reverse mapping checking getaddrinfo for failed - POSSIBLE BREAK-IN ATTEMPT!
Last login: Wed Jan 25 09:20:51 2012 from

What this is telling us is that although we are connecting to my.example.com the IP address of the server we are connecting to actually maps back to 192-168-1-200.my.example.us in this example. When this actually happened to me, it's because the reverse DNS had not been set up for the server
(which would map e.g. to my.example.com as well as vice versa).

* Hosts file solution

If you knew this reverse mapping was OK, you can add an entry to your hosts file and it will stop the error message from happening.
For the above example, you would add the following to my hosts file:

# vi /etc/hosts  my.example.com

When you log in using SSH from the command line, you won't get that error message any more.



Main menu 2

Story | by Dr. Radut