12.07.2015 Views

Red Hat Enterprise Linux 5 Administration Unleashed

Red Hat Enterprise Linux 5 Administration Unleashed

Red Hat Enterprise Linux 5 Administration Unleashed

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

370CHAPTER 18Setting Up an Email Server with SendmailConfiguring SendmailSendmail is an MTA, meaning it accepts email messages sent to it using the SMTP protocoland transports them to another MTA email server until the messages reach their destinations.It also accepts email for the local network and delivers them to local mail spools,one for each user.To configure a <strong>Red</strong> <strong>Hat</strong> <strong>Enterprise</strong> <strong>Linux</strong> system as a mail server, the sendmail RPM packagemust be installed. If it is not installed, use <strong>Red</strong> <strong>Hat</strong> Network to install it as discussed inChapter 3, “Operating System Updates.” The sendmail-cf package is also necessary if youplan to change the default configuration. Optionally, install the sendmail-doc package ifyou want the Sendmail docs installed locally in the /usr/share/doc/sendmail/ directory.NOTESendmail is quite configurable with hundreds of options. This chapter provides theessential information necessary to get your email server off the ground and running. Toexplore more of its functionality, consult sendmail.org, documentation from the sendmail-docspackage, or a book dedicated to Sendmail configuration and maintenance.The /etc/mail/ directory contains all the Sendmail configuration files, with sendmail.cfand submit.cf being the main configuration files. The sendmail.cf file includes optionsfor the mail transmission agent and accepts SMTP connections for sending email. Thesubmit.cf file configures the mail submission program. However, these files should notbe edited directly.Instead, edit the /etc/mail/sendmail.mc and /etc/mail/submit.mc files. When Sendmail isstarted or restarted with the service command as described in the “Starting and Stoppingthe Server” section, a new sendmail.cf file is automatically generated if sendmail.mc hasbeen modified, and a new submit.cf is generated if submit.mc has been modified.In the sendmail.mc and submit.mc files, lines that begin with dnl, which stands for deleteto new line, are considered comments. Some lines end with dnl, but lines ending in dnl arenot comments.Only the root user can modify files in the /etc/mail/ directory. The /etc/mail/ directoryalso includes the following configuration files:. access. domaintable. helpfileList of hosts that are allowed to send email from this server. Refer to /usr/share/doc/sendmail/README.cf from the sendmail-docs package for details.Table of old domain names and their new domain names in case they havechanged.Text file containing the content displayed for the SMTP HELP command.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!