Re: DNS over TCP: Order of responses
Dean Anderson <[email protected]>
| Newsgroups | gmane.network.djbdns |
|---|---|
| Message-ID | <[email protected]> |
There is no order specified in RFC1035 that I can find.
Section 4.2.2 states:
Several connection management policies are recommended:
- The server should not block other activities waiting for TCP
data.
- The server should support multiple connections.
- The server should assume that the client will initiate
connection closing, and should delay closing its end of the
connection until all outstanding client requests have been
satisfied.
- If the server needs to close a dormant connection to reclaim
resources, it should wait until the connection has been idle
for a period on the order of two minutes. In particular, the
server should allow the SOA and AXFR request sequence (which
begins a refresh operation) to be made on a single connection.
Since the server would be unable to answer queries anyway, a
unilateral close or reset may be used instead of a graceful
close.
So it seems to imply that each query is a unique, separate transaction
just like with UDP. They can be responded to in any order.
--Dean
On Sun, 8 Mar 2009, Dwayne C. Litzenberger wrote:
> When communicating over a TCP connection, are DNS servers expected to send
> responses in the same order as it received the corresponding queries, or is
> something like the following allowed?
>
> Resolver Nameserver
> -------- ----------
> QR=0, ID=1000 example.com IN A ---->
> QR=0, ID=1234 heaven.af.mil IN A ---->
> <---- QR=1, ID=1234 heaven.af.mil IN A 10.0.0.1
> <---- QR=1, ID=1000 example.com IN A 10.0.0.2
>
> I'm writing a small DNS server that forwards queries to other servers based
> on the contents of the query (QNAME, RD, etc.) so I need to know how both
> the resolver side and the nameserver side _should_ behave, as well as what
> I can expect from other software.
>
> I didn't find anything in either RFC 1035 or RFC 2181 about this. Any
> insights would be much appreciated.
>
> Thanks,
> - Dwayne
>
>
--
Av8 Internet Prepared to pay a premium for better service?
www.av8.net faster, more reliable, better service
617 344 9000