I have the usepeerdns option set in my ppp config to grab DNS server
addresses from my ADSL provider. This works well, but overwrites any
additional static DNS entries in /etc/resolv.conf whenever the connection
comes up. That in turn causes my DHCP server to stop sending the local DNS
server's address to clients on the LAN, which means that they no longer
have name resolution for the internal view of my domain (other machines on
the LAN). (Internet DNS still works fine, since they get sent the ISP's
server addresses.)
In the past I remember adding an entry or option (somewhere in /etc/ppp I
think?) which enabled pppd to still grab dns servers from my ISP and add
them to /etc/resolv.conf, but leave the local "nameserver 192.168.10.1"
line alone in /etc/resolv.conf. I've googled my fingers raw but can't seem
to find how I managed to get ppp to add the extra nameserver. I know I
could switch to static DNS, but would prefer to leave it ISP-assigned in
case they're changed in the future, and just add my private one in the
first line of /etc/resolv.conf
Any ideas?
TIA,
Dave.
In your situation I would add a line to rc./local that looks something like this:
cat "line of text" >> /etc/resolve.conf
to add a a line at the end of the file, or:
cat "line of text" > which will essentially begin a new file/1st line with
existing contents "deleted".
I could rewrite the whole thing on the fly at the end of the boot regardless of
what has previously been written during boot if I start a ">" and follow for every
other line with a ">>"
The local script will be run as root so if you want to make friends and influence
people you could put the line
telinit 6
in someone elses local script, then hide behind a bush to watch the fun or go home
early.
--
Cheers,
Rick Miles
Written on Sweetmorn, the 21st of Chaos, 3176
http://turtlespond.net
http://rickmiles.com.au
> In your situation I would add a line to rc./local that looks something
> like this:
> cat "line of text" >> /etc/resolve.conf
> to add a a line at the end of the file, or:
> cat "line of text" > which will essentially begin a new file/1st line
> with
> existing contents "deleted".
>
Thanks Rick - that's actually what I'm doing at the moment, but was hoping
someone knew the right/nice way :) For now I'll stick with the kludge, but
will keep googling just in case...
cheers,
dave.
> cheers,
>
> dave.
>
--
Cheers,
Rick Miles
Written on Boomtime, the 22nd of Chaos, 3176
http://turtlespond.net
http://rickmiles.com.au