Daniel Parthey
2012-Jul-22 19:06 UTC
[Dovecot] Corrupted dbox file - purging found mismatched offsets
Hi, we are running a cluster using mdbox on NFS with director+mailbox on each node. After running our daily doveadm purge loop over all users, we got dbox corruption... doveadm user "*" |\ while read username do doveadm -c /etc/dovecot-director/dovecot-director.conf -D purge -u "$username" done For one user (which deleted a lot of messages from his mailboxes today), we got the following error in the dovecot.log: Jul 22 20:10:36 10.129.3.213 dovecot: doveadm(user at example.org): Error: Corrupted dbox file /mail/dovecot/example.org/user/mail/storage/m.24 (around offset=1380859): purging found mismatched offsets (1380829 vs 920527, 3/61) Jul 22 20:10:36 10.129.3.213 dovecot: doveadm(user at example.org): Warning: mdbox /mail/dovecot/example.org/user/mail/storage: rebuilding indexes What does this message exactly tell me and how to prevent this in the future? Now the indexes are broken and flags are lost. The "storage" directory content of the affected user looks as follows: drwx------ 2 vmail vmail 4096 2012-07-22 20:10 . drwx------ 4 vmail vmail 4096 2012-05-06 12:16 .. -rw------- 1 vmail vmail 99008 2012-07-22 20:10 dovecot.map.index -rw------- 1 vmail vmail 33016 2012-07-22 20:10 dovecot.map.index.log -rw------- 1 vmail vmail 34664 2012-07-22 20:10 dovecot.map.index.log.2 -rw------- 1 vmail vmail 8134 2012-05-16 11:36 m.22 -rw------- 1 vmail vmail 10572466 2012-06-02 23:09 m.24 -rw------- 1 vmail vmail 1380205 2012-05-27 10:59 m.24.broken -rw------- 1 vmail vmail 6506837 2012-06-09 15:42 m.25 -rw------- 1 vmail vmail 18201641 2012-06-17 22:50 m.26 -rw------- 1 vmail vmail 11345293 2012-07-01 14:37 m.28 -rw------- 1 vmail vmail 36707787 2012-07-08 23:05 m.29 -rw------- 1 vmail vmail 6062419 2012-07-15 23:34 m.30 -rw------- 1 vmail vmail 52396198 2012-07-22 20:10 m.31 -rw------- 1 vmail vmail 3067862 2012-07-20 14:31 m.32 -rw------- 1 vmail vmail 44520965 2012-07-20 14:31 m.33 -rw------- 1 vmail vmail 52426605 2012-07-22 20:10 m.34 -rw------- 1 vmail vmail 28984844 2012-07-22 20:10 m.35 -rw------- 1 vmail vmail 14465248 2012-07-22 20:10 m.36 -rw------- 1 vmail vmail 37451127 2012-07-22 20:10 m.37 -rw------- 1 vmail vmail 41494033 2012-07-22 20:10 m.38 -rw------- 1 vmail vmail 52066924 2012-07-22 20:10 m.39 -rw------- 1 vmail vmail 49785529 2012-07-22 20:10 m.40 -rw------- 1 vmail vmail 23509886 2012-07-22 20:10 m.41 -rw------- 1 vmail vmail 29339462 2012-07-22 20:10 m.42 -rw------- 1 vmail vmail 29510420 2012-07-22 20:10 m.43 -rw------- 1 vmail vmail 50896380 2012-07-22 20:10 m.44 -rw------- 1 vmail vmail 8331046 2012-07-22 20:10 m.45 -rw------- 1 vmail vmail 5903744 2012-07-22 20:10 m.46 -rw------- 1 vmail vmail 70281 2012-07-22 20:10 m.47 -rw------- 1 vmail vmail 27397909 2012-07-22 20:10 m.48 -rw------- 1 vmail vmail 3893509 2012-07-22 20:10 m.49 -rw------- 1 vmail vmail 1410097 2012-07-22 20:10 m.50 -rw------- 1 vmail vmail 1905759 2012-07-22 20:10 m.51 -rw------- 1 vmail vmail 51783968 2012-05-06 12:12 m.9 Any hints on how to prevent dbox corruption in this case? And what should I do with the "m.24.broken" file now? Regards Daniel -- https://plus.google.com/103021802792276734820 -------------- next part -------------- # 2.1.8: /etc/dovecot/dovecot.conf # OS: Linux 2.6.32-40-server x86_64 Ubuntu 10.04.4 LTS auth_cache_negative_ttl = 0 auth_cache_size = 10 M auth_cache_ttl = 1 mins auth_verbose = yes auth_verbose_passwords = sha1 deliver_log_format = mailbox: deliver: msgid=%m from=%f: %$ dict { quota = mysql:/etc/dovecot/conf.d/dovecot-dict-sql.conf.ext } disable_plaintext_auth = no doveadm_password = xxx imapc_features = rfc822.size imapc_host = local-mailbox imapc_port = 18143 instance_name = dovecot-mailbox lda_mailbox_autocreate = yes lda_mailbox_autosubscribe = yes login_greeting = Mailbox login_log_format = mailbox: login: %$: %s login_trusted_networks = 10.129.3.0/24 mail_debug = yes mail_fsync = always mail_gid = vmail mail_home = /mail/dovecot/%d/%n mail_location = mdbox:~/mail mail_log_prefix = "mailbox: mail: %s(%u): " mail_plugins = quota stats mail_privileged_group = vmail mail_uid = vmail managesieve_implementation_string = Sieve managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave mdbox_rotate_interval = 1 weeks mdbox_rotate_size = 50 M mmap_disable = yes passdb { args = /etc/dovecot/conf.d/dovecot-sql.conf.ext driver = sql } plugin { quota = dict:User quota::proxy::quota quota_rule = *:storage=10G quota_rule2 = Trash:storage=+100M quota_warning = storage=95%% quota-warning 95 %u quota_warning2 = storage=80%% quota-warning 80 %u sieve = ~/.dovecot.sieve sieve_dir = ~/sieve stats_refresh = 30 secs stats_track_cmds = yes } protocols = imap pop3 lmtp sieve service auth { unix_listener auth-userdb { group = dovecot mode = 0660 user = dovecot } } service dict { unix_listener dict { group = vmail mode = 0660 } } service doveadm { inet_listener doveadm-server { port = 19000 } } service imap-login { inet_listener imap { port = 19143 } } service imap-postlogin { executable = script-login /usr/local/bin/dovecot-postlogin user = $default_internal_user } service imap { executable = imap imap-postlogin } service lmtp { inet_listener lmtp { address = * port = 19024 } } service managesieve-login { inet_listener sieve { port = 19200 } } service pop3-login { inet_listener pop3 { port = 19110 } } service pop3-postlogin { executable = script-login /usr/local/bin/dovecot-postlogin user = $default_internal_user } service pop3 { executable = pop3 pop3-postlogin } service quota-warning { executable = script /usr/local/bin/quota-warning extra_groups = dovecot unix_listener quota-warning { user = vmail } user = vmail } service stats { fifo_listener stats-mail { mode = 0600 user = vmail } } ssl = no userdb { driver = prefetch } userdb { args = /etc/dovecot/conf.d/dovecot-sql.conf.ext driver = sql } verbose_proctitle = yes protocol imap { imap_client_workarounds = delay-newmail tb-extra-mailbox-sep mail_plugins = quota stats imap_quota imap_stats } protocol lmtp { mail_plugins = quota stats sieve } -------------- next part -------------- # 2.1.8: /etc/dovecot-director/dovecot-director.conf # OS: Linux 2.6.32-40-server x86_64 Ubuntu 10.04.4 LTS auth_verbose = yes auth_verbose_passwords = sha1 base_dir = /var/run/dovecot-director deliver_log_format = director: deliver: msgid=%m from=%f: %$ director_doveadm_port = 20000 director_mail_servers = 10.129.3.193 10.129.3.192 10.129.3.191 10.129.3.190 director_servers = 10.129.3.193 10.129.3.192 10.129.3.191 10.129.3.190 director_user_expire = 2 days disable_plaintext_auth = no doveadm_password = xxx doveadm_proxy_port = 19000 instance_name = dovecot-director lmtp_proxy = yes login_greeting = Mail Balancer login_log_format = director: login: %$: %s login_trusted_networks = 10.129.3.0/24 mail_debug = yes mail_fsync = always mail_gid = vmail mail_home = /mail/dovecot/%d/%n mail_location = mdbox:~/mail mail_log_prefix = "director: mail: %s(%u): " mail_privileged_group = vmail mail_uid = vmail managesieve_notify_capability = mailto managesieve_sieve_capability = fileinto reject envelope encoded-character vacation subaddress comparator-i;ascii-numeric relational regex imap4flags copy include variables body enotify environment mailbox date ihave mmap_disable = yes passdb { args = /etc/dovecot-director/conf.d/dovecot-sql.conf.ext driver = sql } protocols = imap pop3 lmtp sieve service auth { unix_listener auth-userdb { user = dovecot } } service director { fifo_listener login/proxy-notify { mode = 0666 } inet_listener { port = 9090 } unix_listener director-userdb { mode = 0600 } unix_listener login/director { mode = 0666 } } service doveadm { executable = doveadm-server director inet_listener doveadm-server { port = 20000 } } service imap-login { executable = imap-login director inet_listener imap { port = 20143 } inet_listener imaps { port = 20993 ssl = yes } } service lmtp { inet_listener lmtp { address = * port = 20024 } } service managesieve-login { executable = managesieve-login director inet_listener sieve { port = 20200 } } service pop3-login { executable = pop3-login director inet_listener pop3 { port = 20110 } inet_listener pop3s { port = 20995 ssl = yes } } ssl_cert = </etc/certs/wildcard.net.crt ssl_key = </etc/certs/wildcard.net.key userdb { driver = prefetch } userdb { args = /etc/dovecot-director/conf.d/dovecot-sql.conf.ext driver = sql } verbose_proctitle = yes protocol lmtp { auth_socket_path = director-userdb } protocol sieve { auth_socket_path = director-userdb } protocol doveadm { auth_socket_path = director-userdb } protocol imap { imap_client_workarounds = delay-newmail tb-extra-mailbox-sep }
Seemingly Similar Threads
- Dovecot 2.1.16 doveadm purge -A segfault
- [SIEVE] Locking Errors with vnd.dovecot.duplicate Extension
- doveadm purge -A via doveadm-proxy director fails after some users
- Corrupted mdbox on LMTP director delivery while user is logged in via IMAP
- lmtp proxy timeout while waiting for reply to DATA reply