Showing results for 
Search instead for 
Do you mean 

host, resolv.conf, nsswitch.conf - Argh!

Go to Solution
Frequent Advisor

host, resolv.conf, nsswitch.conf - Argh!

OK. I've read many posts here about various name resolution issues, but I'm still having problems.

This machine is an internal development box. The machine is a K460 running HP/UX 11.0.

Here are the relevant lines from the various files

hostname : verbie
ip :




hosts: files [NOTFOUND=continue] dns [NOTFOUND=return]

hosts localhost loopback verbie

The machine is not listed in a DNS server and not accessed from the Internet.

Does this all look correct?

Honored Contributor [Founder]

Re: host, resolv.conf, nsswitch.conf - Argh!

Hi Tim,


hosts: files [NOTFOUND=continue UNAVAIL=return TRYAGAIN=return] dns [NOTFOUND=return UNAVAIL=continue TRYAGAIN=return]

WIth the hosts file, why have a fully qualified name listed, why not just the host?

Anyone for a Mutiny ?
Honored Contributor [Founder]

Re: host, resolv.conf, nsswitch.conf - Argh!

I didn't see the entry for the router i.e.:


Resolv.conf looks fine (bare minimum.. but works).

What dies (swagent?), or what can't you get out to?

"Do or do not. There is no try!" - Yoda
Honored Contributor [Founder]

Re: host, resolv.conf, nsswitch.conf - Argh!

It all looks fine to me, but you failed to mention or describe the problem. What can't you do?
If it has wheels or a skirt, you can't afford it.
Frequent Advisor

Re: host, resolv.conf, nsswitch.conf - Argh!

Thanks for all the responses.

I wasn't sure I needed a fully qualified hostname in hosts. Just one of the things I tried when things "weren't" working.

Where do the route entries go?
My resolv.conf file has more info (nis, etc). I was just posting the part I assume were important to my problem.

I have Oracle 8.1.6/WebDB on the machine and they have been running for several weeks without a problem. The problem I was having involved running a Coldfusion MX server on the same machine. I was having problems that appeared to be name resolution.

I think I needed to reboot when I made one of the changes.
Honored Contributor [Founder]

Re: host, resolv.conf, nsswitch.conf - Argh!

The route stuff goes in
It is always a good day when you are launching rockets!, Mostly Missiles
Honored Contributor [Founder]

Re: host, resolv.conf, nsswitch.conf - Argh!

Hi Tim,

Putting the entries in /etc/rc.config.d/netconf covers you for the next reboot. To get the route setup NOW - you either have to bounce the net daemon after editing the netconf file

/sbin/init.d/net stop
/sbin/init.d/net start

or issue the route add command

route add default 1

The last value is hop count to the router - usually 1.

Check the routing tables with

netstat -rn

You should now see your default route - test the actual route by trying to ping something on another subnet.

PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!