Difference between revisions of "Email Forwarding"

From ECE Information Technology Services
Jump to navigationJump to search
(New Page)
 
(Elaboration)
Line 1: Line 1:
<!--Originally written on: 2005-Nov-30-->
+
Suppose that you use another email account as your primary account and that you would like all your ECE email to be delivered there.
  
Suppose that you use another email account as your primary account and that you
+
There are two ways to accomplish this:
would like all your ECE email to be delivered there.
+
* with directives in <tt>.forward</tt> files or
 +
* with directives in <tt>.procmailrc</tt> files.
  
There are two ways to accomplish this:
+
Please read [[How Received Email Is Processed]] to understand the difference between using <tt>.forward</tt> and <tt>.procmailrc</tt>.
* with directives in ''.forward'' files or
+
 
* with directives in ''.procmailrc'' files.
+
Take care not to create a mail forwarding loop. If your other account is also configured to forward mail to your ECE account, the mail servers will keep forwarding messages to each other forever!
  
Please read [[How Received Email Is Processed]] to understand the difference between using ''.forward'' and ''.procmailrc''.
+
====Using <tt>.forward</tt> To Forward Email====
 +
Create a plain text file in your home directory named <tt>.forward</tt> containing just the address(es) that you want to forward mail to. If there are multiple destinations, put them on separate lines. For example:
 +
<pre>
 +
somebody@example.com
 +
</pre>
  
====Using ''.forward'' To Forward Email====
+
To keep a copy in your ECE account while also forwarding the mail, include a line with your username preceded by a backslash:
 
<pre>
 
<pre>
  somebody@example.com
+
\myusername
 +
somebody@example.com
 
</pre>
 
</pre>
  
====Using ''.procmailrc'' To Forward Email====
+
====Using <tt>.procmailrc</tt> To Forward Email====
 +
Include the following rule in your <tt>.procmailrc</tt> file:
 
<pre>
 
<pre>
  :0
+
:0
  ! somebody@example.com
+
! somebody@example.com
 
</pre>
 
</pre>

Revision as of 10:08, 26 September 2012

Suppose that you use another email account as your primary account and that you would like all your ECE email to be delivered there.

There are two ways to accomplish this:

  • with directives in .forward files or
  • with directives in .procmailrc files.

Please read How Received Email Is Processed to understand the difference between using .forward and .procmailrc.

Take care not to create a mail forwarding loop. If your other account is also configured to forward mail to your ECE account, the mail servers will keep forwarding messages to each other forever!

Using .forward To Forward Email

Create a plain text file in your home directory named .forward containing just the address(es) that you want to forward mail to. If there are multiple destinations, put them on separate lines. For example:

somebody@example.com

To keep a copy in your ECE account while also forwarding the mail, include a line with your username preceded by a backslash:

\myusername
somebody@example.com

Using .procmailrc To Forward Email

Include the following rule in your .procmailrc file:

:0
! somebody@example.com