[Next] [Previous] [Up] [Top] [Contents]

CHAPTER 26 Mail

26.3 The mail alias file


You can use the mail alias file, /etc/aliases (SunOS 4.1.X) or /etc/mail/aliases (SunOS 5.X) to redirect mail or to send mail to a group of people. The newaliases command must be called to rebuild the aliases database before this information can be used by sendmail. Some examples of entries in the aliases file are:

# Alias for mailer daemon; returned messages from our MAILER-DAEMON

# should be routed to our local Postmaster.

MAILER-DAEMON: postmaster

postmaster: frank

#

# A mailing list for a group

staff_group: frank@nyssa,jim,bobd@leela,smith-b@magnus,

baker,bill@ohstmvsa,jones@epsilon.eng.ohio-state.edu

owner-staff_group: frank

#

# COSUG ACS Mailing List (aliases included in file)

cosug ::include:/acs/tardis/0/frank/cosug/aliases

cosug-request : frank

owner-cosug : cosug-request

#

# Pipe mail through a program

test: "| /usr/local/bin/testpgm"

The vacation program uses the latter form by placing in the user's .forward file contents similar to:

\frank, "|/usr/bin/vacation frank"

System mail logs are generally kept in /var/spool/mqueue/syslog, or /var/log/syslog, or /var/adm/messages, as determined by an entry in /etc/syslog.conf, e.g.:

mail.debug ifdef('LOGHOST', /var/spool/mqueue/syslog, @loghost)

Information is kept on every message sent, who sent it, to whom, the size, the status of the message, and the time, e.g.:

Jul 24 12:05:24 peri sendmail[1090]: MAA01090: from=<frank@peri.acs.ohio-state.edu>, size=555, class=0, pri=60555, nrcpts=2, msgid=<199607241605.MAA03311@nyssa.acs.ohio-state.edu>, proto=SMTP, relay=nyssa [128.146.226.22]

Jul 24 12:05:28 peri sendmail[1092]: MAA01090: to=<mgsmiley@magnus.acs.ohio-state.edu>, ctladdr=<frank@peri.acs.ohio-state.edu> (2523/11), delay=00:00:04, xdelay=00:00:04, mailer=tcp, relay=postbox.acs.ohio-state.edu. [128.146.214.20], stat=Deferred: Connection reset by peer during client greeting with postbox.acs.ohio-state.edu.

Jul 24 12:05:29 peri sendmail[1092]: MAA01090: to=<frank@magnus.acs.ohio-state.edu>, ctladdr=<frank@peri.acs.ohio-state.edu> (2523/11), delay=00:00:05, xdelay=00:00:01, mailer=tcp, relay=mail0.uts.ohio-state.edu. [128.146.214.29], stat=Sent (MAA26210 Message accepted for delivery)

Jul 24 12:10:50 peri sendmail[1107]: MAA01090: to=<mgsmiley@magnus.acs.ohio-state.edu>, ctladdr=<frank@peri.acs.ohio-state.edu> (2523/11), delay=00:05:26, xdelay=00:00:00, mailer=tcp, relay=postbox.acs.ohio-state.edu. [128.146.214.20], stat=Sent (MAA23783 Message accepted for delivery)


Unix System Administration - 8 AUG 1996
[Next] [Previous] [Up] [Top] [Contents]