View Single Post
Old 29. May 2009, 06:39 AM   #9 (permalink)
bk_7312
Senior Member
 
Join Date: Feb 2009
Location: 3rd largest island, smallest country there.
Posts: 229
Default

Quote:
Originally Posted by debtboy View Post
Ah yes,
your /etc/resolv.conf being rewritten has to do with your configuration.
If you are configured (which I expect you are) to obtain DNS addresses automatically
a program will extract the DNS from your Internet provider and write that to resolv.conf

You can fix this many ways...

You can change to a dedicated DNS setting
(Your GUI probably has this capability)

You can modify the program that writes to your resolv.conf
(this sounds worse than it is, it's probably just another config file to modify)
(this procedure may be distro dependent, not universal to all Linux)

A simple way might be to change the permissions on your resolv.conf to:
r--r--r-- which would require the following:
su root it will ask for a password
Now as root chmod 444 /etc/resolv.conf
(making it read only)

However you fix it, your now on the path to configuring your own custom Linux system!!!
Linux IMHO is not meant to be used right out of the box, it's meant to be configured,
why else would you have almost unlimited configurability!!
Thanks debtboy,

I change /etc/resolv.conf permission to read-only but I can still modify it as root and so can the program that modifies /etc/resolv.conf.

I think I took the easy way out, I open MEPIS Network Assistant (already built in on MEPIS, the Linux I currently use as dual-boot) and change from using DHCP to static for both DNS and IP settings. Had a little trouble with the IP part but it's all fixed.

I didn't realise I could change the DNS using MEPIS Network Assistant until now... what a fool I was but it's worth learning how to change the DNS using the command line.
bk_7312 is offline   Reply With Quote