Previous Table of Contents Next

Table 5-8 lists the locations that the /etc/nsswitch.conf file can search for information:

Table 5-8 Location of Name Service Information

Location Description
files File on the client’s local system
nisplus An NIS+ table
nis An NIS map
compat Supports old-style “+” syntax for passwd and group
dns Applies only to the hosts entry

When NIS+ searches one or more of these locations, it returns one of the four status messages listed in Table 5-9.

Table 5-9 Name Service Switch Status Messages

Status Message Description
SUCCESS Found a valid result
UNAVAIL Could not use the source
NOTFOUND Information not in the source
TRYAGAIN Source returned an “I’m busy, try later” code

In the /etc/nsswitch.conf file, you can specify what action NIS+ should take when it returns one of these status messages. The actions you can specify are the following:

  continue—try the next source
  return—stop trying, and return this result

If no action is specified in the /etc/nsswitch.conf file, NIS+ uses the default value [NOTFOUND=continue].

The entries in the /etc/nsswitch.conf file use the following syntax:

table: location [location...] [status=action] [location]

The table variable contains the name of the NIS map, the NIS+ table, or the /etc file. The location variable specifies the first place for the system to search, using any of the locations shown in Table 5-8. If you want, you can specify additional locations to search. You can also specify an action (continue or return) if one of the status messages shown in Table 5-9 is encountered. An example of the default /etc/nsswitch.nisplus file is shown in Chapter 6.

In the default NIS+ file, local /etc files are not consulted for hosts, services, networks, protocols, rpc, ethers, netmasks, and bootparams unless NIS+ is down. If the entry is not found, the [NOTFOUND=return] entry prevents NIS+ from consulting the /etc files. If you want NIS+ to consult the appropriate /etc file on the local system when an entry is not found in the NIS+ table, edit the default file and remove the [NOTFOUND=return] entries.

NIS+ Administration

When NIS+ is configured on the network, you can use either Solstice AdminSuite’s Database Manager or the NIS+ commands to administer NIS+. SunSoft recommends that at least one administrator be familiar with all of the NIS+ commands.


You can use the unbundled AdminSuite Database Manager to administer most of the tables in the org_dir directory. Consult the Solstice AdminSuite 2.3 Administration Guide for information about using AdminSuite.

NOTE:  If you have a large site, you may want to use the NIS+ commands instead of AdminSuite; displaying large databases can be time-consuming.

NIS+ Commands

A major advantage of NIS+ over NIS is that you have direct read-write access to information served by NIS+ through the command-line and programmatic interface. You can further fine-tune control of this access using the NIS+ security authentication and access mechanisms.

The command-line interface lets you change NIS+ tables and directories on servers significantly more easily and quickly without first creating text files and converting them into databases.

Tasks such as adding users and systems to a domain require changing information only in that domain’s NIS+ directory. You can also perform these operations remotely—from systems around the domain—without needing superuser privileges or rlogin access to the NIS+ master servers.

Because you have read-write programmatic access to NIS+ information, you can develop interactive and innovative system administration applications on top of NIS+. NIS+ is used by all Solaris distributed system management applications as the storage facility for administrative data.

Figure 5-9 introduces the NIS+ commands. It also shows which NIS commands are available for compatibility with NIS+ and which NIS commands are not available with Solaris 2.x system software.

Figure 5-9  Overview of name services commands.

Previous Table of Contents Next