OK, I was really restless because of this issue, so I installed a new ARM server in my Hetzner cloud. I setup a new nightly mailcow installation and created one of my live domains with a mailbox.
Then I imported the crypt and vmail backup from my current mailcow, logged into Sogo and voila, dovecot complained about not being able to decrypt the mails
I tried to set the compression of dovecot to LZ4, but unfortunately it wasn’t compiled wit LZ4 support…
Error: zlib_save: Support not compiled in for handler: lz4
So I went along and used the doveadm commands from https://docs.mailcow.email/manual-guides/Dovecot/u_e-dovecot-mail-crypt/ to decrypt the mails in my mailbox, and then encrypted them again. (I had to remove the regex parameters as the busybox find doesn’t regognize them)
Result:
I guess it would be much easier to use a dovecot image compiled with LZ4, otherwise all mailcow admins will have to do the above decrypting and recrypting if zstd is used. And that could take a very long time if you have GBs of mails…