Skip Navigation Links | |
Exit Print View | |
System Administration Guide: Naming and Directory Services (NIS+) |
Part I About Naming and Directory Services
Part II NIS+ Setup and Configuration
4. Configuring NIS+ With Scripts
5. Setting Up the NIS+ Root Domain
8. Configuring an NIS+ Non-Root Domain
10. NIS+ Tables and Information
12. Administering NIS+ Credentials
14. Administering Enhanced NIS+ Security Credentials
15. Administering NIS+ Access Rights
16. Administering NIS+ Passwords
18. Administering NIS+ Directories
20. NIS+ Server Use Customization
Default NIS+ Client Search Behavior
Designating NIS+ Preferred Servers
NIS+ Global Table or Local File
Default NIS+ Server Preferences
Efficiency and NIS+ Server Preference Numbers
Preferred-Only NIS+ Servers and All Servers
When NIS+ Server Preferences Take Effect
Viewing NIS+ Machine Preferences
How to View Preferences for an NIS+ Server
How to View Preferences for an NIS+ Machine
How to View Global Preferences for an NIS+ Machine
How to View Global Preferences for an NIS+ Subnet
Specifying NIS+ Preference Rank Numbers
Specifying NIS+ Global Server Preferences
How to Set Global Preferences for an NIS+ Subnet
How to Set Global Preferences for an Individual NIS+ Machine
How to Set Global Preferences for a Remote NIS+ Domain
Specifying Local NIS+ Server Preference
How to Set Preferences on a Local NIS+ Machine
Modifying NIS+ Server Preferences
How to Change an NIS+ Server's Preference Number
How to Replace One NIS+ Server With Another in a Preference List
Replacing an Entire Preferred Server List in NIS+
Specifying Preferred-Only Servers in NIS+
How to Specify Preferred-Only Servers in NIS+
How to Revert to Using Non-Preferred Servers in NIS+
Ending Use of Server Preferences in NIS+
Eliminating Local Server Preferences in NIS+
How to Switch From Local to Global Subnet Preferences in NIS+
How to Switch From Local to Machine-Specific Global Preferences in NIS+
How to Stop a Machine From Using Any Server Preferences in NIS+
Putting NIS+ Server Preferences Into Immediate Effect
23. Information in NIS+ Tables
Common NIS+ Namespace Error Messages
You can change a server's preference number and switch (replace) the preference numbers assigned to different servers.
To change preferred servers or the preference number assigned to a server, run nisprefadm with the -m oldserver-=newserver(n) option.
#nisprefadm -L|-G -C name -m oldserver=newserver(n)
Where:
-L|-G determines whether you are modifying a local file or a global table.
-C name is the IP number of a subnet or the name of a machine. This option is only used when you are also using the -G option. The modifications you make with this command apply to the subnet or machine that you name.
-m is the modify server list option.
old server is the name of the server whose preference number you want to change.
new server(n) is the server name and its new preference number.
For example, on the deneb machine, to change the number given to the replica6.manf server to 2 in deneb's local client_info file:
deneb# nisprefadm -L -m replica6.manf=replica6.manf(2)
To change one server for another in a preference list:
#nisprefadm -L|-G -C name -m \ oldserver=newserver(prefnumber)
Where:
-L|-G determine whether you are modifying a local or a domain-wide server list.
-C name is the IP number of a subnet or the name of a machine. This option is only used in when you are also using the -G option. The modifications you make with this command apply to the subnet or machine that you name.
-m is the modify-server-list option.
oldserver is the old server you are replacing.
newserver(prefnumber) is the new server (with an optional preference number) that is taking the old server's place in the preferred server list.
Keep in mind that when you replace a server in a global client_info table using the -G option, the replacement only applies to the subnet or machine identified by the -C option. Other listings of the replaced server are not affected.
For example, suppose you have a domain with three subnets, and the replica1 server is listed as a preferred server for two of those subnets. If replica1 is obsolete and you take it out of service, you then run nisprefadm -m to replace it with the new server for the first subnet. Until you do the same for the second subnet, replica1 is still listed as a preferred server for that subnet. The same principle applies to preferred servers for individual machines.
For example, to replace the replica3 server with the replica6 server for subnet 172.21.123.12 in the domain's global client_info table and assign replica6 a preference number of 1:
nismaster# nisprefadm -G -C 172.21.123.12 -m replica3 replica6(1)
To remove one or more servers from a preference list:
#nisprefadm -L|-G -C name -r servers
Where:
-L|-G determines whether you are modifying a local or a domain-wide server list.
-C name is the IP number of a subnet or the name of a machine. This option is only used when you are also using the -G option. The preferred servers you remove with this command apply to the subnet or machine that you name.
-r removes the named servers from the list.
For example, in the domain's global client_info table, to remove the replica3 and replica6.manf servers for the machine polaris:
polaris# nisprefadm -G -C polaris -r replica3 replica6.manf