Am 25.03.2013 15:38, schrieb Timo Sirainen:
Hi,
The same problem was reported by Ralf Hildebrandt one year ago. The bug should be fixed with revision 3599790da3d7 but it seems to be there again.
The Dovecot bug was fixed, but the real reason for this is that the S=values are wrong in your maildir. You can either run the fixing script or set maildir_broken_filename_sizes=yes.
Looks like this (or a related) bug still exist.
If you have a Maildir-Storage with gzip compression enabled, everything's working fine if the user receives mail by LMTP. The mail is saved in his Maildir-Storage, having the right (uncompressed) size in the filename.
vmail vmail 1.9K Mar 26 22:17 1364332643.M527513P23361.mailserver2,S=3780,W=3860:2
But:
If the dovecot.index is broken, corrupt or deleted, Dovecot isn't able to rebuild his index-files.
In Step ONE dovecot creates his index-files, but looks like Dovecot's using the (smaller) FILEsize instead of the (larger) real size.
In Step TWO Dovecot's realizing that the cached size and the stored file size in the filename doesn't fit together. But Dovecot doesn't fix his index file; instead Dovecot's renaming the Maildir-Files, storing the (small) file size in the filename.
Mar 26 22:39:17 mailserver2 dovecot: imap(testuser): Error: Cached message size smaller than expe cted (1467 < 3780)
Error: Maildir filename has wrong S value, r enamed the file from /var/vmail/uni-greifswald.de/testuser/Maildir/cur/1364332643.M527513P23361.m ailserver2,S=3780,W=3860:2, to /var/vmail/uni-greifswald.de/testuser/Maildir/cur/1364332643.M5275 13P23361.mailserver2,S=1856:2,
HOW TO REPRODUCE:
*) Create a Maildir-Store with zip enabled *) Deliver Mails into it. Everything's working fine, the filenames are right *) Delete dovecot.index* *) STEP ONE: Dovecot's complaining about broken index-files *) STEP TWO: Dovecot's renaming the files
I haven't seen any way to find to workaround or repair this broken Maildir-Storage. Even if I rename all files and set sizes in the filenames, Dovecot's complaining about the mismatch in his cache and starts his (broken) repair action.
If we're right, this could be grow to a real problem. Every Server with zipped Maildirs can be completly ruined just by deleting his index-cache-files.
Peer
-- Heinlein Support GmbH Schwedter Str. 8/9b, 10119 Berlin
http://www.heinlein-support.de
Tel: 030 / 405051-42 Fax: 030 / 405051-19
Zwangsangaben lt. §35a GmbHG: HRB 93818 B / Amtsgericht Berlin-Charlottenburg, Geschäftsführer: Peer Heinlein -- Sitz: Berlin