Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

/etc/resolv.conf, /etc/netsvc.conf

Status
Not open for further replies.

ogniemi

Technical User
Nov 7, 2003
1,041
PL
The DNS resolving is not needed so I switched it off removing /etc/resolv.conf

In /etc/netsvc.conf just left hosts=files

Eveything looks fine, but one error in syslog is logged every 5 minutes:

Jan 23 10:57:25 test045 user:err|error syslog: dlopen of user option: files failed: 0509-022 Cannot load module /usr/lib/netsvc/dynload/files.so. 0509-026 System error: A file or directory in the path name does not exist.

When I remove /etc/netsvc.conf the error no more appears.


Q: I it safe to remove /etc/netsvc.conf in my case when DNS is not used and resolv.conf is removed?


thx in advance!
 
I found - there was a mistake in netsvc.conf

should be:

hosts = local
 
Just a point of note, I wouldn't remove resolv.conf completely, but leave a functionally empty file with the commented-out line "this is empty for this reason: " and the reason.

That way whoever comes in behind you can see that there is a reason for that file to have nothing in it, instead of seeing "oh, no resolv.conf, let's get that problem fixed" because most of the time, having one is desirable.
 
But Chapter11, where's the fun in that ;-)

I want to be good, is that not enough?
 
the problem is that when I left it commented (or event empty file - 'touch /etc/resolv.conf'), the mail sending doesn't work.

with empty resolv.conf:
echo test| mailx -v -s test host@domain.net
hangs after several minutes send-mail process failes and messages lands in mailq. When I remove resolv.conf and run 'sendmail -q' the queued messages are resent ok and reaches recipient(s) (smart relay host is added to /etc/hosts).


with removed resolv.conf:
echo test| mailx -v -s test host@domain.net
works.



 
empty file I meant:

> /etc/resolv.conf
 
Maybe just rename it resolv.orig so that you don't have to delete it?

I want to be good, is that not enough?
 
An "empty" resolv.conf means: named is running locally (If I remember correctly)

So if named isn't running the show and you have an empty resolv.conf, you'll see all kinds of strange waits and timeouts...


HTH,

p5wizard
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top