Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

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 router based on OpenWRT which has dnsmasq 2.59. Inside my local area network I have a NS server bind. This server has internal and external views for a couple of my domains. My router forwards port 53 TCP and UDP from outside IP (router WAN) to this server. For the external clients everything works fine.

In order to organize the internal view, I decided to add the exception to



( - IP address of the NS server)

According to dnsmasq manstrong text:

More specific domains take precendence over less specific domains, so: --server=/ --server=/ will send queries for * to, except *, which will go to

this domain name with all the sub-domains is supposed to be forward to my NS server.

Everything works (SOA, NS, MX, CNAME, TXT, SRV etc.) except for A-record:

# nslookup -type=a


*** Can't find No answer - IP address of my router (dnsmasq)

However, I can get the answer for the TXT-record query:

# nslookup -type=txt
Address:        text = "v=spf1 -all"

When I just specify the local IP of my NS server (direct access to the server without using dnsmasq) then the results are:

# nslookup -type=a



There is a similar situation with the MX-record:

C:\>nslookup -type=mx
Server:  router.lan
Address:         MX preference = 10, mail exchanger =         nameserver =   internet address =     internet address =

C:\>nslookup -type=a
Server:  router.lan

*** No address (A) records available for

This is a dig result:

# dig +nocmd any +multiline +noall +answer          86400 IN SOA (
                                121204007  ; serial
                                28800      ; refresh (8 hours)
                                7200       ; retry (2 hours)
                                604800     ; expire (1 week)
                                3600       ; minimum (1 hour)
                                )          86400 IN NS          86400 IN A          604800 IN MX 10          3600 IN TXT "v=spf1 -all"

When I try to ping:

# ping
ping: cannot resolve Unknown host

Is it a bug of dnsmasq 2.59? How to manage this problem?

share|improve this question

I ran into this issue myself recently.

Most likely you have rebind protection set to "on" in the config. If so, you should allow RFC1918 responses for that domain:


This fixed the issue for me. Hope it helps.

If not, take a look at the dnsmasq release notes, there were some regression bugs reported in versions 2.5x-2.6x. 2.62 and 2.65 seem the most stable (I use v62). Try to upgrade and see if it fixes the issue.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .