353 lines
6.8 KiB
HTML
353 lines
6.8 KiB
HTML
<HTML
|
|
><HEAD
|
|
><TITLE
|
|
>Configuring sendmail Options</TITLE
|
|
><META
|
|
NAME="GENERATOR"
|
|
CONTENT="Modular DocBook HTML Stylesheet Version 1.57"><LINK
|
|
REL="HOME"
|
|
TITLE="Linux Network Administrators Guide"
|
|
HREF="index.html"><LINK
|
|
REL="UP"
|
|
TITLE="Sendmail"
|
|
HREF="x-087-2-sendmail.html"><LINK
|
|
REL="PREVIOUS"
|
|
TITLE="Interpreting and Writing Rewrite Rules"
|
|
HREF="x14923.html"><LINK
|
|
REL="NEXT"
|
|
TITLE="Some Useful sendmail Configurations"
|
|
HREF="x15291.html"></HEAD
|
|
><BODY
|
|
CLASS="SECT1"
|
|
BGCOLOR="#FFFFFF"
|
|
TEXT="#000000"
|
|
LINK="#0000FF"
|
|
VLINK="#840084"
|
|
ALINK="#0000FF"
|
|
><DIV
|
|
CLASS="NAVHEADER"
|
|
><TABLE
|
|
WIDTH="100%"
|
|
BORDER="0"
|
|
CELLPADDING="0"
|
|
CELLSPACING="0"
|
|
><TR
|
|
><TH
|
|
COLSPAN="3"
|
|
ALIGN="center"
|
|
>Linux Network Administrators Guide</TH
|
|
></TR
|
|
><TR
|
|
><TD
|
|
WIDTH="10%"
|
|
ALIGN="left"
|
|
VALIGN="bottom"
|
|
><A
|
|
HREF="x14923.html"
|
|
>Prev</A
|
|
></TD
|
|
><TD
|
|
WIDTH="80%"
|
|
ALIGN="center"
|
|
VALIGN="bottom"
|
|
>Chapter 18. Sendmail</TD
|
|
><TD
|
|
WIDTH="10%"
|
|
ALIGN="right"
|
|
VALIGN="bottom"
|
|
><A
|
|
HREF="x15291.html"
|
|
>Next</A
|
|
></TD
|
|
></TR
|
|
></TABLE
|
|
><HR
|
|
ALIGN="LEFT"
|
|
WIDTH="100%"></DIV
|
|
><DIV
|
|
CLASS="SECT1"
|
|
><H1
|
|
CLASS="SECT1"
|
|
><A
|
|
NAME="AEN15220"
|
|
>18.7. Configuring sendmail Options</A
|
|
></H1
|
|
><P
|
|
> <B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> has a number of options that allow you to
|
|
customize the way it performs certain tasks. There are a large number of
|
|
these, so we've listed only a few of the more commonly used ones in
|
|
the upcoming list.</P
|
|
><P
|
|
>
|
|
To configure any of these options, you may either define them in the
|
|
<B
|
|
CLASS="COMMAND"
|
|
>m4</B
|
|
> configuration file, which is the preferable method,
|
|
or you may insert them directly into the <TT
|
|
CLASS="FILENAME"
|
|
>sendmail.cf</TT
|
|
>
|
|
file. For example, if we wished to have <B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> fork
|
|
a new job for each mail message to be delivered, we might add the following
|
|
line to our <B
|
|
CLASS="COMMAND"
|
|
>m4</B
|
|
> configuration file:
|
|
|
|
<TABLE
|
|
BORDER="0"
|
|
BGCOLOR="#E0E0E0"
|
|
WIDTH="100%"
|
|
><TR
|
|
><TD
|
|
><PRE
|
|
CLASS="SCREEN"
|
|
>define(‘confSEPARATE_PROC’,‘true’)</PRE
|
|
></TD
|
|
></TR
|
|
></TABLE
|
|
></P
|
|
><P
|
|
>The corresponding <TT
|
|
CLASS="FILENAME"
|
|
>sendmail.cf</TT
|
|
> entry created is:
|
|
|
|
<TABLE
|
|
BORDER="0"
|
|
BGCOLOR="#E0E0E0"
|
|
WIDTH="100%"
|
|
><TR
|
|
><TD
|
|
><PRE
|
|
CLASS="SCREEN"
|
|
>O ForkEachJob=true</PRE
|
|
></TD
|
|
></TR
|
|
></TABLE
|
|
></P
|
|
><P
|
|
> The following list describes common <I
|
|
CLASS="EMPHASIS"
|
|
>sendmail m4</I
|
|
> options (and
|
|
<TT
|
|
CLASS="FILENAME"
|
|
>sendmail.cf</TT
|
|
> equivalents):</P
|
|
><P
|
|
></P
|
|
><DIV
|
|
CLASS="VARIABLELIST"
|
|
><DL
|
|
><DT
|
|
><TT
|
|
CLASS="LITERAL"
|
|
>confMIN_FREE_BLOCKS</TT
|
|
>
|
|
<TT
|
|
CLASS="LITERAL"
|
|
>(MinFreeBlocks)</TT
|
|
></DT
|
|
><DD
|
|
><P
|
|
> There are
|
|
occasions when a problem might prevent the immediate delivery of mail
|
|
messages, causing messages to be queued in the mail spool. If your
|
|
mail host processes large volumes of mail, it is possible for the mail
|
|
spool to grow to such a size that it fills the filesystem supporting
|
|
the spool. To prevent this, <B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> provides this
|
|
option to specify the minimum number of free disk blocks that must
|
|
exist before a mail message will be accepted. This allows you to
|
|
ensure that <B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> never causes your spool
|
|
filesystem to be filled (Default: 100). </P
|
|
></DD
|
|
><DT
|
|
><TT
|
|
CLASS="LITERAL"
|
|
>confME_TOO</TT
|
|
> <TT
|
|
CLASS="LITERAL"
|
|
>(MeToo)</TT
|
|
></DT
|
|
><DD
|
|
><P
|
|
>When a mail target such as an email alias is expanded, it is sometimes
|
|
possible for the sender to appear in the
|
|
recipient list. This option determines whether the originators of an
|
|
email message will receive a copy if they appear in the expanded
|
|
recipient list. Valid values are “true” and
|
|
“false” (Default: false).</P
|
|
></DD
|
|
><DT
|
|
><TT
|
|
CLASS="LITERAL"
|
|
>confMAX_DAEMON_CHILDREN</TT
|
|
> <TT
|
|
CLASS="LITERAL"
|
|
>(MaxDaemonChildren)</TT
|
|
></DT
|
|
><DD
|
|
><P
|
|
>Whenever <B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> receives an SMTP connection
|
|
from a remote host, it spawns a new copy of itself to deal with the
|
|
incoming mail message. This way, it is possible for
|
|
<B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> to be processing multiple incoming mail messages
|
|
simulatanenously. While this is useful, each new copy of
|
|
<B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> consumes memory in the host computer. If
|
|
an unusually large number of incoming connections are received,
|
|
by chance, because of a problem or a malicious attack, it
|
|
is possible for <B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> daemons to consume all
|
|
system memory. This option provides you with a means of limiting the
|
|
maximum number of daemon children that will be spawned. When this
|
|
number is reached, new connections are rejected until some of
|
|
the existing children have terminated
|
|
(Default: undefined).</P
|
|
></DD
|
|
><DT
|
|
><TT
|
|
CLASS="LITERAL"
|
|
>confSEPARATE_PROC</TT
|
|
> <TT
|
|
CLASS="LITERAL"
|
|
>(ForkEachJob)</TT
|
|
></DT
|
|
><DD
|
|
><P
|
|
>When processing the mail queue and sending mail messages,
|
|
<B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> processes one mail message at a time. When this
|
|
option is enabled, <B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
> will fork a new copy of
|
|
itself for each message to be delivered. This is particularly useful
|
|
when there are some mail messages that are stuck in the queue because
|
|
of a problem with the target host
|
|
(Default: false).</P
|
|
></DD
|
|
><DT
|
|
><TT
|
|
CLASS="LITERAL"
|
|
>confSMTP_LOGIN_MSG</TT
|
|
> <TT
|
|
CLASS="LITERAL"
|
|
>(SmtpGreetingMessage)</TT
|
|
></DT
|
|
><DD
|
|
><P
|
|
>Whenever a connection is made to <B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
>, a
|
|
greeting message is sent. By default, this message contains the hostname,
|
|
name of the mail transfer agent, the sendmail version number, the local
|
|
version number, and the current date. RFC821 specifies that the first word
|
|
of the greeting should be the fully qualified domain name of the host, but
|
|
the rest of the greeting can be configured however you please. You can specify
|
|
sendmail macros here and they will be expanded when used. The only people
|
|
who will see this message are suffering system administrators diagnosing
|
|
mail delivery problems or strongly curious people interested in discovering
|
|
how your machine is configured. You can relieve some of the tedium of their
|
|
task by customizing the welcome message with some witticisms; be nice.
|
|
The word “EMSTP” will be inserted between the first and second
|
|
words by <B
|
|
CLASS="COMMAND"
|
|
>sendmail</B
|
|
>, as this is the signal to remote hosts
|
|
that we support the ESMTP protocol
|
|
(Default: <TT
|
|
CLASS="LITERAL"
|
|
>$j Sendmail $v/$Z; $b</TT
|
|
>).</P
|
|
></DD
|
|
></DL
|
|
></DIV
|
|
></DIV
|
|
><DIV
|
|
CLASS="NAVFOOTER"
|
|
><HR
|
|
ALIGN="LEFT"
|
|
WIDTH="100%"><TABLE
|
|
WIDTH="100%"
|
|
BORDER="0"
|
|
CELLPADDING="0"
|
|
CELLSPACING="0"
|
|
><TR
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="left"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="x14923.html"
|
|
>Prev</A
|
|
></TD
|
|
><TD
|
|
WIDTH="34%"
|
|
ALIGN="center"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="index.html"
|
|
>Home</A
|
|
></TD
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="right"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="x15291.html"
|
|
>Next</A
|
|
></TD
|
|
></TR
|
|
><TR
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="left"
|
|
VALIGN="top"
|
|
>Interpreting and Writing Rewrite Rules</TD
|
|
><TD
|
|
WIDTH="34%"
|
|
ALIGN="center"
|
|
VALIGN="top"
|
|
><A
|
|
HREF="x-087-2-sendmail.html"
|
|
>Up</A
|
|
></TD
|
|
><TD
|
|
WIDTH="33%"
|
|
ALIGN="right"
|
|
VALIGN="top"
|
|
>Some Useful sendmail Configurations</TD
|
|
></TR
|
|
></TABLE
|
|
></DIV
|
|
></BODY
|
|
></HTML
|
|
> |