The following procedure explains how to set up a slave server. Repeat this procedure for each machine you want configured as an NIS slave server.
For more information about obtaining the appropriate rights to perform specific tasks, see Using Your Assigned Administrative Rights in Securing Users and Processes in Oracle Solaris 11.2 .
Add the name and IP address of each of the other NIS servers. Use the following format: IPaddress FQDN-hostname aliases.
For example:
172.16.0.1 master.example.com master 172.16.0.2 slave1.example.com slave1 172.16.0.3 slave2.example.com slave2
# /usr/sbin/ypinit -c
The ypinit command prompts you for a list of NIS servers. Type the name of the local slave you are working on first, then type the name of the master server, followed by names of the other NIS slave servers in your domain. For the other slave servers, follow the order from the physically closest to the furthest in network terms.
# svcs \*nis\* STATE STIME FMRI online 20:32:56 svc:/network/nis/domain:default online 20:32:56 svc:/network/nis/client:default
If the services are displayed with an online state, then NIS is running. If the service state is disabled, then NIS is not running.
# svcadm restart network/nis/domain # svcadm restart network/nis/client
# svcadm enable network/nis/domain # svcadm enable network/nis/client
# svcs network/nis/server STATE STIME FMRI offline 20:32:56 svc:/network/nis/server:default
# svcadm restart network/nis/server
# svcadm enable network/nis/server
# /usr/sbin/ypinit –s master
where master is the machine name of the existing NIS master server.