<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.3020" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>But, technically, isn't dnsmasq the "client" to the 
upstream DNS servers?&nbsp; Don't YOU have control over how long you wait for a 
reply?&nbsp; Couldn't we have a config-param, similar to how I envisioned this 
resolv option would work, where if dnsmasq has multiple upstream nameserver's, 
we could specify the timeout for a reply in ms or seconds?&nbsp; This isn't for 
a "no such domain", this is for a no-reply (host is down or DNS is not 
responding on that host, etc.).</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>If you did that, we could even have an option to 
send the request to all (or some fraction) upstream servers in parallel and just 
take the first reply.&nbsp; I don't know if they'd call us a bad Inet citizen if 
we did that, though.&nbsp; But, hey, we're making-up for it by caching the 
reply, right? ;)</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>-AJ</FONT></DIV>
<DIV>&nbsp;</DIV>
<BLOCKQUOTE 
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
  <DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
  <DIV 
  style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B> 
  <A title=simon@thekelleys.org.uk href="mailto:simon@thekelleys.org.uk">Simon 
  Kelley</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>To:</B> <A title=aweber@comcast.net 
  href="mailto:aweber@comcast.net">AJ Weber</A> </DIV>
  <DIV style="FONT: 10pt arial"><B>Cc:</B> <A 
  title=dnsmasq-discuss@lists.thekelleys.org.uk 
  href="mailto:dnsmasq-discuss@lists.thekelleys.org.uk">dnsmasq-discuss@lists.thekelleys.org.uk</A> 
  </DIV>
  <DIV style="FONT: 10pt arial"><B>Sent:</B> Tuesday, February 06, 2007 4:34 
  PM</DIV>
  <DIV style="FONT: 10pt arial"><B>Subject:</B> Re: resolver options</DIV>
  <DIV><BR></DIV>AJ Weber wrote:<BR>&gt; <BR>&gt; Thank you for your quick 
  reply...<BR>&gt;&nbsp; <BR>&gt; RE: "options in the custom resolver file", 
  should we have the ability to <BR>&gt; propagate some of these options?&nbsp; 
  For example, timeout, attempts and <BR>&gt; rotate?&nbsp; I think they could 
  be useful in certain situations (like my <BR>&gt; own...I don't want to have 
  to update all my clients resolv interaction <BR>&gt; -- or can this be set 
  with a dhcp option of sorts?).<BR><BR>It's not really possible: don't forget 
  that all this is happening via <BR>UDP: a client sends a request which is a 
  UDP packet, and gets back an <BR>answer (another UDP packet) or times out. If, 
  for instance, the client <BR>timeout is 10 seconds, and the dnsmasq one 5, 
  dnsmasq has no way to tell <BR>the client to give up after 5 seconds except by 
  returning "no such <BR>domain", which is a lie and could cause all sort of 
  problems if the <BR>client really believes it. Really the only way is to 
  adjust the timeout <BR>at the client end.<BR><BR>"rotate" is normally 
  irrelevant when the client only has one nameserver <BR>- dnsmasq, and 
  "attempts" should be at least 2 (the default). dnsmasq <BR>has quite complex 
  methods for chosing between multiple upstream servers <BR>which somewhat 
  depend on clients retrying at least once.<BR><BR>&gt;&nbsp; <BR>&gt; RE: The 
  existing leases...I knew the leases were cached in a file, but I <BR>&gt; 
  didn't know that when dnsmasq starts it actually reads the file and <BR>&gt; 
  leverages that information.&nbsp; Is that documented somewhere?<BR>&gt;&nbsp; 
  <BR>I think it's just assumed that that's the function of that file - a 
  <BR>persistent lease database which survives dnsmasq restarts and 
  reboots.<BR><BR>As an aside, things work pretty well even without the 
  persistent <BR>database. If the ratio of available addresses to clients is 
  reasonably <BR>high then clients will always get given the same address 
  anyway. The <BR>main problem is that the client name disappears from DNS after 
  a restart <BR>until the client renews&nbsp; its lease.<BR><BR>&gt; I've said 
  it before, and I'll say it again:&nbsp; This is a fantastic piece <BR>&gt; of 
  software!<BR>*blush*<BR><BR>&gt;&nbsp; <BR>&gt; Thanks again,<BR>&gt; 
  AJ<BR>&gt;&nbsp; <BR>Cheers,<BR><BR>Simon.<BR><BR>&gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; ----- Original Message 
  -----<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; *From:* Simon Kelley &lt;<A 
  href="mailto:simon@thekelleys.org.uk">mailto:simon@thekelleys.org.uk</A>&gt;<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  *To:* AJ Weber &lt;<A 
  href="mailto:aweber@comcast.net">mailto:aweber@comcast.net</A>&gt;<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  *Cc:* <A 
  href="mailto:dnsmasq-discuss@lists.thekelleys.org.uk">dnsmasq-discuss@lists.thekelleys.org.uk</A><BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  &lt;<A 
  href="mailto:dnsmasq-discuss@lists.thekelleys.org.uk">mailto:dnsmasq-discuss@lists.thekelleys.org.uk</A>&gt;<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  *Sent:* Tuesday, February 06, 2007 12:42 PM<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  *Subject:* Re: resolver options<BR>&gt; <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; AJ 
  Weber wrote:<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  &gt;<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; If I use a "different" 
  resolv.conf file (i.e. I use a<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; 
  resolv-file=/etc/resolv.dnsmasq), will an "option" have the 
  same<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  effect<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; it normally 
  would?<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; For example, I'm considering 
  changing timeout to 2 (instead of the<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  &gt; default of 5), because I've had some issues with my ISP's 
  DNS<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  servers<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; recently and don't want to 
  wait too long for the timeout.&nbsp; With 
  the<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; broadband connection, any of 
  the nameservers in my list consistenly<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  &gt; returns in &lt; 1 sec (when they're up, of 
  course).<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; Will this have the desired 
  effect?&nbsp; Any comments or concerns with<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  that<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; change in general?&nbsp; Am I 
  misunderstanding the purpose of the<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  "options<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; timeout:" ?<BR>&gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; The only lines which are read by dnsmasq are 
  "nameserver" ones -<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; everything else is 
  ignored, except "search" if the option --domain=# 
  id<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; used, when the first entry of the search 
  string is used as dnsmasq's<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; domain 
  setting.<BR>&gt; <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; To get the effect of faster 
  time-outs, it's necessary to alter the<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; timeout 
  in the clients, not in dnsmasq.<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; ALSO...(DIFFERENT TOPIC) : Is 
  there no way to tell dnsmasq to<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; dump 
  it's<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; current lease-info to a file 
  that could be read on restart so it<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  knows<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; about all outstanding DHCP 
  leases?&nbsp; It's rare that I have to 
  restart<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; dnsmasq or the linux box 
  it's on, but when I do, it forces me to<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  restart<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; a lot of client machines in 
  case I'd get a dhcp/IP address mix-up<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; 
  (where<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; dnsmasq doesn't know an IP 
  Address is already leased to a running<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 
  &gt; client, and a new client requests a lease so it hands-out the 
  same<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; address).<BR>&gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Dnsmasq does this by default, in 
  /var/lib/misc/dnsmasq.leases. You can<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; change 
  the location of the lease file using --dhcp-leasefile.<BR>&gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Cheers,<BR>&gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp; Simon.<BR>&gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; 
  <BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; Thanks in 
  advance,<BR>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &gt; 
AJ<BR></BLOCKQUOTE></BODY></HTML>