Setting up Mail Forwarding in Postfix

To setup mail forward in postfix,

Edit postfix config file

Add

Create file /etc/postfix/virtual_alias_domains

Add your domains on this file. 1 Per line.

Example

Here i have 2 domains added, postfix will service as incoming email server for these 2 domains.

Now create /etc/postfix/virtual_alias_maps, this file will list all email accounts you need and where the email needed to be forwarded to.

Add

here email coming to [email protected] and [email protected] get forwarded to [email protected]

If you need catch all email account, just use

If you want email forwarded to more than one recipient, add them one after other like

Now run

Restart postfix

You need to set MX record of your domain to point to server running the postfix mail server to receive mails.