NFS Services Administrator's Guide

Troubleshooting NFS Services
Common Problems with NIS
Chapter 8 313
If NIS Returns Incorrect Information
Issue the following command on the NIS client to determine which
master server supplies the appropriate NIS map:
/usr/bin/ypwhich -m mapname
If the server does not respond, see “If You Receive an NIS “Server
Not Responding” Message” on page 307.
Log in as root to the NIS master server, and issue the following
command to check the contents of the appropriate NIS map:
/usr/bin/ypcat -k mapname
If the map contents are not correct, edit the ASCII file from which
the map is generated. Then issue the following commands to
regenerate the map and push it to the slave servers:
cd /var/yp
/usr/ccs/bin/make mapname
Issue the domainname command (with no arguments) to make sure
the client’s default domain is the domain served by the NIS master
server. If it is not, log in as root to the NIS client, and issue the
following command to change its domain name:
domainname domainname
Issue the following command on the NIS client to check the contents
of the map on the NIS server to which the client is bound:
/usr/bin/ypcat -k mapname
If the contents are not correct, log in as root to the server that serves
the NIS client, and issue the following command:
/usr/sbin/ypxfr mapname
This command transfers the map from the NIS master server to the
server where you issue the command.
If the NIS client is bound to a slave server, make sure the slave
server is listed in the NIS master server’s ypservers database.
Follow these steps:
1. Issue the following command on the NIS client to determine
which server the client is bound to:
/usr/bin/ypwhich