EC2 Instances not reachable from Internet

0

When I create EC2 instances they are not accessible from the internet. This happens with the default VPC and a custom VPC I created. I have an internet gateway in the VPCs this has been tried in. I get a public IP address assigned to the instance. The route table and the security policy allow all traffic and the gateway is mapped in the route table as well. These are common instances such as the amazon linux and ubuntu instances.

I thought maybe my VPC was the issue, but the Default VPC should work by default, is that a correct assumption?

질문됨 9달 전245회 조회
3개 답변
0
수락된 답변

The Default VPC Security group only allows access from its self. You will need to update the appriopiate security group to allow inbound traffic to the port in question from the CIDR you require.

If you could share more details about your security groups etc, this would help

Thanks

profile picture
전문가
답변함 9달 전
profile picture
전문가
검토됨 9달 전
  • That was what confused me. I thought that the default security policy already allowed traffic in. Everyone shows EC2 instance creation, but it wasn't clear to me how that Security Group worked. That was definitely my issue. Thank you for the help.

0

Please use the VPC Reachability Analyzer to troubleshoot this issue.

profile pictureAWS
전문가
kentrad
답변함 9달 전
  • For some reason we can't seem to get that working. It gives me an access denied.

0

Default VPC sg is Literally Default VPC sg. AWS best practice is make custom sg for each workload environment and required policy. When you make sg with right policy for your situation (for example allow specific source IP/Any IP with specific destination service port to reach your instances)than put this on your instance.

V
답변함 9달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠