Configure the name service switch table
You must configure the name service switch table correctly to enable ONTAP to consult local or external name services to retrieve host, user, group, netgroup, or name mapping information.
You must have decided which name services you want to use for host, user, group, netgroup, or name mapping as applicable to your environment.
If you plan to use netgroups, all IPv6 addresses specified in netgroups must be shortened and compressed as specified in RFC 5952.
Do not include information sources that are not being used. For example, if NIS is not being used in your environment, do not specify the -sources nis
option.
-
Add the necessary entries to the name service switch table:
vserver services name-service ns-switch create -vserver vserver_name -database database_name -sources source_names
-
Verify that the name service switch table contains the expected entries in the desired order:
vserver services name-service ns-switch show -vserver vserver_name
If you want to make any corrections, you must use the
vserver services name-service ns-switch modify
orvserver services name-service ns-switch delete
commands.
The following example creates a new entry in the name service switch table for the SVM vs1 to use the local netgroup file and an external NIS server to look up netgroup information in that order:
cluster::> vserver services name-service ns-switch create -vserver vs1 -database netgroup -sources files,nis
-
You must configure the name services you have specified for the SVM to provide data access.
-
If you delete any name service for the SVM, you must remove it from the name service switch table as well.
The client access to the storage system might not work as expected, if you fail to delete the name service from the name service switch table.