Failing DNS resolution

My local sites have seemingly lost the ability to resolve DNS from with Docker. The first signs were when my local sites started running extremely slowly and then I observed error messages being displayed in the control panel, such as:

WP HTTP Error: cURL error 28: Resolving timed out after 10553 milliseconds

After a bunch of debugging and fiddling, I was able to put in a temporary workaround by SSH-ing in and editing the nameserver entry in /etc/resolv.conf file to point directly to my router instead of the default IP address. However, I understand this isn’t a permanent solution and I’d love to understand what could’ve caused this overnight change and how I can fix it properly. I’m running 2.0.6 on macOS Sierra.

Any assistance would be greatly appreciated

Hi Gary,

Sorry for the trouble!

Try going to Help » Restart Local’s Machine in Local. Sometimes VirtualBox’s network devices can get out of whack and simply restarting the machine will fix it.

Hi Clay.
I had previously attempted rebooting the entire host machine without success and unfortunately restarting the local VM hasn’t made any difference either.


In that case, this might be worth looking at:

The path to Local’s Docker Machine is ~/.docker/machine/machines/local-by-flywheel

Here’s another thing you can try:

  1. Power off local-by-flywheel in VirtualBox by going to Close » ACPI Shutdown
  2. Go to Preferences » Network » Host-only networks
  3. As long as your VMs are using Vagrant or Docker Machine (Local uses Docker Machine), you can safely remove all of the host-only networks
  4. Re-open Local

So I tried both options and sadly see no change.

Although editing config.json seemed like a promising solution, it’s not made any difference for any of my Local sites.
The only host-only network I have listed was “vboxnet0” - attempted to remove, but it’s regenerated whenever I restart the VM. I tried experimenting with changing the network adapters between NAT, bridged and host-only, but discovered that a host-only and NAT connections are both required in order to start or access the guest instance.

It’s still not obvious to me why this suddenly stopped working and the only functioning workaround is to edit the /etc/resolv.conf file