SSH connection loops back to host.

Issues related to configuring your network
Post Reply
JimJensen
Posts: 3
Joined: 2016/11/23 13:58:03

SSH connection loops back to host.

Post by JimJensen » 2016/11/23 14:09:14

CentOS release 6.8 (Final)
Kernel 2.6.32-642.11.1.el6.x86_64 on an x86_64

I have two internet IP addresses, each point to a different server. I am having an issue with SSH and Telnet for one of the IP addresses. I can ssh and telnet to xxx.xxx.xxx.188 just fine. When I ssh or telnet to xxx.xxx.xxx.185 I get a login prompt but it is for the host that I am connecting from. So in short the connection is getting looped back to itself. When I do a traceroute it shows that it is going to my router. I am completely stumped as to how this is happening and I have no idea what to change to make the connection go through. Is it something on the server or could it be something in the router?

User avatar
TrevorH
Site Admin
Posts: 33216
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: SSH connection loops back to host.

Post by TrevorH » 2016/11/23 15:04:01

Are you connecting by hostname or ip address?
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

JimJensen
Posts: 3
Joined: 2016/11/23 13:58:03

Re: SSH connection loops back to host.

Post by JimJensen » 2016/11/23 15:06:26

I've tried both ways, the ip address and the hostname from /etc/hosts.

User avatar
TrevorH
Site Admin
Posts: 33216
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: SSH connection loops back to host.

Post by TrevorH » 2016/11/23 15:09:54

And are the boxes you're connecting to directly on the internet or is there a firewall with port forwarding in front of them?
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

JimJensen
Posts: 3
Joined: 2016/11/23 13:58:03

Re: SSH connection loops back to host.

Post by JimJensen » 2016/11/23 15:17:29

Port forwarding. I know for sure that is isn't any thing on the router or the server as I have sixty+ other servers that I connect to these boxes. It is something on that server or something on the router where that server is. It is strange that one ip address works and the other won't.

User avatar
TrevorH
Site Admin
Posts: 33216
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: SSH connection loops back to host.

Post by TrevorH » 2016/11/23 15:35:34

It would be an easy explanation if the port forwarding was misconfigured and went to the wrong host...
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

Post Reply