1833589 Members
4091 Online
110061 Solutions
New Discussion

nslookup error

 
SOLVED
Go to solution
Ben Li
Advisor

nslookup error

I have iust setup nisclient for the new HP machine. When I use nslookup to check the host ip address it comes out message like this:
*** Unknown source : nisplus. not supported.
*** You have defined one or more supported sources.
*** Please modify your configuration file and try again.
*** Or you will get unreliable information.
...

the ypbind and running in the system. I think in the configuration file it setup both nis and nis+. Can anyone tell me how to modify the configuration files? And which file?

Thanks
14 REPLIES 14
Brian M. Fisher
Honored Contributor

Re: nslookup error

Check the settingings in /etc/nsswitch.conf
You should be looking at NIS+ first on the following line:
hosts: nisplus [NOTFOUND=return] files

Brian
<*(((>< er
Perception IS Reality
Ben Li
Advisor

Re: nslookup error

Yes, the /etc/nsswitch.conf is like that.

Thanks
Rick Garland
Honored Contributor

Re: nslookup error

In addition to the nsswitch.conf file, ensure that you are running the service you actually want to run.
Antoanetta Naghiu
Esteemed Contributor

Re: nslookup error

Usually, the hosts are solved by DNS or hosts. If you really use nisplus for that and you had configured the new machine into the server, then, try nis in /etc/nsswitch.conf (not nisplus, just nis). But, first be sure it is corectlly configured. Eventually try nslookup on the nis server to look for the new box.
Ben Li
Advisor

Re: nslookup error

I use nisls -l and niscat -A passwd.org_dir command, then it comes out the result from the nis+ server.

thanks
Antoanetta Naghiu
Esteemed Contributor

Re: nslookup error

I am not using nisplus, but nslookup in the nisplus server should work as well (if was hp machine). What is the output of nslookup ran in the server?
I do not think that password map/database has something to do with hosts map (database, whatever).
At least in nis, simple, not plus, you have different maps for password, hosts, services, a.s.o.
Antoanetta Naghiu
Esteemed Contributor

Re: nslookup error

As an addeum, in the /etc/nsswitch.default for hosts they talk about nis, dns, files but not about nisplus. Maybe you can ask HP if nisplus is supported for hosts resolution.
By the way, do you have another HP machine that uses nisplus for hosts resolution? If yes, compare the config and the patches level.
Ben Li
Advisor

Re: nslookup error

It seems the nis+ and dns runs well. and I can mount file system from other sun machine to the HP. Only when I run nslookup it comes with the message.
If in the nslookup prompt, I set the domain server name, then it will works well within the prompt.
It seems the nslookup can not get the domain server name from the /etc/resolv.conf file.
Any ideas?

Thanks
Antoanetta Naghiu
Esteemed Contributor

Re: nslookup error

As far as I know, /etc/resolv.conf is used by DNS and has nothing to do with NIS. For nis you have to have a master, 1-2 slave (recommended, not required), and the clients. Create the maps on master, push them to the clients. No interaction with /etc/resolv.conf
Anthony deRito
Respected Contributor

Re: nslookup error

Ben, the resolver will handle parsing through the statement in /etc/nsswitch.conf. Here is the resolver in action:

# nslookup venus
Name Server: name.lll.eee.ddd
Address: nnn.nnn.nnn.nnn

Trying DNS
Trying NIS
Trying files
Name: venus
Address: 192.85.248.3

In this example, the resolver finally found the entry in the local hosts file. You can see it first trying DNS, then NIS. The switch file would look like this:hosts: dns [NOTFOUND=continue UNAVAIL=continue TRYAGAIN=return] nis [NOTFOUND=continue UNAVAIL=continue TRYAGAIN=return]
files

Berlene Herren
Honored Contributor

Re: nslookup error

Use the nsswitch.compat > copy it to /etc/nsswitch.conf.

Berlene
http://www.mindspring.com/~bkherren/dobes/index.htm
Darren Miller_1
New Member

Re: nslookup error

Ben,

The problem is most likely in your /etc/nsswitch.conf file. If you have both DNS and NIS configured on your system, try adding the following to /etc/nsswitch.conf (create the file if it doesn't yet exist):

hosts: dns nis files

If you aren't using DNS, just add:

hosts: nis files

At 11.x, /etc/nsswitch.conf also supports "passwd" and "group" entries, which may be of interest.

For more information, do a "man switch", or take a look at the sample template files in /etc/nsswitch.*. Hope that helps!
Berlene Herren
Honored Contributor
Solution

Re: nslookup error

This is an expected result as nslookup does not support the use of NIS+. This is evident from the nslookup(1) man page:

"Note, NIS+ is not supported by nslookup. If the hosts source nisplus is found in the /etc/nsswitch.conf file. It will be ignored."

Instead, another resolver such as nsquery should be used as nsquery does support the use of nisplus within /etc/nsswitch.conf.

Berlene
http://www.mindspring.com/~bkherren/dobes/index.htm
Ben Li
Advisor

Re: nslookup error

Thanks Berlene. That solved my concern about whether the NIS+ works normally or not.