DNS Query "pipelining"

217 views
Skip to first unread message

paul tremberth

unread,
Nov 17, 2010, 5:20:28 PM11/17/10
to public-dns-discuss
Hi,

I havent found anything similar being discussed here.
I havent seen it in network captures I'be done with Wireshark. Maybe
this already exists in some implementations or is not possible, but
I'm not aware of it.

So the idea would be to pack more than 1 question per DNS query
message for a common domain name, which I think is possible looking at
the RFCs DNS message format.

For many websites, your favorite browser queries "www.example.com",
then something like "static.example.com", and maybe
"images.example.com" (look at DNS queries when visiting facebook.com)
Wouldn't it be cool to query once for "www.","static.", "images." +
"example.com"? and have replies for all 3 questions in 1 DNS response
message?

Of course a browser would need to group DNS resolutions for the same
domain name to fetch resources of a web page, and something else than
the standard gethostbyname() call, but for example Chrome Browser +
Google DNS could implement that.

Any thoughts?

Paul.

Wilmer van der Gaast

unread,
Nov 17, 2010, 6:35:19 PM11/17/10
to public-dn...@googlegroups.com
Hello Paul,

On 17 November 2010 22:20, paul tremberth <paul.tr...@gmail.com> wrote:
>
> So the idea would be to pack more than 1 question per DNS query
> message for a common domain name, which I think is possible looking at
> the RFCs DNS message format.
>

I assume you're talking about putting more than one question in the
QUESTION section? Although the DNS protocol technically allows this,
IIRC not a single implementation ever supported it (BIND included).
This seems to be confirmed by
http://www.maradns.org/multiple.qdcount.html . Also, IIRC (but I'm
less sure about this) I read somewhere that some other
changes/extension made to DNS in the past are not compatible with
having multiple questions in a packet.

Although the idea is interesting, the benefit would be small because
DNS query packets aren't that huge. (And if they are, their responses
will be even bigger, easily hitting the 512 byte limit.)


Regards,

--
Wilmer van der Gaast, Traffic SRE/Google Public DNS team.
Google Ireland.

paul tremberth

unread,
Nov 19, 2010, 9:42:29 AM11/19/10
to public-dns-discuss
Hi Wilmer,

Thanks for your input.
Yes, I was talking about QDCOUNT.

Interesting link on MaraDNS.
As it is mentionned I also experienced a "format error"
when sending a example request to a BIND server.

The main motivation was that the payload vs. header
for these small query paquets is somewhere around 28/60-80 bytes from
what I can see,
and as the questions would be for the same second-level domain name,
and thanks to DNS message compression,
the additional payload would be small.

But I agree the benefit may be small, it would need some
experimenting.

Another connex idea would be to use the Additional RRs section in
replies
to anticipate subsequent queries depending on likely/previous queries
for same the domain name
(especially after reading http://code.google.com/speed/public-dns/docs/performance.html,
"Prefetching name resolutions")

Regards,
Paul.


On Nov 18, 12:35 am, Wilmer van der Gaast <wil...@google.com> wrote:
> Hello Paul,
>
> On 17 November 2010 22:20, paul tremberth <paul.trembe...@gmail.com> wrote:
>
> > So the idea would be to pack more than 1 question per DNS query
> > message for a common domain name, which I think is possible looking at
> > the RFCs DNS message format.
>
> I assume you're talking about putting more than one question in the
> QUESTION section? Although the DNS protocol technically allows this,
> IIRC not a single implementation ever supported it (BIND included).
> This seems to be confirmed byhttp://www.maradns.org/multiple.qdcount.html. Also, IIRC (but I'm
Reply all
Reply to author
Forward
0 new messages