dns servers

From: Eric Stern <estern@dont-contact.us>
Date: Wed, 28 Oct 1998 14:57:01 -0500 (EST)

I wrote a patch for 2.0.patch2 last night that dynamically loads dnsserver
processes based on demand. That is, if there is a call to
dnsGetFirstAvailable() and there are none available, it spawns a new one,
up to the maximum of 32 processes (compile time option).

The reasoning here is that my typical way of tuning dnsservers is to keep
increasing them until the last process always has 0 requests (or at least,
very very few). This little bit of code should allow it to tune itself.
In its current state, it will add dns processes, but it will never remove
them.

So I'm just wondering: can anyone think of a compelling reason to reap
dnsservers? I'm thinking that a brief surge of activity could spawn a few
more processes than are really needed, but those idle processes really
won't hurt anything, and the code to reap them could be a bit tricky, so I
wasn't going to bother. As i said, it'll only load up to 32 of them (and I
can't imagine anyone needing that many...a busy cache might need 15...20
tops). The "dns_children" entry in squid.conf now controls how many
processes are initially spawned.

BTW, I also changed the dns_child_table to a static array (32 elements).
I'm also going to revamp the redirector process the same way (static
array, dynamically loaded).

I haven't tested this at all yet. As soon as I'm sure its stable I'll get
a patch out.

/-----------------------------------------------------------------------/
/ Eric Stern - PacketStorm Technologies - (519) 837-0824 /
/ http://www.packetstorm.on.ca /
/ WebSpeed - a transparent web caching server - available now! /
/-----------------------------------------------------------------------/
Received on Tue Jul 29 2003 - 13:15:54 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:11:57 MST