JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
System Administration Guide: Naming and Directory Services (NIS+)
search filter icon
search icon

Document Information

Preface

Part I About Naming and Directory Services

1.  Name Service Switch

Part II NIS+ Setup and Configuration

2.  NIS+: An Introduction

3.  NIS+ Setup Scripts

4.  Configuring NIS+ With Scripts

NIS+ Configuration Overview

NIS+ and the Service Management Facility

Using svcadm With rpc.nisd -x

Modifying the /lib/svc/method/nisplus File

Creating a Sample NIS+ Namespace

Summary of NIS+ Scripts Command Lines

Setting Up NIS+ Root Servers

Prerequisites to Running nisserver to Set Up a Root Server

How to Create an NIS+ Root Master Server

How to Change Incorrect Information When Setting Up NIS+

How to Set Up a Multihomed NIS+ Root Master Server

Populating NIS+ Tables

Prerequisites to Running nispopulate to Populate Root Server Tables

How to Populate the NIS+ Root Master Server Tables

Setting Up NIS+ Client Machines

How to Initialize a New NIS+ Client Machine

Creating Additional NIS+ Client Machines

Initializing NIS+ Client Users

How to Initialize an NIS+ User

Setting Up NIS+ Servers

Configuring a Client as an NIS+ Server

How to Configure an NIS+ Server Without NIS Compatibility

How to Configure an NIS+ Server With NIS Compatibility

How to Configure an NIS+ Server With DNS Forwarding and NIS Compatibility

Creating Additional NIS+ Servers

Creating an NIS+ Root Replica Server

How to Create an NIS+ Root Replica

How to Set Up Multihomed NIS+ Replica Servers

Creating an NIS+ Subdomain

How to Create a New Non-Root NIS+ Domain

Creating Additional NIS+ Domains

Populating the New NIS+ Subdomain's Tables

Prerequisites to Populating a NIS+ Subdomain's Tables

Populating the NIS+ Master Server Tables

How to Populate the NIS+ Tables From Files

How to Populate the NIS+ Tables From NIS Maps

Creating NIS+ Subdomain Replicas

How to Create an NIS+ Replica

Initializing NIS+ Subdomain Client Machines

How to Initialize an NIS+ Subdomain Client Machine

Initializing an NIS+ Subdomain Client Users

How to Initialize an NIS+ Subdomain User

Summary of Commands for the Sample NIS+ Namespace

5.  Setting Up the NIS+ Root Domain

6.  Configuring NIS+ Clients

7.  Configuring NIS+ Servers

8.  Configuring an NIS+ Non-Root Domain

9.  Setting Up NIS+ Tables

Part III NIS+ Administration

10.  NIS+ Tables and Information

11.  NIS+ Security Overview

12.  Administering NIS+ Credentials

13.  Administering NIS+ Keys

14.  Administering Enhanced NIS+ Security Credentials

15.  Administering NIS+ Access Rights

16.  Administering NIS+ Passwords

17.  Administering NIS+ Groups

18.  Administering NIS+ Directories

19.  Administering NIS+ Tables

20.  NIS+ Server Use Customization

21.  NIS+ Backup and Restore

22.  Removing NIS+

23.  Information in NIS+ Tables

24.  NIS+ Troubleshooting

A.  NIS+ Error Messages

About NIS+ Error Messages

Common NIS+ Namespace Error Messages

B.  Updates to NIS+ During the Solaris 10 Release

Solaris 10 and NIS+

Glossary

Index

Creating a Sample NIS+ Namespace

The procedures in this chapter show you how to create a sample NIS+ namespace. The sample NIS+ namespace will be created from /etc files and NIS maps. This sample shows you how to use the scripts both when your site is not running NIS and when NIS is running at your site. You can set your servers to NIS-compatibility mode if they will be serving NIS clients. See Solaris 1 Release and NIS-Compatibility Mode for more information on NIS-compatibility mode.


Note - Your site's actual NIS+ namespace and its domain hierarchy probably differs from the sample namespace's, and yours probably contains a different number of servers, clients, and domains. Do not expect any resemblance between your final domain configuration or hierarchy and the sample one. The sample namespace is only an illustration of how to use the NIS+ scripts. After you have created this sample namespace, you should have a clear idea about how to create domains, servers, and clients at your site.


The sample namespace contains the following components:

This scenario shows the scripts being used to configure NIS+ at a site that uses both system information files, such as /etc/hosts, and NIS maps to store network service information. The sample NIS+ namespace uses such a mixed site purely for example purposes.

Summary of NIS+ Scripts Command Lines

Table 4-2 contains the generic sequence of NIS+ scripts and commands you will use to create a ample NIS+ domain. Subsequent sections describe these command lines in detail. After you are familiar with the tasks required to create NIS+ domains, servers, and clients, use Table 4-2 as a quick-reference guide to the appropriate command lines. Table 4-2 is a summary of the actual commands with the appropriate variables that you type to create the sample NIS+ namespace.

Table 4-2 NIS+ Domains Configuration Command Lines Summary

Action
Machine
Command
Include /usr/lib/nis in root's path; C shell or Bourne shell.
Root master server and client machines as superuser
setenv PATH $PATH:/usr/lib/nis

or

PATH=$PATH:/usr/lib/nis; export PATH

Optionally, if using DES authentication, select the Diffie-Hellman key length
Server and client machines as superuser
nisauthconf -dhkey-length-alg-type des
Create a root master server without or with NIS (YP) compatibility.
Root master server as superuser
nisserver -r-dnewdomain.

or

nisserver -Y-r-d newdomain.

Populate the root master server tables from files or from NIS maps.
Root master server as superuser
nispopulate -F-p /files -d newdomain.

or

nispopulate -Y-d newdomain. -h NISservername\ -a NIS_server_ipaddress -y NIS_domain

Add additional users to the NIS+ admin group.
Root master server as superuser
nisgrpadm-aadmin.domain.name.domain.
Make a checkpoint of the NIS+ database.
Root master server as superuser
nisping -C domain.
Initialize a new client machine.
Client machine as superuser
nisclient -i-d domain. -h master1
Initialize user as an NIS+ client.
Client machine as user
nisclient -u
Start the NIS+ service (rpc.nisd daemon) – required to convert a client to a server without or with NIS compatibility (and DNS forwarding).
Client machine as superuser
Modify the /lib/svc/method/nisplus file to add the -Y or -B options as needed, then enable the NIS+ service:

svcadm enable /network/rpc/nisplus

Convert a server to a root replica.
Root master server as superuser
nisserver-R-d domain. -h clientname
Convert a server to a non-root master server.
Root master server as superuser
nisserver -M-d newsubdomain.domain. -h\clientmachine
Populate the new master server tables from files or from NIS maps.
New subdomain master server as superuser
nispopulate -F-p/subdomaindirectory -d \ newsubdomain.domain.

or

nispopulate-Y-dnewsubdomain.domain.-h NISservername -aNIS_server_ipaddress -y NIS_domain

Convert a client to a master server replica.
Subdomain master server as superuser
nisserver-R-dsubdomain.domain. -h clientname
Initialize a new client of the subdomain. Clients can be converted to subdomain replicas or to another server.
New subdomain client machine as superuser
nisclient -i -d newsubdomain.domain. -h \ subdomainmaster
Initialize user as an NIS+ client.
Client machine as user
nisclient -u

Note - To see what commands an NIS+ script calls, without actually executing the commands, use the -x option. The -x option causes the command names and their approximate output to echo to the screen as if you were actually running the script. Running the scripts for the first time with -x can minimize unexpected results. For more information, see the man pages for the scripts.