274
16.5.1 Procmail Configuration
Procmail configuration files, most notably the user's .procmailrc, contain important environmen-
tal variables. These variables tell Procmail which messages to sort, what to do with the messages that
do not match any recipes, and so on.
These environmental variables usually appear in the .procmailrc file at the beginning, in the fol-
lowing format, each on their own line:
Figure 16–7 Structure of an environmental variable line
<env-variable> =" <value> "
In this example, the <env-variable> is the name of the variable, and the <value> section defines
the variable.
Many environment variables are not used by most Procmail users, and many of the more important
environment variables are already defined a default value. Most of the time, you will be dealing with
the following variables:
•
DEFAULT — Sets the default mailbox where messages that do not match any recipes will be
placed.
The default DEFAULT value is the same as $ORGMAIL.
•
INCLUDERC — Specifies additional rc files containing more recipes for messages to be checked
against. This allows you to break up your Procmail recipe lists into individual files that fulfill
different roles, such as blocking spam and managing email lists, that can then be turned off or on
by using comment characters in the user's .procmailrc file.
For example, two lines in a user's .procmailrc file may look like this:
Figure 16–8 Example of the INCLUDERC option in use
MAILDIR=$HOME/Msgs
INCLUDERC=$MAILDIR/lists.rc
INCLUDERC=$MAILDIR/spam.rc
If the user would like to turn off the Procmail filtering of their email lists but leave spam control
in place, they could simple comment out the first INCLUDERC line with a # character.
•
LOCKSLEEP — Sets the amount of time, in seconds, between attempts by Procmail to use a
particular lockfile. The default is eight seconds.
•
LOCKTIMEOUT — Sets the amount of time, in seconds, that must pass after a lockfile was last
modified before Procmail will assume that the lockfile is simply old and can be deleted. The
default is 1024 seconds.
•
LOGFILE — The location and file to contain any Procmail informational or error messages.
Chapter 16:Email
Need help?
Do you have a question about the LINUX 7.2 and is the answer not in the manual?
Questions and answers