How To Configure Custom Postfix Bounce Messages (PMG 5.1-2)

fybko

New Member
Jan 15, 2019
2
0
1
34
Hi there, is there any way to change the message delivery failure message that gets emailed out to the user, when a email can not be delivered (wrong/non-existed destination address).

At the moment, user gets the following:
SUBJECT: Delayed Mail (still being retried)

This is the mail system at host pmg.domain.com.

####################################################################
# THIS IS A WARNING ONLY. YOU DO NOT NEED TO RESEND YOUR MESSAGE. #
####################################################################

Your message could not be delivered for more than 4 hour(s).
It will be retried until it is 5 day(s) old.

For further assistance, please send mail to postmaster.

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

The mail system

<wrongemail@yahoo.cm>: connect to yahoo.cm[98.136.101.175]:25: Connection timed
out​

And 5 days later they gets:
SUBJECT:Undelivered Mail Returned to Sender

This is the mail system at host pmg.domain.com.

I'm sorry to have to inform you that your message could not
be delivered to one or more recipients. It's attached below.

For further assistance, please send mail to postmaster.

If you do so, please include this problem report. You can
delete your own text from the attached returned message.

The mail system

<wrongemail@yahoo.cm>: connect to yahoo.cm[74.6.144.137]:25: Connection timed out​

All mail sent by MAILER-DAEMON@domain.com

What i want to know is:
  1. Can i edit and customize the message ?
  2. Can i edit MAILER-DAEMON to something like ADMIN@domain.com ?
 
Copy and then I change my main.cf.in settings and customizations, correct ?

copy main.cf >> main.cf.in
 
No, use the manual and copy the default template main.cf.in into the folder as given and then sync it to main.cf. Edit your settings in the copied folder. Should be anything like /var/lib/pmg/templates to /etc/pmg/templates but not sure currently, please look into the manual.
 
No, use the manual and copy the default template main.cf.in into the folder as given and then sync it to main.cf. Edit your settings in the copied folder. Should be anything like /var/lib/pmg/templates to /etc/pmg/templates but not sure currently, please look into the manual.

Is custom template configurations synchronized with all cluster?
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!