Postfix not working after update

Debian: 9 (and 10)

I updated some packages from the virtualmin interface a few days ago and now PostFix does not seem to work.
I tried many things: rebooting, restarting postfix, upgrading debian from 9 to 10. But it still won’t start when I click the ‘start’ button on the virtualmin main page (under status).

I logged in using putty and did this:

service postfix status

● postfix.service - Postfix Mail Transport Agent
Loaded: loaded (/lib/systemd/system/postfix.service; disabled; vendor preset: enabled)
Active: active (exited) since Fri 2020-10-09 05:26:54 PDT; 6min ago
Process: 3059 ExecStart=/bin/true (code=exited, status=0/SUCCESS)
Main PID: 3059 (code=exited, status=0/SUCCESS)

Oct 09 05:26:54 …: Starting Postfix Mail Transport Agent…
Oct 09 05:26:54 …: Started Postfix Mail Transport Agent.

postfix -v check

postfix: name_mask: all
postfix: inet_addr_local: configured 5 IPv4 addresses
postfix: inet_addr_local: configured 2 IPv6 addresses
postfix: Postfix is running with backwards-compatible default settings
postfix: See http://www.postfix.org/COMPATIBILITY_README.html for details
postfix: To disable backwards compatibility use “postconf compatibility_level=2” and “postfix reload”
postfix/postfix-script: warning: symlink leaves directory: /etc/postfix/./makedefs.out
postfix/postfix-script: warning: /var/spool/postfix/etc/ssl/certs/ca-certificates.crt and /etc/ssl/certs/ca-certificates.crt differ
postfix/postfix-script: warning: /var/spool/postfix/lib/i386-linux-gnu/libnss_systemd.so.2 and /lib/i386-linux-gnu/libnss_systemd.so.2 differ

I looked at the log and saw similar warnings as above:
Oct 9 05:35:00 …: name_mask: all
Oct 9 05:35:00 …: inet_addr_local: configured 5 IPv4 addresses
Oct 9 05:35:00 …: inet_addr_local: configured 2 IPv6 addresses
Oct 9 05:35:00 …: Postfix is running with backwards-compatible default settings
Oct 9 05:35:00 …: See http://www.postfix.org/COMPATIBILITY_README.html for details
Oct 9 05:35:00 …: To disable backwards compatibility use “postconf compatibility_level=2” and “postfix reload”
Oct 9 05:35:04 …: warning: symlink leaves directory: /etc/postfix/./makedefs.out
Oct 9 05:35:04 …: warning: /var/spool/postfix/etc/ssl/certs/ca-certificates.crt and /etc/ssl/certs/ca-certificates.crt differ
Oct 9 05:35:05 …: warning: /var/spool/postfix/lib/i386-linux-gnu/libnss_systemd.so.2 and /lib/i386-linux-gnu/libnss_systemd.so.2 differ

I looked at the postfix compatibility web page but I am not sure what options make it go in compatiblity. Also these are warnings so I am guessing this would not prevent postfix from running.

I also tried these but when I look at the postfix status, it is the same as above:
/etc/init.d/postfix start
service postfix restart

Your config files were probably overwritten during the upgrade. You may want to check them in /etc/postfix. The two most important files are main.cf and master.cf

Thanks for the suggestion.
It seems that both files were not modified since they are exact matches with my previous backup.
Anything else I could check?

I also tried this but got the same issue:
apt-get install --reinstall postfix
/etc/init.d/postfix start
/etc/init.d/postfix status

I would probably compare your current config files that I mentioned before with the ones from the new package. There probably is a setting in the new config files that you need hence the reason it’s going into backwards compatibility mode. You can usually find/view the new package files online.

My postfix stopped working now I can’t receive / send emails. I’m using Postfix version 2.11.3. The configuration check tells me nothing useful; it doesn’t indicate any errors (not obvious, no red text or error messages. Used a wide net - grep -iR postfix *.log > postfixGrepLogs.txt in /var/logs folder since I see no postfix log file).

I’ve been grepping the 2GB file of postfix log messages trying to find a clue but (looking for error, fail, start, exit, fatal. Only fatal returned a small number of hits which looks promising, will look into that further. Would be nice if the config check highlighted errors when there are any.

2GB of messages in log like these, which are probably normal as these are email relay rejections:

/usr/sbin/postconf: warning: /etc/postfix/master.cf: undefined parameter:  mua_sender_restrictions
/usr/sbin/postconf: warning: /etc/postfix/master.cf: undefined parameter: mua_client_restrictions
/usr/sbin/postconf: warning: /etc/postfix/master.cf: undefined parameter: mua_helo_restrictions
/usr/sbin/postconf: warning: /etc/postfix/master.cf: undefined parameter: mua_sender_restrictions
/usr/sbin/postconf: warning: /etc/postfix/master.cf: undefined parameter: mua_helo_restrictions
/usr/sbin/postconf: warning: /etc/postfix/master.cf: undefined parameter: mua_sender_restrictions
/usr/sbin/postconf: warning: /etc/postfix/master.cf: undefined parameter: mua_client_restrictions
/usr/sbin/postconf: warning: /etc/postfix/master.cf: undefined parameter: mua_helo_restrictions
/usr/sbin/postconf: warning: /etc/postfix/main.cf: unused parameter: unknown_sender_reject_code=554

What I don’t know about Postfix can fill several large libraries, so consider this advice worth every penny I’m billing you for it.

The following worked for me when I was having a similar problem with Postfix 2 point something before I updated to 3.5.3.

Back up /etc/postfix/main.cf and try inserting the following into the end of the file:

smtpd_restriction_classes = mua_sender_restrictions, mua_client_restrictions, mua_helo_restrictions
mua_client_restrictions = permit_sasl_authenticated, reject
mua_sender_restrictions = permit_sasl_authenticated, reject
mua_helo_restrictions = permit_mynetworks, reject_non_fqdn_hostname, reject_invalid_hostname, permit
meta_directory = /etc/postfix
shlib_directory = /usr/lib/postfix
tls_server_sni_maps = hash:/etc/postfix/sni_map

Then restart Postfix and hope for the best.

Richard

@thomnet please don’t hijack topics. Start a new topic for new issues. Your issue is not the same as OP.

OK, I’ll start a fresh one then.

It’s postfix isn’t it? And I did update, not sure if that was the cause.

It’s definitely not the same issue. Very different messages in the logs.

OK, looking for “appropriate” place on this forum to post it then Got any suggestions Joe?

Start a new topic. The “Help” category is fine.

Done. Postfix won't start, can't figure out why

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.