jump to navigation

How to setup an email alias in Linux with Sendmail system installed August 16, 2010

Posted by jbanju in LINUX CentOS.

1. Login with root user ID
2. Edit the /etc/aliases file (with vi editor)
3. Append / change an email alias in this format

alias_name: email_id1 [, email_id2,] …

E.g. append this new email alias to the /etc/aliases

blogadmin: walkernews@walkernews.net, assist@walkernews.net

4. Save and exit the alias file
5. Execute the newaliases command followed by echo $? (suppose there is no error found, you will get a 0 returned by the echo command).
Alternatively, you can execute the equivalent sendmail -bi command (since this is a Sendmail system)

By now, you should test and confirm the works done so far. E.g. send an email to the email alias:

mail -s “testing with aliases name blogadmin” blogadmin

Mission completed if you the email in both inboxes (in this example, these are walkernews@walkernews.net and assist@walkernews.net).

Remark :

root:           /dev/null #Send root mail to null



No comments yet — be the first.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: