From owner-svn-doc-all@FreeBSD.ORG Sun May 11 16:48:54 2014 Return-Path: Delivered-To: svn-doc-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id E6DCE1F3; Sun, 11 May 2014 16:48:54 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C7CFF21B3; Sun, 11 May 2014 16:48:54 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s4BGmspe071088; Sun, 11 May 2014 16:48:54 GMT (envelope-from dru@svn.freebsd.org) Received: (from dru@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s4BGms31071087; Sun, 11 May 2014 16:48:54 GMT (envelope-from dru@svn.freebsd.org) Message-Id: <201405111648.s4BGms31071087@svn.freebsd.org> From: Dru Lavigne Date: Sun, 11 May 2014 16:48:54 +0000 (UTC) To: doc-committers@freebsd.org, svn-doc-all@freebsd.org, svn-doc-head@freebsd.org Subject: svn commit: r44809 - head/en_US.ISO8859-1/books/handbook/mail X-SVN-Group: doc-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-doc-all@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: "SVN commit messages for the entire doc trees \(except for " user" , " projects" , and " translations" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 11 May 2014 16:48:55 -0000 Author: dru Date: Sun May 11 16:48:54 2014 New Revision: 44809 URL: http://svnweb.freebsd.org/changeset/doc/44809 Log: Editorial review of Replacing MTA chapter. Add needed periodic.conf entries and update mailer.conf with Postfix example. Sponsored by: iXsystems Modified: head/en_US.ISO8859-1/books/handbook/mail/chapter.xml Modified: head/en_US.ISO8859-1/books/handbook/mail/chapter.xml ============================================================================== --- head/en_US.ISO8859-1/books/handbook/mail/chapter.xml Sun May 11 15:21:54 2014 (r44808) +++ head/en_US.ISO8859-1/books/handbook/mail/chapter.xml Sun May 11 16:48:54 2014 (r44809) @@ -539,7 +539,7 @@ postmaster@example.com postmast GregoryNeil ShapiroInformation taken - from emails written by + from emails written by @@ -550,30 +550,22 @@ postmaster@example.com postmast &os; comes with Sendmail already installed as the MTA which is in charge of - outgoing and incoming mail. - - However, the system administrator can change the system's - MTA. The reasons for doing so range from - wanting to try out another MTA to needing a - specific feature or package which relies on another - MTA. Whatever the reason, &os; makes it - easy to make the change. - - - Install a New <acronym>MTA</acronym> - - A wide choice of MTAs is available - from the mail category of the &os; Ports Collection. - - Once a new MTA is installed, configure - the new software and decide if it really fulfills your needs - before replacing Sendmail. - - Refer to the new chosen MTA's - documentation for information on how to configure the - software. - + outgoing and incoming mail. However, the system administrator + can change the system's MTA. A wide choice + of alternative MTAs is available from the + mail category of the &os; Ports + Collection. + + Once a new MTA is installed, configure + and test the new software before replacing + Sendmail. Refer to the documentation + of the new MTA for information on how to + configure the software. + + Once the new MTA is working, use the + instructions in this section to disable + Sendmail and configure &os; to use + the replacement MTA. Disable <application>Sendmail</application> @@ -586,14 +578,13 @@ postmaster@example.com postmast their results by email. Many parts of the system expect a functional MTA. If applications continue to use Sendmail's binaries to try - to send email they are disabled, mail could go into an - inactive Sendmail queue, and + to send email after they are disabled, mail could go into an + inactive Sendmail queue and never be delivered. In order to completely disable - Sendmail, including the outgoing - mail service, add or edit the following lines in + Sendmail, add or edit the following lines in /etc/rc.conf: sendmail_enable="NO" @@ -602,90 +593,99 @@ sendmail_outbound_enable="NO" sendmail_msp_queue_enable="NO" To only disable Sendmail's - incoming mail service, set + incoming mail service, use only this entry in + /etc/rc.conf: sendmail_enable="NO" - in /etc/rc.conf. More information + More information on Sendmail's startup options is available in &man.rc.sendmail.8;. - Running the New <acronym>MTA</acronym> on Boot + Replace the Default <acronym>MTA</acronym> - The new MTA can be started during - boot by adding a configuration line to - /etc/rc.conf. This example enables the + When a new MTA is installed using the + Ports Collection, its startup script is also installed and + startup instructions are mentioned in its package message. + Before starting the new MTA, stop the + running Sendmail processes. This + example stops all of these services, then starts the + Postfix service: + + &prompt.root; service sendmail stop +&prompt.root; service postfix start + + To start the replacement MTA at system boot, + add its configuration line to + /etc/rc.conf. This entry enables the Postfix MTA: - &prompt.root; echo -'postfix_enable=YES' ->> /etc/rc.conf + postfix_enable="YES" - The specified MTA will now be - automatically started during boot. - + Some extra configuration is needed as + Sendmail is so ubiquitous that some software assumes + it is already installed and configured. Check + /etc/periodic.conf and make sure that + these values are set to NO. If this file + does not exist, create it with these entries: + + daily_clean_hoststat_enable="NO" +daily_status_mail_rejects_enable="NO" +daily_status_include_submit_mailq="NO" +daily_submit_queuerun="NO" - - Replacing <application>Sendmail</application> as - the System's Default Mailer - - Sendmail is so ubiquitous as - standard software on &unix; systems that some software assumes - it is already installed and configured. For this reason, many - alternative MTAs provide their own + Some alternative MTAs provide their own compatible implementations of the Sendmail command-line interface in - order to facilitate using them as drop-in - replacements for Sendmail. + order to facilitate using them as drop-in + replacements for Sendmail. + However, some MUAs may + try to execute standard + Sendmail binaries instead of the + new MTA's binaries. &os; uses + /etc/mail/mailer.conf to map the expected + Sendmail binaries to the location of the new + binaries. More information about this mapping can be found in + &man.mailwrapper.8;. - When using an alternative MTA, - make sure that software trying to execute standard - Sendmail binaries, such as - /usr/bin/sendmail, actually execute - the chosen mailer instead. Fortunately, &os; provides a - system called &man.mailwrapper.8; for this purpose. - - When Sendmail is operating - as installed, - /etc/mail/mailer.conf will look like + The default + /etc/mail/mailer.conf looks like this: - sendmail /usr/libexec/sendmail/sendmail -send-mail /usr/libexec/sendmail/sendmail -mailq /usr/libexec/sendmail/sendmail -newaliases /usr/libexec/sendmail/sendmail -hoststat /usr/libexec/sendmail/sendmail -purgestat /usr/libexec/sendmail/sendmail + # $FreeBSD$ +# +# Execute the "real" sendmail program, named /usr/libexec/sendmail/sendmail +# +sendmail /usr/libexec/sendmail/sendmail +send-mail /usr/libexec/sendmail/sendmail +mailq /usr/libexec/sendmail/sendmail +newaliases /usr/libexec/sendmail/sendmail +hoststat /usr/libexec/sendmail/sendmail +purgestat /usr/libexec/sendmail/sendmail When any of the commands listed on the left are run, the system actually executes the associated command shown on - the right instead. This system makes it easy to change what + the right. This system makes it easy to change what binaries are executed when these default - Sendmail functions are invoked. - - As an example, to run - /usr/local/supermailer/bin/sendmail-compat - instead of Sendmail, specify the - paths to the installed applications in - /etc/mail/mailer.conf: - - sendmail /usr/local/supermailer/bin/sendmail-compat -send-mail /usr/local/supermailer/bin/sendmail-compat -mailq /usr/local/supermailer/bin/mailq-compat -newaliases /usr/local/supermailer/bin/newaliases-compat -hoststat /usr/local/supermailer/bin/hoststat-compat -purgestat /usr/local/supermailer/bin/purgestat-compat - + binaries are invoked. - - Finishing + Some MTAs, when installed using the + Ports Collection, will prompt to update this file for the new + binaries. For example, Postfix + will update the file like this: + + # +# Execute the Postfix sendmail program, named /usr/local/sbin/sendmail +# +sendmail /usr/local/sbin/sendmail +send-mail /usr/local/sbin/sendmail +mailq /usr/local/sbin/sendmail +newaliases /usr/local/sbin/sendmail - Once everything is configured, either kill the - unneeded sendmail processes and - start the processes belonging to the new software, or - reboot. Rebooting provides the opportunity to ensure that + Once everything is configured, it is recommended to + reboot the system. Rebooting provides the opportunity to ensure that the system is correctly configured to start the new MTA automatically on boot.