How to get my Public DNS (IPv4) of instance Amazon EC2

I launched a new instance in EC2 Management of amazon but this don't have the Public DNS (IPv4).

Can you tell me what I'm missing?

details

Upvotes: 5

Views: 8226

Answers (2)

Kumaresh Babu N S
Kumaresh Babu N S

Reputation: 1708

  • Get your VPC ID from your EC2 dashboard.
  • Go to VPC dashboard. Select your VPC with VPC ID.
  • Click on Actions and Select "Edit DNS Hostnames".
  • Select Yes and click Save.

Now you can find Public DNS IPv4 value in EC2 dashboard.

Upvotes: 8

Chris Rouffer
Chris Rouffer

Reputation: 763

When you create an EC2 instance you need to select "Public IP", otherwise it only adds a private IP address.

After creation, the only way add public IP address is to allocate and attach and "Elastic IP Address".

  1. Select the instance in the EC2 management console
  2. Click on the Actions->Networking menu
  3. Manage IP Addresses
  4. Allocate an Elastic IP, then attach it to your instance

If you delete your instance, don't forget to delete the Elastic IP as well. You are only charged for them when they are NOT attached to an instance.

Upvotes: 3

Related Questions