sendmail aliases

EQ Admin

EQ Forum Admin
Staff member
Hello,

Sendmail aliases allow sendmail to take an e-mail and optionally forward it, write it to a file, or run it through another program.

The sendmail aliases file is usually found at /etc/aliases, but it can also be commonly found at /etc/mail/aliases

An example of a forward can be found in the default /etc/mail/aliases file:

# RFC 822 requires that every host have a mail address "postmaster"
postmaster : root

This is an example of directing e-mail to a file.

In this case, it is being deleted by directing it to a special device known as /dev/null
# Aliases to handle mail to msgs and news

nobody : /dev/null

An example of piping an email to a program is:

support: |/path/to/your/support-program

To create a mailing list separate multiple addresses with a comma:

# help mailing list
help: staff01@domain.com,staff02@domain.com,staff03@domain.com

To make the aliases file changes live run the command: newaliases
 
Last edited:
Top