Your Linux Data Center Experts
Aliases for vPostMaster domains
vPostMaster does not internally support "aliases". By aliases, I'm
talking about a simple mapping of one e-mail address to one or more
others. vPostMaster does support having one account forward mail to
others, optionally while storing a copy in the local account, but this
does require that a real account be set up, complete with password, etc.
This is the preferred way of doing aliases in vPostMaster, because then
all accounts are treated the same, and users don't get confused with two
separate locations for where an e-mail address may be handled.
However, you can configure Postfix to do aliases if you absolutely must
In the "main.cf" file, you will need to add the line:
virtual_alias_maps = regexp:/etc/postfix/virtual-regexp $alias_maps
And then in the section under "smtpd_recipient_restrictions" you need to
add the following line before the "check_policy_service
This example uses regexp maps, but this could just as easily be a hash.
You will need to create these two files mentioned above. In the
"virtual-regexp" file, you need to list the aliase account and the
address it's translated to. For example, if you want to forward "foo"
to "bar" and "baz" in the "example.com" domain:
/^email@example.com$/ firstname.lastname@example.org, email@example.com
In the "virtual-regexp-allow" file, you need to list the same left-hand
with "OK" for the right hand, so that the SMTP server knows to allow
If your mailserver should also handle messages for other hosts or
subdomains, you may need to adjust these rules. For example the pattern:
would handle mail for firstname.lastname@example.org, email@example.com and
firstname.lastname@example.org, but would reject messages for email@example.com.
Restart Postfix and now when you mail "firstname.lastname@example.org" it should
deliver to "email@example.com" and "firstname.lastname@example.org".