postfix: virtual alias maps (trying to act as a mail relay)

Debian Squeeze

So I'm trying to follow the instructions found on http://www.postfix.org/VIRTUAL_README.html#forwarding

I have a FQDN and a few apache vhosts . I'd like to act as a mail relay using virtual alias maps. I've set postfix up as a Satellite System.

I can send mail to my FQDN name which I have set as a catch-all mailbox that immediately fwds to my personal gmail.

When I try to send an email to one of my vhosts, it is rejected.

Line 323 of the successful FQDN email (verbose postfix mail.log output http://p.linode.com/6243)

and

Line 324 of the failed vhost (verbose postfix mail.log output http://p.linode.com/6233)

are where these 2 files start to differ (you can ignore everything up to that point). From that moment on I'm trying to troubleshoot why my vhost email gets rejected.

Here is my main.cf ( http://p.linode.com/6234 )

Here is my master.cf ( http://p.linode.com/6235 )

#postconf -n
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
append_dot_mydomain = no
biff = no
config_directory = /etc/postfix
inet_interfaces = all
inet_protocols = all
mailbox_size_limit = 0
mydestination = mail.mydomain.net, mydomain.net, localhost.net, localhost
myhostname = mail.mydomain.net
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
myorigin = /etc/mailname
readme_directory = no
recipient_delimiter = +
relayhost = 
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
smtpd_tls_cert_file = /etc/ssl/certs/ssl-cert-snakeoil.pem
smtpd_tls_key_file = /etc/ssl/private/ssl-cert-snakeoil.key
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtpd_use_tls = yes
virtual_alias_domains = mail.mydomain.net
virtual_alias_maps = hash:/etc/postfix/virtual

I've set up my /etc/postfix/virtual and

postconf'd it

  • restarted postfix each time.

I have no clue why this isn't working.

Any help is appreciated!

1 Reply

It's all about the /etc/postfix/virtual file

it needs to have:

thedomain.net anything

above any emails from that domain. that is what tells postfix that these domains are accepted

I'll make a contribution to the linode library and link to it from this post.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct