Академический Документы
Профессиональный Документы
Культура Документы
# ps ef |grep yp
/usr/lib/netsvc/yp/ypbind
/usr/lib/netsvc/yp/ypserv -d
/usr/lib/netsvc/yp/ypxfrd
/usr/lib/netsvc/yp/rpc.yppasswdd -D /var/yp/src -m
/usr/lib/netsvc/yp/rpc.ypupdated
Note: For Solaris 10, ypstart is automatically invoked from ypinit -m. Use the svcs utility to view the state of the services.
# /usr/bin/svcs \*nis\*
STATE
STIME FMRI
disabled
13:14:59 svc:/network/rpc/nisplus:default
online
13:28:34 svc:/network/nis/server:default
online
13:28:34 svc:/network/nis/xfr:default
online
13:28:34 svc:/network/nis/update:default
online
13:28:34 svc:/network/nis/passwd:default
online
13:28:35 svc:/network/nis/client:default
# ypwhich -m
NOTE: All the resulting NIS maps will be stored under /var/yp/example-domain directory.
10. To enable this host as a NIS client.
# cp /etc/nsswitch.nis /etc/nsswitch.conf
Edit /etc/nsswitch.conf as necessary (ie. add dns entry).
Note: To control NIS services from the command line:
# /usr/lib/netsvc/yp/ypstop (to stop NIS services)
# /usr/lib/netsvc/yp/ypstart (to start NIS services)
For Solaris 10, you can use:
# ypstop
or
# svcadm disable network/nis/server:default
# svcadm disable network/nis/client:default
# ypstart
or
# svcadm enable network/nis/server:default
# svcadm enable network/nis/client:default
# ypstop; ypstart (restart NIS Services)
or
# svcadm restart network/nis/server:default
# svcadm restart network/nis/client:default
Note: See man page securenets(4) for restricting access and use of /var/yp/securenets file.
# ypstop
or
# svcadm disable network/nis/client:default
# ypstart
or
# svcadm enable network/nis/client:default
# ypstop; ypstart
or
# svcadm restart network/nis/client:default
7. ypwhich m
On the newly configured NIS client, test the NIS functionality by the above command. The output should include the name of the
NIS master server along with the database maps its serving.