ypfiles(4)ypfiles(4)NAMEypfiles - Network Information Service database and directory structure
DESCRIPTION
The Network Information Service (NIS) was formerly known as Yellow
Pages (YP).
Although the name has changed, the functionality of the ser‐
vice remains the same.
The Network Information Service (NIS) network lookup service uses data‐
bases in the directory hierarchy under These databases exist only on
machines that act as NIS servers. A database consists of two files
created by (see makedbm(1M)). One has the filename extension and the
other has the filename extension For example, the database named is
implemented by the pair of files and A database served by the NIS is
called an NIS map.
An NIS domain is a named set of Network Information Service maps. Each
NIS domain is implemented as a subdirectory of (whose name is the
domain name) and contains the maps for that domain. Any number of NIS
domains can exist, and each can contain any number of maps.
Besides the databases contained in master NIS servers have files named
that reside there, too. These files are merely empty files whose times
of last modification are compared with those of the ASCII files from
which the maps are built. The script performs these comparisons to
determine whether the maps are current (see ypmake(1M)). The gen‐
eral_NIS_mapname designation is described further in the section below.
The NIS lookup service does not require maps, although maps may be
required for the normal operation of other parts of the system. The
list of maps an NIS server provides access to is neither restricted nor
must it be all-inclusive. If a map exists in a given domain and a
client asks about it, the NIS serves it. For a map to be consistently
accessible, it must exist on all NIS servers that serve the domain. To
provide data uniformity between the replicated maps, make an entry to
run periodically in root's file on each server (see ypxfr(1M) and
crontab(1)). More information on this topic is in yppush(1M) and
ypxfr(1M).
NIS maps contain two special key-value pairs. The first key,
NIS_LAST_MODIFIED, has a 10-character (ASCII) order number as a value.
The order number is the in seconds when the map was built (see
time(2)). The second key is NIS_MASTER_NAME, whose value is the host
name of the map's master NIS server. The command generates both key-
value pairs automatically. The command uses these values when it
transfers a map from one NIS server to another.
Generate and modify NIS maps only on the master server. They are
copied to the slaves using to avoid potential byte-ordering problems
among NIS servers running on machines with different architectures, and
to minimize the disk space required for the databases (see ypxfr(1M)).
NIS databases can be created initially for both masters and slaves by
using (see ypinit(1M)).
After servers' databases are created, the contents of some maps will
change. Generally, an ASCII source version of each database exists on
the master, and is changed with a text editor. The NIS map is rebuilt
to include the changes, and propagated from the master to the slaves by
running the shell script (see ypmake(1M)).
All standard NIS maps are built by commands contained in the script or
the NIS If you add a non-standard NIS map, edit the script or to sup‐
port the new map (standard NIS maps are discussed under below). and
use to generate the NIS maps on the master and may run to copy the
rebuilt maps to the slaves (see yppush(1M)). The command reads the map
named that contains the host names of all NIS servers for the specific
domain. For more information, see ypmake(1M), yppush(1M), and
ypxfr(1M).
Standard nicknames are defined in the file These names can be used in
place of the full map name in the and commands. Use the command to
display the current set of nicknames. Use the command to display all
the available maps. Each line of the nickname file contains two fields
separated by white space. The first field is the nickname, and the
second field is the name of the map that it expands to. The nickname
cannot contain a period
DEPENDENCIES
If is in a file system that does not allow file names longer than 14
characters and you want to create a new non-standard map for the Net‐
work Information Service, its name must not exceed 10 characters in
length. This rule exists because adds the 4-character suffixes and to
any mapname.
The following table describes the translation of standard NIS mapnames
to shorter names for storage on a 14-character filename file system.
The standard mapnames should be used by NIS clients on HP machines when
making requests, regardless of which machine is the NIS server.
┌─────────────────────┬─────────────────────┐
│Standard NIS Mapname │ Abbreviated Mapname │
├─────────────────────┼─────────────────────┤
│auto.master │ auto.mast │
│ethers.byaddr │ ether.byad │
│ethers.byname │ ether.byna │
│group.bygid │ group.bygi │
│group.byname │ group.byna │
│hosts.byaddr │ hosts.byad │
│hosts.byname │ hosts.byna │
│ipnodes.byaddr │ ip.byad │
│ipnodes.byname │ ip.byna │
│mail.aliases │ mail.alias │
│mail.byaddr │ mail.byad │
│netgroup │ netgroup │
│netgroup.byhost │ netgr.byho │
│netgroup.byuser │ netgr.byus │
│netid.byname │ netid.byn │
│networks.byaddr │ netwk.byad │
│networks.byname │ netwk.byna │
│passwd.byname │ passw.byna │
│passwd.byuid │ passw.byui │
│protocols.byname │ proto.byna │
│protocols.bynumber │ proto.bynu │
│publickey.byname │ pbkey.byna │
│rpc.byname │ rpc.byna │
│rpc.bynumber │ rpc.bynu │
│services.byname │ servi.byna │
│ypservers │ ypservers │
├─────────────────────┼─────────────────────┤
└─────────────────────┴─────────────────────┘
AUTHORypfiles was developed by Sun Microsystems, Inc.
FILES
The following table presents information about the standard Network
Information Service maps.
The General NIS Mapname column lists names for sets of NIS maps; the
sets include adjacent entries from the Standard NIS Mapname column.
The ASCII Source column lists the ASCII files from which the maps are
usually built on HP master NIS servers. The script permits the source
directory, or file in the case of the passwd maps, to vary.
The Standard NIS Mapname column lists names by which maps are stored on
NIS servers and referred to by NIS clients.
┌────────────┬───────────────────┬────────────────────┐
│General NIS │ ASCII Source │ Standard NIS │
│Mapname │ │ Mapname │
├────────────┼───────────────────┼────────────────────┤
│aliases │ /etc/mail/aliases │ mail.aliases │
│ │ │ mail.byaddr │
│automounter │ /etc/auto_master │ auto.master │
│ethers │ * │ ethers.byaddr │
│ │ │ ethers.byname │
│group │ /etc/group │ group.byname │
│ │ │ group.bygid │
│hosts │ /etc/hosts │ hosts.byname │
│ │ │ hosts.byaddr │
│ipnodes │ /etc/hosts │ ipnodes.byname │
│ │ │ ipnodes.byaddr │
│netgroup │ /etc/netgroup │ netgroup │
│ │ │ netgroup.byhost │
│ │ │ netgroup.byuser │
│netid │ /etc/netid │ netid.byname │
│networks │ /etc/networks │ network.byaddr │
│ │ │ network.byname │
│passwd │ /etc/passwd │ passwd.byname │
│ │ │ passwd.byuid │
│protocols │ /etc/protocols │ protocols.byname │
│ │ │ protocols.bynumber │
│publickey │ /etc/publickey │ publickey.byname │
│rpc │ /etc/rpc │ rpc.byname │
│ │ │ rcp.bynumber │
│services │ /etc/services │ servi.bynp │
│ │ │ services.byname │
│ypservers │ ** │ ypservers │
├────────────┼───────────────────┼────────────────────┤
└────────────┴───────────────────┴────────────────────┘
These databases are not built on HP
master Network Information Service servers. However, if
an HP machine is a slave to a master NIS server that cre‐
ates and distributes these databases, the HP slave NIS
server will store these databases. It is suggested that
if you have a non-HP machine that requires these maps,
make that machine the master NIS server. By doing this,
the maps should be built as needed.
No ASCII
source exists for the database. It is created from
responses provided by the user of on the master NIS
server, and it has no matching file.
SEE ALSOdomainname(1), makedbm(1M), rpcinfo(1M), ypinit(1M), ypmake(1M),
yppoll(1M), yppush(1M), ypserv(1M), ypxfr(1M).
ypfiles(4)