Network Management / (OpenView-NNM) Practitioners Forum

Openview and DNS vs hosts file dilema

Go to solution
Lane Frazier
Respected Contributor.

Openview and DNS vs hosts file dilema


Environment is HP-UX 11.0 with NNM 6.1

We are using DNS in my organization and have both a primary and secondary DNS server. Both of these servers are listed in my resolv.conf file

For some reason I am never able to resolve any names or ip addresses beyond what is located in my building. I have been told by the DNS admin that the reverse lookup information has not been implemented yet...

From what little I know about DNS I know that this is not good for my NNM system.

Since I have no control over DNS I'm wondering if it would be in my best interest to implement an etc/hosts file on my NNM will be a pain to keep up with but at least I can get names and ip addresses resolved easier....

Does this sound like a reasonable idea...what do I need to do to make it happen....create an etc/hosts file amd restart netmon?

What do I do with the resolv.conf file?

Thanks for your time
Maybe one day I'll understand Openview?!
Jaroslav Matys
Outstanding Contributor.

Re: Openview and DNS vs hosts file dilema

Simply change nsswitch.conf file:
hosts: files [NOTFOUND=continue] dns
Alex Glennie
Acclaimed Contributor.

Re: Openview and DNS vs hosts file dilema

You'd need to create an etc/hosts and include loopback address as well as ip's & hostnames of other system on your network(s).

Probably OK to leave resolv.conf in place but make sure /etc/nsswitch.conf reads hosts first !

hosts: files [ NOTFOUND=continue ] dns

would probably do, check say using nslookup from /etc/hosts it should return that its reading from files & not the DNS server.

Not sure about NNM, it may need to be restarted / configured in someway ? anyone ?
Eric Morey_1
Respected Contributor.

Re: Openview and DNS vs hosts file dilema

After making changes to the resolv.conf or nsswitch.conf, you just need to stop and start netmon.

ovstop -v netmon
ovstart -v netmon

Rick Garland
Outstanding Contributor.

Re: Openview and DNS vs hosts file dilema

It is going to be some work, you are correct. But you can put the hosts into the /etc/hosts file and maintain there. The /etc/nsswitch.conf will need the modification as well to tell it to look in FILES first.
Frank Saxton
Acclaimed Contributor.

Re: Openview and DNS vs hosts file dilema

Using a local /etc/host file on the NNM server is a very bad idea, IMO. It solves the short term problem but creates long term problems and is not easily extensible. A better solution would be to get DNS running properly.

The DNS servers should know about all of the equipment you will want to manage. If it doesn't, whoever is administering DNS there needs to learn about secondary DNS, zone transfers, etc. Even Companies with huge, global networks set up their DNS servers so that you only need to consult one or 2 servers to find the node you are looking for.

Assuming that the 2 DNS servers that you have addresses for truly cannot resolve host names that you want (try nslookup ), see if you can get a list of all of the authoritative DNS servers for your environment. You can have up to 3 (I think) DNS servers in the search list. If it takes more than 3 DNS servers to get total coverage for your Company equipment, whoever is administering DNS there needs to find a different job.

Another option, assuming that your IT Management is really this clueless, is to set up your server as a secondary DNS server and take zone transfer information from all of the primaries in the network.

The situation you describe is so outrageous that I suspect your problem may really be that you do not have DNS properly configured on your server. Talk to someone in your facility who knows this stuff and have them take a look. The whole idea behind DNS is to avoid the need for maintaining local host files.

Hope this helps and good luck.
Lane Frazier
Respected Contributor.

Re: Openview and DNS vs hosts file dilema

Hello again,

I agree that the right way is to use argument there.I really don't want to have to keep up with a hosts file..I was simply trying to make NNM's life easier until we get the whole DNS issue resolved.

As far as I know I have both resolv.conf and nsswitch.conf configured correctly...

resolv.conf looks like this
nameserver < IP address of Primary DNS server>
nameserver < Ip address of Secondary DNS server>

nsswitch.conf looks like

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

nslookup commands for ip addresses in my building work fine....NNM is being used to keep up with about 500 routers outside my building.

nslookup commands for any ip addresses or hostnames of cisco routers on my network comes back with I know that NNM performance is negatively impacted..all I wanted to do is try and "help" things until we get DNS set...

All that said...mgt wants me to get some documentation together that describes the impact DNS has on NNM...such as quicker discovery,quicker opening map time, less polling overhead etc etc...I've found several things in the managing your network...anybody have a better document or a link to one...

I've got to have something to go press this issue some more...Thanks to everybody for your help.
Maybe one day I'll understand Openview?!
Lane Frazier
Respected Contributor.

Re: Openview and DNS vs hosts file dilema

One other tidbit of info...

While nslookup returns nothing

a /opt/OV/support/gethost < hostname > does

also I am able to telnet (as opposed to an ip address) and can get into my routers this way...

What is the significance of this?
Maybe one day I'll understand Openview?!

Re: Openview and DNS vs hosts file dilema

Hey, good thread even though it looks a bit aged now...

If anyone is still following this, I wanted to get a bit more reliability of my ERP system running on HP-UX, DNS works over all very well.  However our DNS (pri/sec) went down the other day (hardware) it took down my ERP system.  I am on generally small network and it takes just say 4-6 servers to keep this ERP fully functional.  Would in this case it makes sense to use DNS first and have it only look at my local copy of /etc/hosts if both of my DNS fail at the same time.  All of these systems have hard coded IPs.  Thanks for the advise   -KJ

time is a preditor to us all, live now not in the future.