[Dnsmasq-discuss] [Patch] dnsmasq biased round robin for new requests

Simon Kelley simon at thekelleys.org.uk
Sun Jun 5 21:41:57 BST 2011

harish badrinath wrote:
> I assume the patch was rejected ??
We're still talking, I think.

> Either the patch / idea / both did not meet your approval. If the
> patch was the problem, i am willing to redo it the "right way" (with
> some guidance of course). If the idea was the problem, i do see a use
> for it, albit a very niche one. If both were the problem, i shall just
> let this go into the dustbin of history.

Tweaking the patch so that it makes sense and fits my coding aesthetic
isn't a problem, but the idea of searching a set of servers in a
particular order is problematic.

Assume you have two servers, one of which knows about some domains but
the other does not. You query the "special" server first so that it can
tell you about those domains. But DNS uses UDP, which is an unreliable
transport, so at random, the queries to the special server might get
lost, and then the queries will get answered from the second server, and
randomly your extra domains get lost. Good luck diagnosing the problem.

Dnsmasq is written with the strong assumption that all "normal" upstream
servers have the same view of the DNS. You can redirect queries for some
domains to other servers like this


and *.example.com will go to the special server and only the special
server, it doesn't rely on a server pre-empting the answer before the
query goes to the general servers.

Does that mechanism not solve your problem?



More information about the Dnsmasq-discuss mailing list