Solaris 10 Installation Guide: Network-Based Installations

name_service Keyword

You can use the name_service keyword to configure the name service, the domain name, and the name server for the system. The following sample shows the general syntax for the name_service keyword.


name_service=name-service {domain_name=domain-name 
                                 name_server=name-server
                                 optional-keyword=value}

Choose only one value for name_service. Include all or none of the domain_name,name_server, or optional keywords, as needed. If no keywords are used, omit the curly braces {}.

The following sections describe the keyword syntax to configure the system to use a specific name service.

NIS Syntax for name_service Keyword

Use the following syntax to configure the system to use the NIS name service.


name_service=NIS {domain_name=domain-name 
                   name_server=hostname(ip-address)}
domain-name

Specifies the domain name

hostname

Specifies the host name of the name server

ip-address

Specifies the IP address of the name server


Example 6–1 Specifying a NIS Server With the name_service Keyword

The following example specifies a NIS server with the domain name west.example.com. The server's host name is timber, and the server IP address is 192.168.2.1.


name_service=NIS {domain_name=west.example.com 
                  name_server=timber(192.168.2.1)}

For more information about the NIS name service, see System Administration Guide: Naming and Directory Services (DNS, NIS, and LDAP).

NIS+ Syntax for name_service Keyword

Use the following syntax to configure the system to use the NIS name service.


name_service=NIS+ {domain_name=domain-name 
                   name_server=hostname(ip-address)}
domain-name

Specifies the domain name

hostname

Specifies the host name of the name server

ip-address

Specifies the IP address of the name server


Example 6–2 Specifying a NIS+ Server With the name_service Keyword

The following example specifies a NIS+ server with the domain name west.example.com. The server's host name is timber, and the server IP address is 192.168.2.1.


name_service=NIS+ {domain_name=west.example.com 
                   name_server=timber(192.168.2.1)}

For more information about the NIS+ name service, see System Administration Guide: Naming and Directory Services (NIS+).

DNS Syntax for name_service Keyword

Use the following syntax to configure the system to use DNS.


name_service=DNS {domain_name=domain-name 
                  name_server=ip-address,ip-address,ip-address
                  search=domain-name,domain-name,domain-name,
                  domain-name,domain-name,domain-name} 
domain_name=domain-name

Specifies the domain name.

name_server=ip-address

Specifies the IP address of the DNS server. You can specify up to three IP addresses as values for the name_server keyword.

search=domain-name

(Optional) Specifies additional domains to search for name service information. You can specify up to six domain names to search. The total length of each search entry cannot exceed 250 characters.


Example 6–3 Specifying a DNS Server With the name_service Keyword

The following example specifies a DNS server with the domain name west.example.com. The server IP addresses are 10.0.1.10 and 10.0.1.20. example.com and east.example.com are listed as additional domains to search for name service information.


name_service=DNS {domain_name=west.example.com 
                  name_server=10.0.1.10,10.0.1.20 
                  search=example.com,east.example.com}

For more information about the DNS name service, see System Administration Guide: Naming and Directory Services (DNS, NIS, and LDAP).

LDAP Syntax for name_service Keyword

Use the following syntax to configure the system to use LDAP.


name_service=LDAP {domain_name=domain_name
                   profile=profile_name profile_server=ip_address 
                   proxy_dn="proxy_bind_dn" proxy_password=password}
domain_name

Specifies the domain name of the LDAP server.

profile_name

Specifies the name of the LDAP profile you want to use to configure the system.

ip_address

Specifies the IP address of the LDAP profile server.

proxy_bind_dn

(Optional) Specifies the proxy bind distinguished name. You must enclose the proxy_bind_dn value in double quotes.

password

(Optional) Specifies the client proxy password.


Example 6–4 Specifying an LDAP Server With the name_service Keyword

The following example specifies an LDAP server with the following configuration information.


name_service=LDAP {domain_name=west.example.com 
                   profile=default 
                   profile_server=172.31.2.1 
                   proxy_dn="cn=proxyagent,ou=profile,
                   dc=west,dc=example,dc=com" 
                   proxy_password=password}

For more information about how to use LDAP, see System Administration Guide: Naming and Directory Services (DNS, NIS, and LDAP).