Database backends mismatch!

Everytime I upgrade my system I end up having my cyrus IMAP server borked due to database upgrade problems. The latest was from Ubuntu 9.10 to 10.04 that gave me the following error:

/etc/init.d/cyrus2.2: Database backends mismatch! You must manually
/etc/init.d/cyrus2.2: verify and update the Cyrus databases to the
/etc/init.d/cyrus2.2: new backends.
/etc/init.d/cyrus2.2: Please refer to /usr/share/doc/cyrus-common-2.2/README.Debian
/etc/init.d/cyrus2.2: for instructions.

To fix this I had to edit a bit fo my old instructions for SuSE. The next few steps should get your server working again.

cd /var/lib/cyrus
rm db/*
rm db.backup1/*
rm db.backup2/*
rm deliver.db
rm tls_sessions.db
sudo -u cyrus ctl_mboxlist -d > /tmp/mailboxes.txt
mv mailboxes.db mailboxes.db.old
cvt_cyrusdb /tmp/mailboxes.txt flat /var/lib/cyrus/mailboxes.db skiplist
rm /usr/lib/cyrus/
sudo chown -R cyrus:mail /var/lib/cyrus
dpkg-reconfigure cyrus-common-2.2

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.