Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX Reference > S

service.switch(1M)

HP-UX 11i Version 3: February 2007
» 

Technical documentation

» Feedback
Content starts here

 » Table of Contents

 » Index

NAME

service.switch — indicate lookup sources and fallback mechanism

SYNOPSIS

/etc/mail/service.switch

DESCRIPTION

/etc/mail/service.switch is a sendmail(1M) service switch similar to /etc/nsswitch.conf (see nsswitch.conf(4)) that indicates the lookup source for hostnames and aliases. It consists of two lines, one for hosts and one for aliases. The lookup sources are listed after the hosts or aliases name.

For hosts, one or more of the following can be listed:

files (for /etc/hosts) dns (for Domain Name Service) nis (for NIS)

For aliases, one or more of the following can be listed:

files (for /etc/mail/aliases) nis (for NIS)

Sample Configurations

1.

The default configuration for service.switch is to use dns for hostname lookups and the aliases file for aliases. (Note that due to a bug, the hostname lookup will never fallback to a file lookup, so anything listed after dns will be ignored.)

hosts dns files aliases files

2.

To work with a non-DNS environment that uses file lookups (/etc/hosts), the following service.switch can be used:

hosts files aliases files

3.

To work with a NIS environment that does not use DNS, the following service.switch can be used:

hosts nis files aliases nis files

Modifying sendmail.cf

The sendmail.cf file must be modified to request the usage of the service.switch file. Otherwise, the default for sendmail.cf is to use DNS for hostname lookups, and files for alias lookups. To use NIS or files, the following line must be uncommented in sendmail.cf:

#O ServiceSwitchFile=/etc/mail/service.switch

SEE ALSO

sendmail(1M).

HISTORY

The service.switch file appeared in sendmail V8.

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 1983-2007 Hewlett-Packard Development Company, L.P.