I didn't follow all of that, probably because I'm using Eiger
and there are differences.
But here is what it came down to:
I gave up attempting to follow all the possibilities and
realized that exit-hooks was the "final" word.
So I put a script in the "BOUND" section to do exactly what
I wanted.
In my case it was a python script to parse the leases file
and build dhcpd.conf the way I wanted.
Could easily have been bash or ash and I could easily have
built it with some "custom" overrides, but the point is I now
have control of the process and it only took an hour or so.

Free software ain't cheap, but it's free.





Will Clements <[EMAIL PROTECTED]> on 03/29/2002 09:21:48 PM

To:   Matt Schalit <[EMAIL PROTECTED]>
cc:   [EMAIL PROTECTED] (bcc: Phillip Watts/austin/Nlynx)

Subject:  Re: [Leaf-user] dhclient and dnscache



--> >
--> > I recently setup a Dachstein floppy firewall/gateway for
-->
-->
--> > 1]  The machine being used is a Compaq P133, (and old
-->
--> Don't know.  Maybe.
-->
-->
-->
--> > 2]  I want to automatically update the external servers
-->
--> People have described some sort of exit script that
--> you can cusomize that gets run just before dhclient
--> finishes and exits.  It's part of the dhclient package.
--> Check it's files and search the archives for dhclient,
--> exit, and/or exit hooks.  I don't run it but thought
--> I'd throw it out there until someone else replies.
-->

Yea I thought about that but in my situation, I believe
the following occurs:

A) "/etc/init.d/dhclient" calls "/usr/sbin/dhclient" which
reads the dhclient.conf file and also parses the ISP lease
info.

B) Because I'm using the "supersede domain-name-servers"
directive in the dhclient.conf file, the variable that
should hold the nameserver(s) from the ISP lease info,
instead contain the nameserver(s) from the dhclient.conf
file "BEFORE" control is passed to "/etc/dhclient-script".

C) Thus the nameserver variable passed to
"/etc/dhclient-script", (I believe its actually called
"domain-name-servers") has the wrong nameserver(s) assigned
to it.

D) Only "/etc/dhclient-script" calls/sources "dhclient-exit-hooks",
(I think), thus the "dhclient-exit-hooks" script does not
have access to the right nameserver info for me to
update dnscache at this point.

E) I seem my options as:

I could recompile "/usr/sbin/dhclient" to create another
pass through variable that maintains the original lease
DNS server info when the "supersede domain-name-servers"
is used.  I doubt I'll do this since I don't have a box/
virtual box to compile this on.

Or I could try to get it from the dhclient lease file.
But I'm looking for an easy way out with minimum effort on
my part.

----

Any thoughts on my line of reasoning?


Will


_______________________________________________
Leaf-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/leaf-user





_______________________________________________
Leaf-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/leaf-user

Reply via email to