Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have booted up an instance in side a private VPC. I assigned an ElasticIp address to it and I can ssh into the instance with no issues. However, DNS is not resolving :(

in my /etc/resolv.conf I have

domain eu-west-1.compute.internal
search eu-west-1.compute.internal

but when I try and ping I get

icmp_seq=156 Destination Net Unreachable

Which makes sense as I have no route to that private subnet. I can ping any external ip address i.e


but I cannot


I created the VPC using the wizard I assume that the VPC is assigning the /etc/resolv.conf settings.

and the documentation says I should have external dns access, but I don't.

Can anyone help?

share|improve this question
Is that the real IP of the external DNS server you're trying to use? – EEAA Jan 16 '13 at 18:19
yes it is. It works when I use a normal aws instance. i.e not in the VPC – Alistair Prestidge Jan 17 '13 at 21:03

In the VPC Service control panel you can create DHCP Options Sets. Create one of those with the nameservers you want to use.

Then, under "Your VPCs", change the DHCP Options Set in use by your VPC to be the new one you just created.

If you are going to have more than a few servers in your VPC, you might want to consider running your own internal caching DNS resolver.

share|improve this answer
Can I not use the default DNS server that AWS has assigned? do I have to use one I define? – Alistair Prestidge Jan 16 '13 at 17:19
I tried your suggestion of creating my own DHCP options but for some reason they are not being used nothing updates in /etc/resolve.conf and I still cannot ping a domain name – Alistair Prestidge Jan 17 '13 at 21:33
run your own DNS – Skaperen Mar 30 '15 at 10:28
up vote -1 down vote accepted

So it turns out it was something to do with AMI I was using. For some reason I could not get it to update the DNS servers.

I tried 3 other public AMI's and it worked fine on boot with no issues. It picked up the settings I defined in the DHCP settings.

So the answer here is just not to use that AMI in VPC.

share|improve this answer
the generic AMIs are fine in a VPC – Skaperen Mar 30 '15 at 10:29
I was not using a "generic" AMI. What ever that means. – Alistair Prestidge Apr 7 '15 at 10:45

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.