PMG E-Mail change sender of system messages

vettel18

New Member
Jul 16, 2025
5
1
3
Hi,

PMG currently sends emails for system messages, auto replies and spam filter notifications from a default email address: Postmaster@xxxx.xx
How can I change this email address? There is already a correct address configured under Configuration/Options/Administrator Email, but it is ignored.

Thanks for your help!
 
Hi,

PMG currently sends emails for system messages, auto replies and spam filter notifications from a default email address: Postmaster@xxxx.xx
How can I change this email address? There is already a correct address configured under Configuration/Options/Administrator Email, but it is ignored.

Thanks for your help!
could you please share the logs of such a mail and the mail itself (just to be sure where it actually originates from and how/if this can be adapted) - thanks!
 
Hi,
it also happens when we deliver a mail in quarantine.
Envelop from is postmaster@myserver.mydomain but myserver.mydomain is not a valid mail domain.
So if receiver does not exist in our downstream mail servers, the bounce cannot be done up to the PMG server.
 
Hi,
it also happens when we deliver a mail in quarantine.
Envelop from is postmaster@myserver.mydomain but myserver.mydomain is not a valid mail domain.
So if receiver does not exist in our downstream mail servers, the bounce cannot be done up to the PMG server.
Same problem here. The "admin"-email is taken as sender-address for the summary-emails, but if you as admin manually release emails by clicking "Deliver" in the web-ui, the "postmaster@<pmghost>" is still taken.
 
Last edited:
  • Like
Reactions: DavidD
Hi,
with postconf command, i have changed myorigin=$myhostname to my desired domain.
I hope it does not have a bad effect...
Aren't these settings overwritten when one changes and saves settings via the WUI?
I read something about "templates" that need to be changed instead, but at least on my installation these template-files are missing for some reason.
 
@Developers: Could you please add this to the feature wishlist? IHMO it would mean a great and easy to implement enhancement if either the "admin email" address is taken for postmaster-emails or if there would be a dedicated field in the UI to sent the sender-address for all emails generated by PMG itself (like the daily report and the ones sent by pressing "Deliver".

Thanks in advance!

PS: I did not find any sub-forum to post feature requests. So where and how would normal paying users put these requests? Thanks!
 
Aren't these settings overwritten when one changes and saves settings via the WUI?
please see the reference documentation:
https://pmg.proxmox.com/pmg-docs/pmg-admin-guide.html#pmgconfig_template_engine
but at least on my installation these template-files are missing for some reason.
They are in /var/lib/pmg/templates - you need to copy them to /etc/pmg/templates (and create that directory before)

Developers: Could you please add this to the feature wishlist? IHMO it would mean a great and easy to implement enhancement if either the "admin email" address is taken for postmaster-emails or if there would be a dedicated field in the UI to sent the sender-address for all emails generated by PMG itself (like the daily report and the ones sent by pressing "Deliver".
Most mails sent by PMG get their From header set to the admin mail (so they can be DKIM signed if the address is configured as DKIM domain) - they are still sent with an empty envelope sender to prevent bounces for automated reports.

Regarding the mails sent when you click "Deliver" those still have their From header set to the one in the mail - the envelope sender is set to postmaster, as the mails are being sent from PMG - for the original sender they look accepted (they were accepted when they were put into quarantine)

Those settings are chosen to not cause mail-loops and senseless backscatter - and for the time being we don't plan on changing that.

What is the actual issue with the mails for you? Do they get rejected? Do they look wrong?

PS: I did not find any sub-forum to post feature requests. So where and how would normal paying users put these requests? Thanks!
Feature requests and bugreports can be reported here - as you have more participants to the discussion - if something is confirmed or many users wish for it - our bugzilla is the best place to record such interest: https://bugzilla.proxmox.com - I hope this helps!
 
  • Like
Reactions: ChrisTG74
@Stoiko Ivanov thanks for your reply and the informations. Very appreciated!

What is the actual issue with the mails for you? Do they get rejected? Do they look wrong?
The main problem we face is, that the sending-address is not postmaster@<mydomain.tld> but postmaster@<pmg-hostname>.<mydomain.tld>. This leads to emails not being verified as company-internal by E365.

From what I understood how "postmaster" should be used, I would expect that the address would not contain the hostname, as it is ment to be the "postmaster" for the particular domain, not only for the host running the mailserver.

For now, I have added a policy in E365's spam-detection to handle this, but for a clean solution I think it would make sense to either always drop the hostname-part for the postmaster-address, or to give the users the ability for changes this in the WUI.
 
From what I understood how "postmaster" should be used, I would expect that the address would not contain the hostname, as it is ment to be the "postmaster" for the particular domain, not only for the host running the mailserver.
postmaster@ should be an address that at some point reaches an admin who can fix issues with mail delivery - usually it kept with the hostname of the actual system sending mails and not one of the domains for which it is an MX.

This leads to emails not being verified as company-internal by E365.
If the mails are sent by _your_ PMG in your company - I'd consider them company-internal - and would probably add the FQDN of your PMG to the internal domains in E365 (don't have experience with E365 though)
 
If the mails are sent by _your_ PMG in your company - I'd consider them company-internal - and would probably add the FQDN of your PMG to the internal domains in E365 (don't have experience with E365 though)
This could be done, of couse, but would lead to permanent warnings in E365 admin-center as E365 would then expect that the DNS-entries like MX, SPF etc. are present for this subdomain pointing to E365 and not to PMG.

Why not offering an official way to change the sender-address of the reports- and delivery-emails? I don't see any downside to provide an option for this.

Thank you.
 
For anyone else looking for an interim solution, here is what I did now:

Bash:
mkdir /etc/pmg/templates/
cp /var/lib/pmg/templates/main.cf.in /etc/pmg/templates/

Then, with an editor, open /etc/pmg/templates/main.cf.in and find the line "myorigin". If it is missing (like it was the case for me), simple add it:

Bash:
myorigin = [% dns.domain %]

Restart the services by:

Bash:
 pmgconfig sync --restart 1

HTH!
 
Last edited: