[Next] [Previous] [Up] [Top] [Contents]

21.2 NIS

21.2.2 Databases controlled by NIS

The information in the NIS maps is in a database format using the ndbm library. Each map has 2 files: .pag, and .dir. These are contained in a subdirectory of /var/yp named after your NIS "domain". The databases are:

Name Service
aliases mail aliases and addresses
bootparams boot and NFS mount information for diskless clients
ethers hostname and ethernet addresses
group group names and gid's
hosts hostname and internet addresses
netgroup netgroup membership list
netid map of local userID/groupID/group access-list and hosts for DES
netmasks network number and netmask
networks network number and internet name
passwd username and password information
protocols internet protocol names and numbers
publickey public and secret keys for secure NFS
rpc RPC program name and number
services internet service name, port number, and protocol

To tell the SunOS 4.1.X system to use the NIS database for passwd and group files put entries such as:

+::0:0:::

as the last entry in the /etc/passwd file of the NIS clients, i.e. all NIS password entries are valid on this host. Other examples of limitations and exclusions are, for /etc/passwd:

+frank: - frank is a valid user, use his entry from the NIS database.

+frank:::::/home/new/frank: - frank is a valid user, all entries are as in the NIS database, except his
login directory.

+@group:*:0:0:::/bin/true - the group "group" can't login, but users in this group can refer to their home directories.

-@group::0:0::: - exclude this group from entry.

and for /etc/group:

+: - all entries in the NIS group database are valid here.

+group: - the NIS group "group" is valid.

+project:::frank,bob - only the member frank and bob of group "project" are valid.

SunOS 5.X clients will use the NIS database if nis and compat (for NIS +/- entry compatibility) are specified for the passwd entry in /etc/nsswitch.conf, e.g.:

passwd: compat files nis

To use the default NIS passwd table there is no need to add additional entries to /etc/passwd on the SunOS 5.X client.


Unix System Administration - 8 AUG 1996
[Next] [Previous] [Up] [Top] [Contents]