Error: Corrupted index cache file

Sohin Vyacheslav slawa at
Fri Feb 10 15:15:47 UTC 2023

Hi All,

In mail.log exists an error messages "Error: Corrupted index cache file 
/data/mail/vhosts/ at 
invalid record size" for some accounts.

I tried these steps to fix it:

1. Running commands
# doveadm -D -v index -u user at INBOX
# doveadm -v force-resync -u user at INBOX

after this I saw that the following files are updated in ../Maildir/:

But after some time error messages occurred again.

2. Added NFS mount option 'nordirplus' to /etc/fstab with remount /data 
partition, add 'mmap_disable = yes' and 'mail_fsync = always' to 
10-mail.conf as advised on (because /data 
partition mounted via NFS);

3. Renaming 3 files with/without Dovecot service pre-stop.

# mv dovecot.index old.dovecot.index
# mv dovecot.index.cache old.dovecot.index.cache
# mv dovecot.index.log old.dovecot.index.log

Unfortunately, all done steps didn't fix issue.
What is the proper way to fix corrupted index cache errors?

dovecot package: 1: (Ubuntu-18.04).

p.s. for some of email accounts also exists error messages "Error: 
Broken file ../Maildir/dovecot-uidlist line ###: Invalid data:" besides 
mentioned cache error.

Best wishes
Sohin Vyacheslav

More information about the dovecot mailing list