NIS Client Networking  «Prev  Next»

NIS Command Matching

In this exercise, you were asked to match the commands with their corresponding definitions. Below are the results.
  1. yppoll: Returns the server name and NIS version for a given database
  2. ypmatch: Lists the values of keys within a database
  3. ypcat: Lists the entire contents of a given database
  4. ypwhich: Returns the name of the NIS server used, or the master server for a given database
  5. ypbind: The client-side NIS daemon

Network Information System servers

Network Information System (NIS) is a software feature developed by Sun Microsystems to manage information needed to configure a group of UNIX (and now Linux) computers on a network. Using NIS, a group of computers can share common passwd, groups, hosts, and other configuration files. By default, NIS services are off. You can turn on NIS services for your Linux computer as either an NIS client (using shared information) or an NIS server (distributing shared information). NIS client computers need to start the /etc/init.d/ypbind script and identify the NIS servers in the /etc/yp.conf file.
To use Fedora or RHEL as an NIS server, you must gather up the configuration files you want to share, then start the /etc/init.d/ypserv script. The script runs the /usr/sbin/ypserv daemon, which takes care of the distribution of information to the NIS client computers.

Configuring NIS Server daemons

The NIS server must be running several daemon processes to be an NIS server. Red Hat Linux supplies several run-level scripts that you can configure to start NIS server daemon processes. These scripts, located in the /etc/init.d directory, include the following:
  1. ypserv: This script starts the ypserv (/usr/sbin/ypserv) daemon. It reads information from the /etc/ypserv.conf file to determine what to do. Then it listens for requests from NIS client computers on the network.
  2. yppasswdd: This script starts the rpc.yppasswdd (/usr/sbin/rpc.yppasswdd) daemon. This daemon handles requests from users on NIS client computers who want to change their user passwords.

Unless you requested that these scripts be configured to start at boot-time when you installed Red Hat Linux, they will not start automatically. You can use the following chkconfig command to set ypserv and yppasswdd scripts to start automatically at boot time.
# chkconfig ypserv on
# chkconfig yppasswdd on

If you want to start the services immediately, you can type the following:
# /etc/init.d/ypserv start
# /etc/init.d/yppasswdd start

The NIS master server should be up and running. If there are any NIS slave servers, you should configure them now.