[solution] convert linux mdbox compressed to maildir directories and separate mail

By.

min read

My profile

Share this:

please note:
do this on a separate server! Then Imapsync the result once you are done.
Also note: not all doveadm version support this ->
Error: Couldn’t load plugin /usr/lib/dovecot/doveadm/lib10_doveadm_zlib_plugin.so: Module is for different ABI version 2.1.1 (we have 2.3.ABIv15(2.3.15))

[code:1:7dcf222b67]# Change the owner of the files in mdbox so doveadm has access.
chown -R mail /home/myDomain/imap/myDomain.nl/myUser/mdbox
# Convert mdbox to Maildir. Do this in a temporary folder and not straight into the existing Maildir of the user because this will result in a permission error.
doveadm -o first_valid_uid=1 -o namespace=inbox -o namespace/inbox/inbox=yes -o namespace/inbox/separator=. -o mail_location=mdbox:/home/myDomain/imap/myDomain.nl/myUser/mdbox backup -u mail maildir:/home/myDomain/imap/myDomain.nl/myUser/Maildir_test
# Now copy the converted Maildir into the existing Maildir of the user.
cp -rf /home/myDomain/imap/myDomain.nl/myUser/Maildir_test/. /home/myDomain/imap/myDomain.nl/myUser/Maildir
# Change the owner of the files in Maildir so the user has access.
chown -R myDomain:mail /home/myDomain/imap/myDomain.nl/myUser/Maildir[/code:1:7dcf222b67]

Source
https://forum.directadmin.com/threads/mdbox-to-maildir-conversion.63538/

Share this:

Leave a Reply

Your email address will not be published. Required fields are marked *