Wednesday 25 January 2012

Thunderbird folder compacting bug

I've been having a bit of a bug with Thunderbird at work, and since nobody else seems to have even posted about it, I might as well mention it here. I keep my email archives in Dropbox, and this has saved my life twice now, but Dropbox is also part of the problem. Two times over the past weeks I have received errors from Thunderbird either claiming that my archive folders are "full" or else they have just disappeared entirely. Upon examination, those files have been deleted - an entire year's worth of email vanished silently. Fortunately for me, Dropbox has an undelete feature, so I was able to recover the files without much trouble, once I noticed they were missing.

My best guess at the cause involves a kind of conflict of timing between Dropbox and Thunderbird and the folder compacting process. At various times, Thunderbird decides that a folder needs to be compacted, which probably means resuming empty space left behind by deleted messages. It is possible that during these times when the folders are being automatically compacted, the file is deleted on disk. When this fact is noticed by Dropbox, it dutifully syncs the file deletion action to their servers and that becomes the official state of the folder. When Thunderbird goes to check again, the file is gone and there are problems.

Mokalus of Borg

PS - My solution was to make Thunderbird ask before compacting, and pause Dropbox while it does so.
PPS - It's not great, but it works.

No comments: