question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

dnsmasq doesn't resolve 127.0.0.1

See original GitHub issue

I followed the instructions to set up dnsmasq. As soon as I reach this step, I lose access to the internet:

sudo networksetup -setdnsservers "Wi-Fi" 127.0.0.1

I tried clearing my DNS cache but that did not work. I’m running OS X El Capitan.

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:13 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
fzagarzazucommented, Aug 11, 2016

The problem for me was this line in the configuration file:

conf-file=%%PREFIX%%/share/dnsmasq/trust-anchors.conf

There is no such file.

I commented it out and put the trusted-anchor setting instead (see README).

Note: trust anchor: https://data.iana.org/root-anchors/root-anchors.xml

Instructions:

To configure dnsmasq, copy the example configuration to /usr/local/etc/dnsmasq.conf and edit to taste.

cp /usr/local/opt/dnsmasq/dnsmasq.conf.example /usr/local/etc/dnsmasq.conf

To have launchd start dnsmasq now and restart at startup: sudo brew services start dnsmasq

Note: requires sudo.

It copies the file, but check the permissions, execute the following command to change it: sudo chmod 0644 /Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist

You may want to update the documentation. Thanks for maintaining the page.

Hope this helps.

0reactions
rishadfbcommented, Oct 31, 2015

I reinstalled dnsmasq and followed the steps again. It worked fine this time. I don’t know why that is! Thank you for your help!

Read more comments on GitHub >

github_iconTop Results From Across the Web

dnsmasq not working to point .local addresses to 127.0.0.1
local seem to be some kind of reserved keyword, at least on Ubuntu: address=/local/127.0.0.1 -- doesn't work. address=/loc/127.0.0.1 -- works.
Read more >
Dnsmasq resolves local hostname to 127.0.0.1 all over the net
dnsmasq can resolve its own hostname by disabling reading from /etc/hosts and configuring another config file for reading the hostnames including itself.
Read more >
Trying to resolve .local to 127.0.0.1 using dnsmasq and ...
I think NetworkManager is behaving as expected. NetworkManager is presumably starting a DNSmasq instance and setting your machine to use ...
Read more >
My computer resolves itself to 127.0.0.1 instead of its outer ip
I recently installed dnsmasq in two of my machines. The service works all right but the trouble is that when consulted they return...
Read more >
[Dnsmasq-discuss] Problem with server=/local/127.0.0.1
In my dnsmasq.conf "server=/local/127.0.0.1" doesn't seem to work. > > > At least, it doesn't work how I thought it was supposed to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found