Who moved my resolv.conf ?

Tom Lane tgl at redhat.com
Thu Aug 27 01:12:08 UTC 2009


Tom Horsley <tom.horsley at att.net> writes:
> I have the NetworkManager turned off, I have network turned on,
> I have PEERDNS=no in the eth0-ifcfg file. Yet someone is still
> engaged in swapping in and out different resolv.conf files.

> How do I make it stop in Fedora 12 Alpha? I've done all the
> things that made it stop in fedora 11...

It's harder than one could wish to prevent this in F-11, too.
What's misleading is that network-scripts contains code that will
overwrite resolv.conf with comments claiming to be NetworkManager's
handiwork, even though NetworkManager is turned off.

The notes I made while debugging my F-11 setup are:

network-scripts likes to overwrite /etc/resolv.conf at boot.  To prevent,
make sure ifconfig-eth0 sets PEERDNS=no and doesn't set DNS1, which is not
the way anaconda will have left it.  Beware there are three hardlinked copies
of this script in /etc/sysconfig/network*/.  May also need to fix
/etc/sysconfig/networking/profiles/default/resolv.conf
and make sure /etc/resolv.conf isn't hardlinked to anything, and make sure
/etc/resolv.conf.save doesn't exist.

The last one is particularly insidious: if there's an
/etc/resolv.conf.save, ifdown puts it back :-(

If there's still more that has to be done in F-12, would someone
tell what?

			regards, tom lane




More information about the fedora-test-list mailing list