Hello,
I have two installations of dovecot configured to replicate mailboxes between them. recently, i upgraded the operating system on one of them (mx2.example.com) and now i'm running one installation on version 2.2.27 (debian stretch) and another on version 2.3.4.1 (mx1.example.com debian buster).
My setup includes 3 shared namespaces that point to the mailboxes of 3 accounts. these accounts are setup to use maildir format.
After upgrading one of the hosts, i started having issues with failed replications on those mailboxes.
I tried running the replication manually and repeatedly by issuing the following on mx1.example.com:
doveadv -d sync -u exception_bucket@example.com -d -l 30 -n -u
and the logs on mx2.example.com included the following lines consistently:
Jul 02 14:21:58 dsync-server(exception_bucket@example.com): Debug: brain S: Change during sync: Mailbox GUID 2d32711ddfd27250390e0000a712b6e3 was lost Jul 02 14:21:58 dsync-server(exception_bucket@example.com): Debug: brain S: We don't have mailbox 2d32711ddfd27250390e0000a712b6e3
I double checked for the existance of the mailbox with that guid (that guid points to the inbox) and the mailbox existed on both servers but, the contents of the mailbox on the two servers where different (missing e-mails on both servers).
I attempted running a force-resync command as follows but with no luck.
doveadm -d force-resync -u exception_bucket@example.com inbox
but the issue persisted. admittedly, i didn't run the command on both servers because i read it doesn't replicate after figuring a workaround.
The next thing i tried was attempting replication without the -n flag, given that you mention that there are some issues replicating shared namespaces. That didn't fix the replication status either.
After looking around, i came onto the solution on this thread: https://dovecot.org/pipermail/dovecot/2017-october/109620.html
which proposed setting mailbox_list_index = no.
This was the default setting on version 2.2.27, so i changed that setting on mx2.example.com which was running version 2.3.4.1.
This allowed the replication to work but i don't think it is a setting i want in my configuration.
Is there something i can do to re-enable dovecot to check index files instead of mailboxes? Could that be an issue when replicating between those two different versions?
I'm attaching the configuration files for both the mailservers, a separate configuration file is included since mail_replica settings are set from there, and a link to the compressed log file i pulled during the operation.
https://filebin.net/d9yygnq8jg74unwb/replication_debug.log.bz2?t=vv2o81ka
Thank you in advance, Apostolis Hardalias