O'Reilly logo

Linux in a Nutshell, Fourth Edition by Aaron Weber, Stephen Figgins, Ellen Siever

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Administering NIS

NIS is enabled by setting up NIS servers and NIS clients. The descriptions given here describe NIS setup using ypserv, which does not support a master/slave server configuration. All NIS commands depend on the RPC portmap program, so make sure it is installed and running before setting up NIS.

Setting Up an NIS Server

Setting up an NIS server involves the following steps:

  1. Set a domain name for NIS using domainname

  2. Edit the ypMakefile, which identifies which databases to build and what sources to use in building them

  3. Copy the ypMakefile to /var/yp/Makefile

  4. Run make from the /var/yp directory, which builds the databases and initializes the server

  5. Start ypserv, the NIS server daemon

Setting Up an NIS Client

Setting up an NIS client involves only the following steps:

  1. Set the domain name for NIS using domainname, which should be the same name used by the NIS server

  2. Run ypbind

NIS User Accounts

NIS networks have two kinds of user accounts: distributed and local. Distributed accounts must be administered from the master machine; they provide information that is uniform on each machine in an NIS domain. Changes made to distributed accounts are distributed via NIS maps. Local accounts are administered from the local computer; they provide account information unique to a specific machine. They are not affected by NIS maps, and changes made to local accounts do not affect NIS. When NIS is installed, preexisting accounts default to local accounts.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required