1845896 Members
3940 Online
110250 Solutions
New Discussion

NIS problem

 
Neerav Kothari
Occasional Contributor

NIS problem

Hi,
I am a newbie to HP UX, so bear with me. The HP 9000 box I am working with was working quite fine untill I made a change to the Name Server Switch config. I tried undoing what I had done but to no avial. When I boot the machine, I get the following message every couple of seconds:

nyhpux01 pid=1062 /usr/lib/netsvc/yp/ypbind
NIS: server not responding fo domain "mydomain.com"; still trying

The only way for me to stop these messages is to kill the ypbind process once I log in as root. Since this is not a critical system and we have very little Unix perience in house, there are no backups. Help!!! Thanks.
6 REPLIES 6
Vikas Khator
Honored Contributor

Re: NIS problem

Hi,

Assuming you have fixed your name config file .
cd /sbin/init.d
./nfs.server stop
./nfs.client stop
./nis.client stop
./nis.server stop
./nfs.core stop
./inetd stop ; ./inetd start

./nfs.core start
./nis.server start
./nis.client start
./nfs.client start
./nfs.server start

Hope this fixes your problem
Keep it simple
Shannon Petry
Honored Contributor

Re: NIS problem

This means that the system can not find your NIS server, plain and simple. You can handle this in a couple of ways. If you are not running Secure NIS, then edit the file "/etc/rc.config.d/namesvrs" and go to the bottom of the file. Their you will see several variables and settings. Look for "YPBIND_OPTIONS=" and make it 'YPBIND_OPTIONS="-ypset"'. Next look for the line 'YPSET_ADDRESS=""' and make it 'YPSET_ADDRESS="ip.of.your.server"'.
then run /sbin/init.d/nis.client start, and see if you now have your server.
It is a lame fix because if you upgrade, your changes must be remade. It would be best to look at the server map "ypservers" and make sure it is correct. Also look at your broadcast address for both the clients and servers. They should be the same.
Last, and most importantly, make sure that the system can resolve the PROPER name of the server. The easy way to test both sides is to telnet from the server to the client. On the client run "who -u" and see who is connected. As far as your seat goes, this name must be resolvable. The same must occur on the server. If their is an /etc/hosts entry which conflicts, there can be strange problems such as this!

Best Regards,
Shannon
Microsoft. When do you want a virus today?
Antoanetta Naghiu
Esteemed Contributor

Re: NIS problem

I guess, you have to go to /etc/rc.config.d and edit namesvrs.Are you using NIS at all?
Is your box client, slave or master?

Anyway, in namesvrs file, set to 0 the variable that you do not need, to 1 what you need. e.g. if your box is NIS client, have NIS_CLIENT=1, NIS_SERVER=0. If the box is not part of NIS domain,
NIS_CLIENT=0, NIS_SERVER=0, NIS_DOMAIN= (nothing, blank), YPBIND_OPTIONS="", actually do not set anything.
Check as well the variable NAMED. If it is 1, will start the named daemon.
Rick Garland
Honored Contributor

Re: NIS problem

Are you able to resolve the other nodes in the domain? Is the NIS files using the node name or IP address?

Do nslookup by IP and hostname to ensure that resolution is happening.
Steve Sauve
Frequent Advisor

Re: NIS problem

Some simple things you could try would be the following:
1. Make sure you can ping the IP address of the NIS server from the client and vice versa.
2. Make sure they can ping eachother by host name.
3. I believe you said you changed the nsswitch.conf file? If you think it might be fubar, then just rename it. Without it HP-UX uses default settings which may work for you.

Hope this helps,
Steve
Anthony deRito
Respected Contributor

Re: NIS problem

Neerav, try to determine your entire NIS configuration. This is not hard. Check the /etc/rc.config.d/namesvrs files on all boxes and check out the NIS_MASTER_SERVER and NIS_SLAVE_SERVER variables. Determine which system(s) is your NIS server and which system(s) is your NIS client. Furthermore, your NIS master server(s) should be running the following processes:

ypserv
ypxfrd

Your NIS client(s) should be running the following processes:

ypbind
keyserv

Now, after you know your environment, check out that ypbind is registered with the portmapper on all boxes. Run

rpcinfo -p | grep ypbind
rpcinfo -p | grep ypserv

You should see them in the output.

Now make a broadcast from your system in question to determine if the servers that were determined to be running ypserv are responding. Use this command:

rpcinfo -b 100004 2

You should see something like this:

nnn.nnn.nn.123 system1.domainname
nnn.nnn.nn.456 system2.domainname

Now make sure you can ping the servers from your system and communicate with them.

Note that you have to have at least one server on your network running the ypserv process. If all is in place, your system in question should automatically bind to one of the servers running ypserv.

When and if it does bind, you should be able to run the command:

ypwhich

and see the servername of the NIS server running the ypserv process.

Hope this helps.

Tony