0

I recently cloned two AWS CentOS 7 instances from a physical server. From the first AWS instance, I can telnet on port 22 to the second AWS instance. From the second AWS instance, I cannot telnet to the first AWS instance.

[root@secondservername etc]# telnet 10.xxx.yyy.zzz 22 Trying 10.xxx.yyy.zzz...

The iptables firewalls are accepting INPUT, FORWARDING, OUTPUT on both instances. There is no /etc/host.deny configs. There are no TCP wrappers. The identical security group allowing port 22 access for anything is in place. /etc/ssh/sshd_config Allow root access Yes is in place and the problem persists with non-root users.

These instances are exact copies of the original bare-metal server.

I was wondering if there were any thoughts on this?

1
  • Does one of them keep the original IP while the other has the IP changed? There is no iptables rules at all? and no rules in AWS? what about the routing table? Have you tried to see what happens with the packets using tcpdump? This question lacks much of the information that is needed to be able to answer.
    – NiKiZe
    Aug 16, 2021 at 15:06

1 Answer 1

0

The issue here was human error. In creating the instance, should have selected identical subnets, for simplicity. There is a "bad" subnet and a "good" subnet in the availability zone here. The one is bad in the sense that there is an upstream acl that interferes with anything port 22. I am not in the mood to change the acl, but i was able to build a second instance with the identical subnet, identical availability zone and ssh works now bi-directionally. A team built the vpc in question here and it's easier to do it this way.

As FYI, ssh is needed for autossh, a feature of mysql, to allow for replication and other database issues.

As always, thanks for your help, it got me thinking.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .