Specifies the ordering of certain name resolution services.
The /etc/netsvc.conf file is used to specify the ordering of name resolution for the sendmail command, gethostbyname subroutine, gethostaddr subroutine, and gethostent subroutine and alias resolution for the sendmail command.
Several mechanisms for resolving host names and aliases are available. The gethostbyname, gethostbyaddr, and gethostent subroutines use these mechanisms for resolving names. A default order exists in which the resolver subroutines try the mechanisms for resolving host names and Internet Protocol (IP) addresses.
You can override the default order and the order given in the /etc/irs.conf file by creating the /etc/netsvc.conf configuration file and specifying the desired ordering. To specify this host ordering, create an entry in the following format:
hosts = value [, value]
Use one or more of the following values for the hosts
keyword:
The environment variable NSORDER overrides the host settings in the /etc/netsvc.conf file, which in turn overrides the host settings in the /etc/irs.conf file.
The sendmail command searches the local /etc/aliases file, or uses NIS if specified for resolving aliases. You can override the default by specifying how to resolve aliases in the /etc/netsvc.conf file. To specify alias ordering to the sendmail command, enter the following:
alias = value [, value]
Use one or more of the following values for the alias
keyword:
files | Searches the local /etc/aliases file for the alias |
nis | Uses NIS services for resolving alias |
The order is specified on one line with values separated by commas. White spaces are permitted around the commas and the equal sign. The values specified and their ordering are dependent on the network configuration.
hosts = local
hosts = local , nis
hosts = ldap = auth , bind
In this example, if the resolver cannot contact the LDAP server, then it searches the BIND service.
aliases = nis
/etc/netsvc.conf | Specifies the path to the file. |
The aliases file for mail, irs.conf file, hosts file format for TCP/IP.
The sendmail command.
The gethostbyname subroutine, gethostbyaddr subroutine, and gethostent subroutine.
TCP/IP Name Resolution in AIX 5L Version 5.1 System Management Guide: Communications and Networks