Session Manager for EC2 without internet access

0

I just created a EC2 inside a fully private VPC (without IGW, without NAT, no internet access at all), and follow the instructuion to create endpoints. As a test result, what I found is I can't connect to this EC2 using session manager via browser

Here's the link to the instructions I've followed,

https://aws.amazon.com/premiumsupport/knowledge-center/ec2-systems-manager-vpc-endpoints/

To verify and compare, then I just created 2 cloudformationized environment to make sure I am using same EC2 AMI, Same IAM Profile, Same endpoints and endpoint SG policy (allow all traffics), same VPC enableDNS settings, same ACL (allow all traffic). The only difference is one of the EC2 have outbound internet access.

The test result is:

Only EC2 have outbount internet access can be connected using session manager via browser.

Is that correct ?

AWS
Rachel
已提問 3 年前檢視次數 1678 次
1 個回答
0
已接受的答案

The EC2 Instance doesn't need to have outbound internet access (NAT or IGW).

I've had similar issues in the past, ensure you have all three service endpoints setup (Security Group & Subnet mappings):

  • com.amazonaws.[region].ssm
  • com.amazonaws.[region].ssmmessages
  • com.amazonaws.[region].ec2messages

Security Group for the Endpoints should allow HTTPS access from your VPC range (or narrowed down), and if you've modified the outbound rules on your Instance's Security Group - verify that too.

For completeness: issue was missing of Private DNS for Endpoints.

        PrivateDnsEnabled: True
AWS
專家
Raphael
已回答 3 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南