0
votes

I'm new to EC2 and I'm trying to setup an elasticsearch cluster. So far, I've been having trouble with discovery, so I want to get to the root problem by understanding how to telnet between two EC2 instances.

  • I have two t.micro instances setup
  • Both use the same security group called "elastic"
9300         sg-3bc28e0b (elastic)    
22 (SSH)     0.0.0.0/0
23 (TELNET)  0.0.0.0/0
9200         0.0.0.0/0
  • I installed telnet on both servers

When i try and telnet from one box to the other using the private IP, or public DNS I get "Connection refused"

When I'm on one EC2 instance, I've tried telnetting to the other by:

  • telnet 10.xxx.65.xxx 9300
  • telnet ec2-50-xxx-xx-127.us-west-2.compute.amazonaws.com 9300

Nothing works. What am i doing wrong? If I can't telnet from one box to the other, my understanding is that I'm not likely to have success with elasticsearch discover (which I haven't had with two other instances I setup and have since terminated).

1
Telnet port does not need to be open since you are not connecting on the telnet port. Make sure a service is running and listening on that port and that you have no software firewall installed on the instance that might be blocking connections.datasage

1 Answers

0
votes

Open 9300 port for the security group where two instances are run (Even if same security group for both !!!)

Use Group ID value. For instance sg-18e1f37a