Forwarding or copying of emails

From Notes_Wiki
Revision as of 05:04, 16 July 2015 by Saurabh (talk | contribs) (Created page with "<yambe:breadcrumb>Postfix_server_configuration|Postfix server configuration</yambe:breadcrumb> =Forwarding or copying of emails= ==Copy all emails received by a user to other...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

<yambe:breadcrumb>Postfix_server_configuration|Postfix server configuration</yambe:breadcrumb>

Forwarding or copying of emails

Copy all emails received by a user to other accounts

A copy of all emails received by user can be sent to other accounts. This can be done by creating a '.forward' file in users home folder. In this file an email address can be specified per line where the mails should be forwarded. For example for user saurabh a .forward could look like:

barjatiya.saurabh@gmail.com
root
saurabh@sbarjatiya.com
saurabh

where a copy of each received email would get forwarded to barjatiya.saurabh@gmail.com, user root on same system, saurabh@sbarjatiya.com and a copy of email would be present in user saurabh mail box. The name of same user, ie saurabh, in this case must come at end. We cannot put the same name in any other (non-last) line.

Also if only forwarding is desired and a copy of email in user saurabh's inbox is not required than we can omit specifying 'saurabh' at end. Note that if copy of email is not required then using aliases from /etc/alises might be simpler for forwarding email to other accounts or addresses.