[Dnsmasq-discuss] logs question about <NODATA>-IPv4
Simon Kelley
simon@thekelleys.org.uk
Thu, 26 May 2005 12:25:39 +0100
Javi wrote:
> Hi,
>
> I'm using dnsmasq as a dns cache in a debian woody box, my version is:
>
> /usr/local/sbin/dnsmasq -v
> Dnsmasq version 2.20 Copyright (C) 2000-2005 Simon Kelley
>
> I notice some problems with postfix like these:
>
> Recipient address rejected: Domain not found; from=<XXXX>
> to=<ventas@bora-bora.es>
>
> so i take a look at my dnsmasq logs and....
>
> I supose this is the god behaviour:
>
> May 26 12:50:17 nesta dnsmasq[16418]: query bora-bora.es[MX]
> from 127.0.0.1
> May 26 12:50:17 nesta dnsmasq[16418]: forwarded bora-bora.es to
> 194.224.52.36
> May 26 12:50:17 nesta dnsmasq[16418]: query filtre.pimec.net[A]
> from 127.0.0.1
> May 26 12:50:17 nesta dnsmasq[16418]: forwarded filtre.pimec.net
> to 194.224.52.36
>
> But i don't know what this exactly mean:
>
> May 26 12:37:34 nesta dnsmasq[16418]: query bora-bora.es[A] from 127.0.0.1
> May 26 12:37:34 nesta dnsmasq[16418]: cached bora-bora.es is <NODATA>-IPv4
>
> May 26 12:50:06 nesta dnsmasq[16418]: query bora-bora.es[MX] from 127.0.0.1
> May 26 12:50:06 nesta dnsmasq[16418]: forwarded bora-bora.es to
> 194.224.52.36
> May 26 12:50:06 nesta dnsmasq[16418]: forwarded bora-bora.es to
> 194.224.52.37
> May 26 12:50:17 nesta dnsmasq[16418]: query bora-bora.es[A] from 127.0.0.1
> May 26 12:50:17 nesta dnsmasq[16418]: forwarded bora-bora.es to
> 194.224.52.36
> May 26 12:50:17 nesta dnsmasq[16418]: reply bora-bora.es is <NODATA>-IPv4
> May 26 12:50:17 nesta dnsmasq[16418]: query bora-bora.es[MX] from 127.0.0.1
>
>
> What means the <NODATA> message? i see that is cached as a response to
> bora-bora.es... so that means that i send a bad ip to my dns
> clients???
> My be it's something wrong with the dns i use to forward my queries?
NODATA means that the domain exists, but there's no information of the
specified type (in this case A records) associated with that domain. If
the domain itself doesn't exist, you would see NXDOMAIN instead.
For you domain, this seems to be correct:
>srk@ermintrude:~$ dig bora-bora.es
; <<>> DiG 9.2.4 <<>> bora-bora.es
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 51749
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0
;; QUESTION SECTION:
;bora-bora.es. IN A
;; AUTHORITY SECTION:
bora-bora.es. 600 IN SOA jobs.sefes.es.
postmaster.sefes.es. 2005051210 86400 7200 2592000 600
So, no A records for bora-bora.es (there are no answers)
Let's see what is there:
>srk@ermintrude:~$ dig any bora-bora.es
; <<>> DiG 9.2.4 <<>> any bora-bora.es
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 20152
;; flags: qr rd ra; QUERY: 1, ANSWER: 6, AUTHORITY: 3, ADDITIONAL: 3
;; QUESTION SECTION:
;bora-bora.es. IN ANY
;; ANSWER SECTION:
bora-bora.es. 604800 IN MX 5 filtre.pimec.net.
bora-bora.es. 604800 IN MX 10 nen.pimec.net.
bora-bora.es. 604800 IN SOA pimec.net.
postmaster.pimec.net. 2005052001 86400 7200 2592000 600
bora-bora.es. 604800 IN NS ns2.pimec.net.
bora-bora.es. 604800 IN NS ineco.nic.es.
bora-bora.es. 604800 IN NS ns1.pimec.net.
;; AUTHORITY SECTION:
bora-bora.es. 604800 IN NS ns2.pimec.net.
bora-bora.es. 604800 IN NS ineco.nic.es.
bora-bora.es. 604800 IN NS ns1.pimec.net.
;; ADDITIONAL SECTION:
ns1.pimec.net. 172771 IN A 217.149.149.12
ns2.pimec.net. 172773 IN A 217.149.149.13
ineco.nic.es. 2138 IN A 194.69.254.2
;; Query time: 66 msec
;; SERVER: 193.62.204.1#53(193.62.204.1)
;; WHEN: Thu May 26 12:18:02 2005
;; MSG SIZE rcvd: 279
So you have some MX records (for mail) which is fine. Note that dnsmasq
doesn't cache MX records, so it will forward the query each time. It
looks like your host is doing an A-record lookup first, then an
MX-record lookup. If that's coming from a mailserver, then it's odd:
mailservers are usually configured to do an MX lookup first, and then
fall-back to a A record if that fails.
HTH
Simon.