Re: FC3 wiping its own resolv.conf

From: Bill Davidsen (davidsen_at_deathstar.prodigy.com)
Date: 06/29/05


Date: Wed, 29 Jun 2005 20:03:34 GMT

David Bromage wrote:
> Baho Utot wrote:
>
>> On Sun, 01 May 2005 14:30:33 +1000, David Bromage wrote:
>>
>>
>>> Bit Twister wrote:
>>>
>>>> On Fri, 29 Apr 2005 12:56:44 +1000, David Bromage wrote:
>>>>
>>>>
>>>>> No, definately not using DHCP. The static IP and PEERDNS=no are set
>>>>> in /etc/sysconfig/network-scripts/ifcfg-eth0 and ifcfg-eth1.
>>>>
>>>>
>>>> add the peerdns line to
>>>> /etc/sysconfig/network
>>>
>>>
>>> Just tried that, and it's still not working. The only thing that does
>>> work is if I write resolv.conf manually and then restart network. I'd
>>> rather not have to do that after every reboot. :)
>>
>>
>> Make your resolv.conf and then set the imutable bit with chattr
>> "chatter +i /etc/resolv.conf" Then nothing can change the file.
>> This is what I have done.
>
>
> Thanks! That's fixed the problem!

No, it hid the symptoms... since a fair number of people don't have that
problem, I think it's reasonable to assume that if you found the actual
root cause you could prevent the unwanted modification from being attempted.

I don't have FC3 here, but older vi knows about read-only but not
attributes, so if you need to change it and forget what you did, you
have left a surprise for yourself, and possibly a problem affecting more
than just this.

Take a look at the time last modified of the dhcp programs if you are
curious, whatever you have, dhcpd, dhclient, whatever. See if they get
called at boot time. If you're curious what's really happening...

-- 
bill davidsen
   SBC/Prodigy Yorktown Heights NY data center
   http://newsgroups.news.prodigy.com