Applicable to:
- Plesk for Linux
Question
Customized entries in
/etc/postfix/main.cf
and
/etc/postfix/master.cf
get reverted after running the plesk repair mail
command, installation of Plesk microupdates, changes made in Plesk GUI > Tools & Settings > Mail Server Settings or after starting to use the Plesk Email Security extension. Why do these changes get reverted?
Answer
These Postfix configuration resets are intended and Plesk functionality depends on them happening.
Plesk rewrites the Postfix config files if corresponding mail settings are changed and it needs to be able to do so in order to deliver a consistent and well-functioning mail configuration.
The Plesk Email Security extension requires almost constant access to these configuration files in order to deliver consistent results as well.
Postfix configuration files will also often be regenerated during any Postfix package updates.
You may vote for the feature request of keeping Postfix customization files untouched by Plesk on the following link:
Allow customization of /etc/postfix/main.cf and /etc/postfix/master.cf – Your Ideas for Plesk
Top-ranked suggestions are likely to be included in future versions of Plesk
As a workaround, you may reapply the changes made to the /etc/postfix/main.cf
at a given period of time (15 minutes in the example below) by setting up a cron job while following these steps:
1. Log into your server via SSH as the root user
2. Executing the following command in order to reach edit the crontab on your Linux server:
# crontab -e
3. Add a line that would edit the Postfix configuration and restart Postfix in order to apply the changes at every 15th minute:
*/15 * * * * postconf "inet_protocols = ipv4" && systemctl restart postfix
4. Save the changes
Whenever this cron job runs, the inet_protocols
in Postfix will be set to ipv4 and Postfix will be restarted in order to apply the changes.
Comments
0 comments
Please sign in to leave a comment.