NFS Services Administrator's Guide
Configuring and Administering NIS
Configuring and Administering an NIS Master Server
Chapter 4158
For more information, type man 4 hosts or man 1 sort at the HP-UX
prompt.
To Enable NIS Master Server Capability
1. Log in as root to the host that will be the master server.
2. On the host that will be the master server, ensure that the $PATH
environment variable includes the following directory paths:
• /var/yp
• /usr/lib/netsvc/yp
• /usr/ccs/bin
3. Issue the following command to set the NIS domain name:
/usr/bin/domainname domainname
If your host uses short file names, make sure the first 14 characters
of domainname uniquely identify your domain among the other NIS
domains in your network.
4. In the /etc/rc.config.d/namesvrs file, set the NIS_DOMAIN
variable to the domain name:
NIS_DOMAIN=domainname
5. In the /etc/rc.config.d/namesvrs file, set the
NIS_MASTER_SERVER and NIS_CLIENT variables to 1, as follows:
NIS_MASTER_SERVER=1
NIS_CLIENT=1
If the host that will be the master server is already a slave server for
another domain, set the NIS_MASTER_SERVER variable to 1 and the
NIS_SLAVE_SERVER variable to 0.
If the host is an NIS+ server or client, set the NISPLUS_SERVER and
NISPLUS_CLIENT flags to 0.
6. Issue the following command to create the NIS maps for the domain:
/usr/sbin/ypinit -m
The ypinit script will prompt you for the names of your slave
servers.
7. Enter the names of the slave servers.