Best practice to SSH to multiple EC2 instances

0

What is the best way to manage sessions to multiple EC2 instances with dynamic IP addresses? I occasionally stop the instances and therefore, the IP changes. I don't want to have to update the IP every time I connect. Elastic IPs give a static IP, but there is a limit of 5 per account and doesn't seem like the right solution. How can I efficiently work on these instances daily (such as a SSH connection manager) without the hassle of constantly updating the IP addresses?

EP79932
asked 8 months ago244 views
3 Answers
4

With EC2 Instance Connect Endpoint(EIC), this ask has been quite simpler, here is detailed step by step guide in this blog post. Definitely session manager is also an option.

profile pictureAWS
EXPERT
answered 8 months ago
profile picture
EXPERT
reviewed 8 months ago
profile pictureAWS
EXPERT
iBehr
reviewed 8 months ago
2

Hello.
How about using Systems Manager's Session Manager instead of SSH?
If your OS can use Session Manager, you can use it by setting up an IAM role on EC2.
https://docs.aws.amazon.com/systems-manager/latest/userguide/session-manager.html

Other methods, such as EC2 Instance Connect Endpoint, make it possible to use EC2 without worrying about its public IP address.
https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/connect-with-ec2-instance-connect-endpoint.html

profile picture
EXPERT
answered 8 months ago
profile picture
EXPERT
reviewed 8 months ago
  • Thanks...I'll look in to Session Manager. I basically want to be able to easily pop in and out of instances all day with the least amount of hassle.

  • Session Manager or EC2 Instance Connect Endpoint can be used to connect without worrying about IP addresses.

0
profile picture
answered 8 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions