Previous Table of Contents Next


Setting Up DNS Alias Files

The DNS naming service does not use aliases for individuals. It does use aliases for hosts or domains, which are called Mail Exchange (MX) records. The /etc/named.boot file on the DNS server(s) for the domain or subdomain contains a list of other configuration files in DNS, one of which contains MX host information. You can specify host names or domain names in this file. Domain names can contain wildcards; for example, *.sun.com is an acceptable domain name.

You must use the sendmail.mx program with the DNS naming service. When you use the sendmail.mx program, the ${name} rule, which creates fully qualified host names, is activated in the sendmail.cf file. You do not need to edit the configuration file to activate this rule.

Follow these steps to set up the sendmail.mx program:

1.  Type mv /usr/lib/sendmail /usr/lib/sendmail.nomx and then press Return. The current sendmail program is renamed.
2.  Type mv /usr/lib/sendmail.mx /usr/lib/sendmail and then press Return. The sendmail.mx file gets host names directly from DNS.
3.  Make sure there is an entry for mailhost in the DNS /etc/named.boot file on the DNS server.

Setting Up the Postmaster Alias

Every system should be able to send mail to a postmaster. You can create an NIS or NIS+ alias for postmaster or create one in each local /etc/mail/aliases file. This is the default /etc/mail/aliases entry:

# Following alias is required by the mail protocol, RFC 822
# Set it to the address of a HUMAN who deals with this system's
mail problems.
Postmaster: root

To create the postmaster alias, edit each system's /etc/mail/aliases file and change root to the mail address of the person who will act as the postmaster.

You may want to create a separate mailbox for the postmaster to keep postmaster mail separate from personal mail. If you create a separate mailbox, use the mailbox address instead of the postmaster's mail address when you edit the /etc/mail/aliases files.

Follow these steps to create a separate mailbox for the postmaster:

1.  Create an account named postmaster and put an asterisk (*) in the password field of the /etc/shadow file.
2.  Type mail -f postmaster and then press Return. Mail will be able to read and write to the mailbox name.

Follow these steps to add the postmaster mailbox to the alias:

1.  Become superuser and edit the /etc/mail/aliases file on each system. If your network runs NIS or NIS+, use the AdminSuite Database Manager to edit the Aliases database.
2.  Change the postmaster alias from root to postmaster:
postmastermailbox@postmasterhost
Save the changes.
3.  On the postmaster's local system, create an entry in the /etc/mail/aliases file that defines the name of the alias (postmaster, for example) and includes the path to the local mailbox.
4.  Type newaliases and then press Return.

Alternatively, you could change the "postmaster:" entry in the aliases file to postmaster: /usr/somewhere/somefile.

Testing Your Mail Configuration

When you have all of the systems in your mail configuration set up, use the suggestions in this section to test the setup to make sure mail messages can be sent and received.

1.  Reboot any system for which you have changed a configuration file.
2.  Send test messages from each system by typing /usr/lib/sendmail -v </dev/null names and then press Return. Specify a recipient's email address in place of the names variable. This command sends a null message to the specified recipient and displays messages while it runs.
3.  Run the following tests:
  Send mail to yourself or to other people on the local system by addressing the message to a regular username.
  If you are on an ethernet, send mail to someone on another system. Do this in three directions: from the main system to a subsidiary system, from a subsidiary system to the main system, and from a subsidiary system to another subsidiary system.
  If you have a relay host, send mail to another domain from the mailhost to ensure that the relay mailer and host are configured properly.
  If you have set up an uucp connection on your phone line to another host, send mail to someone at that host and have that individual send mail back or call you when the message is received.
  Ask someone to send you mail over the uucp connection. The sendmail program cannot tell whether the message gets through because it hands the message to uucp for delivery.
  Send a message to the postmaster on different systems and make sure that it comes to your postmastesr's mailbox.

Administering Your Mail Configuration

The following sections describe how to keep mail services running smoothly.

Duties of Postmaster

Your responsibilities for administering mail include the following tasks:

  Check the mail queues to make sure that mail is flowing in and out.
  Check any downed systems where mail is backing up. If the system is not needed, delete it from the mail system or bring it up to keep mail moving.
  Fix personal aliases, as requested.
  Administer Aliases databases as people move in and out of the domain.
  Set up temporary forwarding files.
  Contact owners of mailing lists and help them fix mailing list problems.
  Go through postmaster mail daily and look for problems, broken .forward files, and mail alias loops. Fix the problem or tell people how to fix it.
  Answer questions about mail delivery problems from outside of the company.
  Truncate log files periodically.

The Mail Queue

Under high load or temporary failure conditions, sendmail puts a message into a job queue in the /var/spool/mqueue directory instead of delivering it immediately. Ordinarily, the mail queue is processed automatically. Sometimes, however, you may have to intervene manually. For example, if a major host is down for a period of time, the queue may become clogged. Although sendmail ought to recover gracefully when the host comes up, you may find performance unacceptable in the meantime.


Previous Table of Contents Next