sendmail Desktop Reference

sendmail Desktop ReferenceSearch this book
Previous: 1.5 HintsChapter 2Next: 2.2 Delivery Agent Equates

2. The File

Delivery Agent Equates
Delivery Agent F= Flags
Defined Macros
Class Macros
The Timeout Option
Rule Sets
Delivery Agent S= and R=
The check_ Rule Sets
Wildcard Operators in the LHS
Positional Operators in the RHS
Other Operators in the RHS
Operators that Return a Triple
Conditional Operators

The sendmail configuration file, usually called, provides all the central information that controls the sendmail program's behavior. It lists the location of all the other files sendmail needs to access and the location of all the directories in which sendmail needs to create and remove files. It sets the definitions sendmail uses when rewriting addresses. It defines the rules and sets of rules sendmail uses for transforming mail addresses (and aliases for those addresses) into usable information, such as which delivery agent to use and the correct form of the address to use with that delivery agent.

2.1 Overview

Each line in the configuration files begins with a key character that defines the function of that line. Any character other than those shown here is an error.


Begins a comment line (the entire line is ignored).


Continues the previous line.


Continues the previous line.

Cw localhost

Adds localhost to class w (see §32.5.8).


Adds and to the multi-character class named {GuestDomains} (see §32.1.1).


Defines macro m with the value our.domain (see §31.10.24).


Defines multi-character macro name {OurOldDomain} with the value old.domain (see §31.3).


Assigns value /u/mail to the environmental variable HOME. (Such assignments are only available to delivery agents that sendmail executes.) (See 22.2.1.)


Imports the value of USER from the environment and makes it available to delivery agents.

Fw /etc/

Fills the class w with values read from the /etc/ file (see §19.6.26).

Fk |/usr/sbin/showuu

Runs the program /usr/sbin/showuu and fills the class k with values printed by that program. (see §32.5.2).

HDate: $a

Defines the Date: header with the value $a (see §35.10.10).

H?P?Return-Path: <$g>

Defines the Return-Path: header with the value <$g>. This header will only be output if the P in ?P? appears in the delivery agent's F= equate (see §35.4).

Kuid text -z: -k2 -v0 /etc/passwd

Declares a database named uid to be of class text, which will look up keys in the flat file named /etc/passwd (see §33.8.18). The -z:, -k2, and -v0 say that /etc/passwd has colon-delimited fields, that the key will be in the index 2 field, and the value in the index 0 field, thus converting uid values to login names, see §

Mname, equate=value, ...

Declares a mail delivery agent. The name is the symbolic name for this agent. The items in the equate list are described in the next section, "Delivery Agent Equates."

O MaxQueueRunSize=100

Gives the option MaxQueueRunSize the value 100 (see §34.8.38). Note that there must be a space between the O and the option name. Options are summarized later in this chapter.


Uses the old single-character name J to define the ForwardPath option (see §34.8.27).


Associates the symbolic name bulk with a delivery priority of -60. These symbolic names are compared to the Precedence: header (if one) during delivery, and used to begin a message's priority in the queue (see §35.8).

RLHS tabs RHS [tabs COMMENT ]

Defines a rewriting rule (do-while clause) where the RHS rewrites an address while the LHS comparison evaluates to true. The LHS and RHS must be separated by one or more tab characters. Optional tabs and a COMMENT may follow and are not part of the rewriting rule (see §28.1).


Declares a rule-set start to have the name name (where name is either a number or is symbolic text). When name is symbolic, an optional numeric value val may be assigned to it (see §29.1).

T bob jane

Declares that the users bob and jane are "trusted" and may use the -f command-line switch to precondition the sender identity. Users who are not trusted and who use the -f switch cause a warning to be included in the outgoing mail headers (see §22.8.1).


Specifies the version of the configuration file to be 7. An optional slash and a vendor identifier may follow, as /Berkeley (see §27.5).

Previous: 1.5 Hintssendmail Desktop ReferenceNext: 2.2 Delivery Agent Equates
1.5 Hints 2.2 Delivery Agent Equates