Inconsistency in map index with dovecot v2.3.21
Hi,
since I upgraded dovecot to version 2.3.21 on a FreeBSD 13.2 system, I've been seeing a few occurences of the following warnings daily:
Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp(user1)<8209>
The numbers in parentheses seem to always be of the format (x,40 != x,56) or (x,40 != x,72).
I also get such errors on some users when purging (doveadm-purge fails with error 75):
doveadm(user2): Warning: mdbox /var/vmail/users/user2/mdbox/storage: Inconsistency in map index (5,40 != 5,72) doveadm(user2): Warning: fscking index file /var/vmail/users/user2/mdbox/storage/dovecot.map.index doveadm(user2): Warning: mdbox /var/vmail/users/user2/mdbox/storage: rebuilding indexes doveadm(user2): Error: Purging namespace '' failed: BUG: Unknown internal error
If I rerun doveadm purge for this user it completes successfully.
Can anyone shed some light on what might be causing these messages? I didn't have these with 2.3.20. Should I be worried about data loss due to these index inconsistencies?
I have the same problem after updating dovecot 2.3.21, I am receiving the errors below for the accounts when I perform backups.
doveadm(user@user.com.br): Error: Purging namespace '' failed: BUG: Unknown internal error Error: failed sync dir: doveadm(user2@user2.com.br): Warning: mdbox /data/data/mailboxbackup/20240207/user2.com.br/u/ser/user2.com.br/mdbox/storage: Inconsistency in map index (42,40 != 42,56) doveadm(user2@user2.com.br): Warning: fscking index file /data/data/mailboxbackup/20240207/user2.com.br/u/ser/user2/mdbox/storage/dovecot.map.index doveadm(user2@user2.com.br): Warning: mdbox /data/data/mailboxbackup/20240207/user2.com.br/u/ser/user2.com.br/mdbox/storage: rebuilding indexes doveadm(user2@user2.com.br): Warning: Transaction log file /data/data/mailboxbackup/20240207/user2.com.br/u/ser/user2/mdbox/storage/dovecot.map.index.log was locked for 284 seconds (mdbox storage rebuild) doveadm(user2@user2.com.br): Error: Purging namespace '' failed: BUG: Unknown internal error
As in the case of our friend the other day, the error no longer happens on the same account, it happens on another random one.
On 12. Jan 2024, at 9.37, John Alex. via dovecot dovecot@dovecot.org wrote:
Hi,
since I upgraded dovecot to version 2.3.21 on a FreeBSD 13.2 system, I've been seeing a few occurences of the following warnings daily:
Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp(user1)<8209>
: Warning: mdbox /var/vmail/users/user1/mdbox/storage: Inconsistency in map index (5,40 != 5,56) Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp(user1)<8209> : Warning: fscking index file /var/vmail/users/user1/mdbox/storage/dovecot.map.index Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp(user1)<8209> : Warning: mdbox /var/vmail/users/user1/mdbox/storage: rebuilding indexes Jan 11 13:13:26 dimokritos dovecot[33170]: lmtp(user1)<8209> : Warning: fscking index file /var/vmail/users/user1/mdbox/storage/dovecot.map.index
Hmm. I can't seem to be able to reproduce it easily at least. Looking at the code changes, I do see now that there is one related change that may be wrong, or at least the commit message is wrong: https://github.com/dovecot/core/commit/aae93d3ea73004ba1883bbf91c9e40f613ffc... - although it shouldn't affect anything unless there are already some other errors. But maybe there's something I don't see right now. Can you try if the errors go away by reverting this change?
Should I be worried about data loss due to these index inconsistencies?
No data loss, but it can lead to inefficient rebuilds.
On 2024-02-10 2:24 a.m., Timo Sirainen wrote:
On 12. Jan 2024, at 9.37, John Alex. via dovecotdovecot@dovecot.org wrote:
since I upgraded dovecot to version 2.3.21 on a FreeBSD 13.2 system, I've been seeing a few occurences of the following warnings daily:
Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp(user1)<8209>
: Warning: mdbox /var/vmail/users/user1/mdbox/storage: Inconsistency in map index (5,40 != 5,56) Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp(user1)<8209> : Warning: fscking index file /var/vmail/users/user1/mdbox/storage/dovecot.map.index Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp(user1)<8209> : Warning: mdbox /var/vmail/users/user1/mdbox/storage: rebuilding indexes Jan 11 13:13:26 dimokritos dovecot[33170]: lmtp(user1)<8209> : Warning: fscking index file /var/vmail/users/user1/mdbox/storage/dovecot.map.index Hmm. I can't seem to be able to reproduce it easily at least. Looking at the code changes, I do see now that there is one related change that may be wrong, or at least the commit message is wrong:https://github.com/dovecot/core/commit/aae93d3ea73004ba1883bbf91c9e40f613ffc... - although it shouldn't affect anything unless there are already some other errors. But maybe there's something I don't see right now. Can you try if the errors go away by reverting this change?
We are getting the same warnings on 2 separate test servers; one with local ZFS storage, the other one with NFS storage (single server, data not shared with any other servers). We are imapsync'ing a few hundred user accounts from the production server so there is a lot of emails transfer a day. The warnings occur at random times and with random users.
I reinstalled 2.3.21 from source (originally was using Dovecot repo packages) and tested by reverting that commit. The warnings continued.
Next I tried with Dovecot 2.3.20 and still got the same warnings after a while.
# 2.3.20 (80a5ac675d): /usr/local/etc/dovecot/dovecot.conf # Pigeonhole version 0.5.20 (149edcf2) # OS: Linux 5.4.0-171-generic x86_64 Ubuntu 20.04.6 LTS nfs4
Feb 13 15:38:25 dovecot: imap-login: Login: user=<username>,
method=PLAIN, rip=127.0.0.1, lip=127.0.0.1, mpid=272469, TLS,
session=
I will try with an even older version to continue testing...
On 2024-02-10 2:24 a.m., Timo Sirainen wrote: On 12. Jan 2024, at 9.37, John Alex. via dovecot dovecot@dovecot.org wrote: since I upgraded dovecot to version 2.3.21 on a FreeBSD 13.2 system, I've been seeing a few occurences of the following warnings daily:
Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp
(user1)<8209><SId/BlXNn2URIAAA+iYuTQ:T2>: Warning: mdbox /
var/vmail/users/user1/mdbox/storage: Inconsistency in map
index (5,40 != 5,56)
Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp
(user1)<8209><SId/BlXNn2URIAAA+iYuTQ:T2>: Warning: fscking
index file /var/vmail/users/user1/mdbox/storage/
dovecot.map.index
Jan 11 13:13:25 dimokritos dovecot[33170]: lmtp
(user1)<8209><SId/BlXNn2URIAAA+iYuTQ:T2>: Warning: mdbox /
var/vmail/users/user1/mdbox/storage: rebuilding indexes
Jan 11 13:13:26 dimokritos dovecot[33170]: lmtp
(user1)<8209><SId/BlXNn2URIAAA+iYuTQ:T2>: Warning: fscking
index file /var/vmail/users/user1/mdbox/storage/
dovecot.map.index
Hmm. I can't seem to be able to reproduce it easily at least. Looking
at the code changes, I do see now that there is one related change
that may be wrong, or at least the commit message is wrong: https://
github.com/dovecot/core/commit/
aae93d3ea73004ba1883bbf91c9e40f613ffc857 - although it shouldn't
affect anything unless there are already some other errors. But maybe
there's something I don't see right now. Can you try if the errors go
away by reverting this change?
We are getting the same warnings on 2 separate test servers; one with local ZFS
storage, the other one with NFS storage (single server, data not shared with
any other servers).
We are imapsync'ing a few hundred user accounts from the production server so
there is a lot of emails transfer a day. The warnings occur at random times and
with random users.
I reinstalled 2.3.21 from source (originally was using Dovecot repo packages)
and tested by reverting that commit. The warnings continued.
Next I tried with Dovecot 2.3.20 and still got the same warnings after a while.
# 2.3.20 (80a5ac675d): /usr/local/etc/dovecot/dovecot.conf
# Pigeonhole version 0.5.20 (149edcf2)
# OS: Linux 5.4.0-171-generic x86_64 Ubuntu 20.04.6 LTS nfs4
Feb 13 15:38:25 dovecot: imap-login: Login: user=<username>, method=PLAIN,
rip=127.0.0.1, lip=127.0.0.1, mpid=272469, TLS, session=
Apologies for the formatting. Retrying with HTML formatting disabled:
We are getting the same warnings on 2 separate test servers; one with local ZFS storage, the other one with NFS storage (single server, data not shared with any other servers). We are imapsync'ing a few hundred user accounts from the production server so there is a lot of emails transfer a day. The warnings occur at random times and with random users.
I reinstalled 2.3.21 from source (originally was using Dovecot repo packages) and tested by reverting that commit. The warnings continued.
Next I tried with Dovecot 2.3.20 and still got the same warnings after a while.
# 2.3.20 (80a5ac675d): /usr/local/etc/dovecot/dovecot.conf # Pigeonhole version 0.5.20 (149edcf2) # OS: Linux 5.4.0-171-generic x86_64 Ubuntu 20.04.6 LTS nfs4
Feb 13 15:38:25 dovecot: imap-login: Login: user=<username>,
method=PLAIN, rip=127.0.0.1, lip=127.0.0.1, mpid=272469, TLS,
session=
I will try with an even older version to continue testing...
participants (4)
-
caio@skymail.com.br
-
John Alex.
-
Oscar del Rio
-
Timo Sirainen