• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Upgrade 10.4.4 to 12: Postfix queue file write error

Ying HaoM

New Pleskian
I just upgraded our Plesk 10.4.4 to 12.0.18 (on Ubuntu 10.04, about to be upgraded to 12.04). Now I get the dreaded 'queue file write error' in postfix on message delivery.

It tries to open /usr/lib/plesk-9.0/postfix-queue (which is not there) in this block in master.cf:

Code:
plesk_virtual unix - n n - - pipe flags=DORhu user=popuser:popuser argv=/usr/lib/plesk-9.0/postfix-local -f ${sender} -d ${recipient} -p /var/qmail/mailnames
127.0.0.1:10025 inet n n n - - spawn user=mhandlers-user argv=/usr/lib/plesk-9.0/postfix-queue 127.0.0.1 10027 before-queue
127.0.0.1:10026 inet n - - - - smtpd  -o smtpd_client_restrictions=  -o smtpd_helo_restrictions=  -o smtpd_sender_restrictions=  -o smtpd_recipient_restrictions=permit_mynetworks,reject  -o smtpd_data_restrictions=  -o receive_override_options=no_unknown_recipient_checks
127.0.0.1:10027 inet n n n - - spawn user=mhandlers-user argv=/usr/lib/plesk-9.0/postfix-queue 127.0.0.1 10026 before-remote
plesk_saslauthd unix y y y - 1 plesk_saslauthd status=5 listen=6 dbpath=/plesk/passwd.db

And on top of that, If disable all the milters/proxy and just try to deliver to plesk_virtual directly, the e-mail just disappears. Postfix thinks it was delivered, but it is not.

I also tried piping some text through /usr/lib/plesk-9.0/postfix-local with the same parameters postfix gives it, but also then nothing. No error, no exit code, no message in maildir.

There are a bunch of fixes around for the queue file write error, but nothing works because the nature of my problem is different. There is a KB article around for Plesk 9, which can hardly be useful.

I tried restoring postfix-queue from the backups, but if I try to use that, the mail.log eventually says:

Code:
Jan 30 01:20:00 ytechosting /usr/lib/plesk-9.0/psa-pc-remote[6621]: Message aborted.

I also used /usr/local/psa/admin/sbin/mchk to no avail: the only change it makes to my master.cf, is adding an empty line. And, I suspect it uninstalled my psa-courier, because it was gone at some point, and mchk was the only thing I did after knowing courier was still there.

How can the postfix config refer to that postfix-queue when it's not there? Is this even a valid master.cf file for Plesk 12?

How do I fix this?
 
Last edited:
A tech support person is already looking at it, in the server, although I haven't seen any activity for a while. They're having a hard time with it. Especially because the postfix-local script just doesn't seem to do anything, so bypassing the proxy-filters doesn't even work.
 
Just for my info. When you do:

Code:
cat earlier-saved-message | /usr/lib/plesk-9.0/postfix-local -f "[email protected]" -d "[email protected]" -p /var/qmail/mailnames

Is it supposed to put that message in /var/qmail/mailnames/target.com/Maildir(/new)? It doesn't, and I don't understand why.
 
Last edited:
I reverted the whole virtual machine because I couldn't get it to work.

In my old Plesk 10.4.4 I confirmed that running the above command indeed just puts the message in that maildir. Even when you do 'echo "sdf"' and pipe it through postfix-local. For some reason, that silently fails on my Plesk 12. No error, no non-zero exit code, nothing. The e-mail message just disappears.

Currently, I'm at a loss...
 
@Ying,

Try to upgrade to 11.5 first and check whether the problem is still present.

If not, than you should try the upgrade from 11.5 to 12.0 (this is a more solid method, the version 10.x is probably to old to allow for a proper direct upgrade to 12.x).

If the issues persists, rollback to 10.x and change postfix to qmail (and upgrade to 11.5, check the problem and upgrade to 12.x).

Please be aware that your earlier problem with the upgrade can have consequences, so back-up all mailboxes (before every upgrade).
 
The admin web panel only allows me to choose version 12 when upgrading. I guess I have to find an installer for version 11?
 
@Ying,

The admin web panel only allows me to choose version 12 when upgrading. I guess I have to find an installer for version 11?

It will be hard to find that "old" installer, since all "current" installers have the nasty habit to (only) present the option of a version 12 installation.

It is very likely that the installer for Plesk 11.5 (https://sp.parallelsnetwork.com/par...ownloads/?_ga=1.53917613.441216693.1423709588) will do the same.

However, if you still have the original installer (as downloaded for the first installation), one could run that (that does the trick on versions 11.0 and 11.5, I am not sure the same applies to the 10.x versions).

Alternatively, you could try to use a test environment (a VM preferably) and use on of the installers found in:

http://autoinstall.plesk.com/PSA_11.5.30/<distribution name>

with

- the distribution name coinciding with your OS, AND
- the installer often to be found in /opt/updater/ (however, have a look at the other directories!!!)

Another option is to try to use a test environment (a VM preferably) and use the autoinstaller from the command line, but that is NOT recommended.

Kind regards.....
 
(I keep missing replies, sorry...)

I don't quite understand. You say running the command line installer from the command line is not recommended, but aren't they all command line?

When I installed Plesk, it put stuff in /root/parallels. I also still have a 'parallels_installer_v3.12.0_build120601.16_os_Ubuntu_10.04_x86_64' in /root. I have no idea what that installs, because it merely states the version of the installer is 3.12.0, not what panel it installs. The mtime of the file is 2013-09-12. I don't quite get that. This machine is older.

It is very likely that the installer for Plesk 11.5 (https://sp.parallelsnetwork.com/par...ownloads/?_ga=1.53917613.441216693.1423709588) will do the same.

The link on that page simply goes to 'http://autoinstall.plesk.com/plesk-installer', so is not version 11 specific, yet the download page is for 11.5. Confusing.
 
@Ying,

To make it more "confusing": you will probably also have installers located at /opt/psa/admin/sbin/autoinstaller and (potentially) /var/cache/parallels_installer/.

However, the issue is not about installers, the problem concerns postfix.

A general problem with postfix can often be resolved by changing to qmail (backup the domains first!) with the autoinstaller (opt/psa/admin/sbin/autoinstaller) and, after changing to qmail, changing back to postfix (again with the autoinstaller).

In essence, this method results in a clean postfix install, making it very unlikely that issues from upgrading Plesk Panel persist.

It only takes a couple of minutes, it is quite fast to change to qmail and back to postfix.

If this method does not yield the desired resolution of the issue, then the postfix problem is related to your upgrade.

Kind regards...
 
What exactly does that switch between qmail and postfix replace? I already compared my master.cf to a file supplied by parallels and it was OK. It seems to be more related to /usr/lib/plesk-9.0/postfix-local and files it calls.

For instance, does /usr/lib/plesk-9.0/postfix-local not exist when you have a qmail install?

Do I have to worry about lost settings when I make that switch? Like e-mail aliases, forwarders, etc?

BTW, can you tell me what /var/lib/plesk/mail/local/local.db contains? The file is not present on Plesk 10. I ask, because in the strace of a failed run, it says:

Code:
# Normal, opening a message and reading 8191 bytes.
open("/opt/psa/handlers/spool/messageaV14oA", O_RDONLY) = 5
read(5, "Return-Path: <[email protected]>\n"..., 8191) = 8191
close(5)  = 0

# Then opening local.db, and read ToKyO CaBiNeT from it?
open("/var/lib/plesk/mail/local/local.db", O_RDONLY) = 5
fcntl(5, F_SETLKW, {type=F_RDLCK, whence=SEEK_SET, start=0, len=0}) = 0
fstat(5, {st_mode=S_IFREG|0600, st_size=528704, ...}) = 0
lseek(5, 0, SEEK_SET)  = 0
read(5, "ToKyO CaBiNeT\n1.0:814\n\0\0\0\0\0\0\0\0\0\0"..., 256) = 256
mmap(NULL, 528704, PROT_READ, MAP_SHARED, 5, 0) = 0x7fdc23e70000
munmap(0x7fdc23e70000, 528704)  = 0
close(5)  = 0

I don't understand it reads "ToKyO CaBiNeT" from it. Are messages stored in that db file?

This call is different between Plesk 10 and 12 and perhaps (part of) the reason it fails.
 
Last edited:
Ying,

Do not focus on problems, just go for the clean install of postfix, which is best to be created (without dataloss) by changing to qmail and back to postfix.

Kind regards
 
I attempted the upgrade again. At first it worked, mail delivery and all. I don't know why, though. I changed a little bit of master.cf stuff, but I think I tried that last month too.

But when I installed some pending updates with aptitude, /usr/bin/deliverquota was gone and delivery failed. I did the:

Code:
/usr/local/psa/admin/sbin/autoinstaller --select-release-current --install-component qmail
/usr/local/psa/admin/sbin/autoinstaller --select-release-current --install-component postfix

And fixed the Postfix config files (I have them in bzr) and then /usr/bin/deliverquota was back. Mail deliver worked again.

Pretty soon I'm going to try to upgrade the Ubuntu system, from 10.04 to 12.04.
 
@Ying,

Don´t try to "fiddle" with the system and/or aptitude, that often does not has the desired results.

Note that you can use the command

./autoinstaller

in the /usr/local/psa/admin/sbin directory, in order to get a menu for installing various components of Plesk.

It is not wise to use the command line autoinstaller, since a mistake with (amongst others) all the options can be easily made.

Furthermore, use a clean install of Ubuntu 12.04 (why not 14.04?) on a new machine, instead of upgrading the OS system on an existing server.

Then migrate the Plesk server, this is the most easy and (more important) more reliable option!

Kind regards...
 
Back
Top