Hi Paul,
On Fri, 22 Mar 2024 at 02:58:00AM -0000, paul@virtuadv.com wrote:
- I got the yahoo/gmail solved but my emails go to their spam... I will try to add DKIM and DMARC next to see if it helps.
yes, and if it not already exists: an SPF record is also helpful.
- I am trying different ways to create those abuse and postmaster emails for all my web sites with the least amount of email accounts. I think aliases worked for site1 when I added:
postmaster: postmaster@site1.com abuse: postmaster@site1.com
Please remember that /etc/aliases (alias_maps) has aliases that apply only for local recipients on the machine itself.
But I am having trouble forwarding the other sites to site1 in order to have only one email account for all these. I tried different things and the latest I tried is by adding this in file virtual:
abuse@site2.com abuse postmaster@site2.com postmaster abuse@site3.com abuse postmaster@site3.com postmaster
It seems like it is trying to send to postmaster@mail.site1.com which dovecot does not find, and it discards those emails. Not sure what is the easiest way of doing this.
Yes, if you only use 'postmaster' in virtual it will expand to this address as you have 'mydomain = mail.site1.com', and so Dovecot cannot find it.
I'd suggest the following, based on your current config:
(1)
Extend your main.cf -> virtual_alias_maps this way:
virtual_alias_maps = hash:/etc/postfix/virtual, pcre:/etc/postfix/virtual_rfc
(BTW, I suggest to use 'hash' instead of 'texthash' you used as with the former Postfix is able to automatically detect changes of these maps and a 'Postfix reload' isn't necessary.)
In virtual_rfc something like this:
/^postmaster@/ postmaster@site1.com /^abuse@/ postmaster@site1.com /^hostmaster@/ postmaster@site1.com /^webmaster@/ postmaster@site1.com
(Hint: in contrast to hashed tables (see above) pcre lookup tables are simple text files, so you have to do a 'Postfix reload' after changing them.)
or
(2)
Alternatively and instead of such a pcre map you could still use:
virtual_alias_maps = hash:/etc/postfix/virtual
and put all these aliases in the virtual file:
abuse@site1.com postmaster@site1.com abuse@site2.com postmaster@site1.com postmaster@site2.com postmaster@site1.com abuse@site3.com postmaster@site1.com postmaster@site3.com postmaster@site1.com abuse@site4.com postmaster@site1.com postmaster@site4.com postmaster@site1.com [...]
--> after editing of course a 'postmap /etc/postfix/virtual'
It depends on the number of domains which option is less expensive.
As this all is mostly MTA/Postfix related and so quite off-topic here maybe it's better to switch to direkt e-mail if we have to look at it further?
Best regards, Markus