I have given a limited access to a AWS account.
I already created an EC2 instance but when I try to associate an elastic ip, I got the error below:
An error occurred while attempting to associate the address
Network vpc-(security id) is not attached to any internet gateway
You are using the new Amazon Virtual Private Cloud instead of the EC2 Classic. The cloud you are using lacks the internet gateway virtual component that is necessary for the cloud to be reachable from the public internet.
You need to add an internet gateway to your private cloud for it to be able to connect to internet; with that in place, you can use Elastic IPs (after all, they are internet addressable; your VPC instances can have static instance IPs), and add a routing entry for internet addresses (0.0.0.0/0, or a narrower space).
来源:https://stackoverflow.com/questions/28778970/aws-elastic-ip-network-vpc-is-not-attached-to-any-internet-gateway