So you have created a VPC and your EC2 instance is ready.. (here I am assuming we haven't configured public IP, while creating EC2 instance).
Let us now allocate an Elastic IP address to our AWS account from the Amazon's reserved public IP range.
This can be done by Services >> EC2 >> Scroll down the left navigation pane and under Network & Security, click on Elastic IPs. Click on the Allocate Elastic IP address button
Once this IP address is allocated, select the Elastic IP, click on Actions and click on "Associate Elastic IP address", as below:
This would bring up the below page which gives an option to select the EC2 instance which this Elastic IP needs to be allocated to. [I have erased my Elastic IP address and the Instance ID]
And that should be it.
There is a catch here, however! The above process won't work if there is no Internet Gateway associated with your VPC. So make sure that you have one. To create an Internet Gateway, check here.
Comments
Post a Comment