Thunderbird: What does Repair Folder ACTUALLY do?
What does repair folder actually do?
A search online gets answers like 'it rebuilds the index', but that's not very explanatory. Does it recreate the index by looking at the folder contents or by going back to the server and downloading emails again?
After a couple of odd things happening (emails appearing in the web version of Gmail, but not in my Thunderbird Inbox), I decided to repair my Inbox. It's an IMAP account with Gmail, and has got over 700 messages in it (yes I know, time for a clear out...).
Thunderbird went slow for quite a long time (like half an hour at least), and messages kept flashing up in the status bar at the bottom saying stuff like "Downloading message 237 of 700". When clicking on messages with large attachments, while the repair was apparently still underway, the messages took some time to load, though they seem to be about normal now.
Was it really downloading emails? I ask, because I have some archive folders MUCH bigger than the Inbox, and would like to know what to expect if I have to repair other folders.
For info: Thunderbird 91.11.0 (64-bit) running under Linux Mint 19.1
Всички отговори (7)
Yes, the messages are downloaded, as Thunderbird must do that in order to read the messages.
david said
Yes, the messages are downloaded, as Thunderbird must do that in order to read the messages.
Thanks for the reply.
I get that Thunderbird needs to download messages to read them, that goes without saying, but I was hoping for more detail about what the repair function does.
I just tried a test with another folder, one with about 5000 emails in it, taking up 200MB on disc, and repairing it doesn't seem to download the whole folder again. There was very little internet traffic during the repair process, except when I deliberately viewed a couple of emails with large attachments, and the file itself is currently only about 10MB.
Променено на
Emails are downloaded and a copy is put into an mbox text file which has same name as the folder in FolderPane. As more emails are downloaded they get appended to that mbox text file one after other. However, it would be an enormous load physically loading each email just to display a few details as you see in the Message List - aka Thread Pane. So, Thunderbird uses an index file for that purpose. In the profile name account name folders it is a file with .msf extension. Each folder you see in folder will have same setup. This means you have eg: 'Inbox' (mbox file) storing emails and 'Inbox.msf' which is an index file.
The index file should be in synch with the mbox file. The index file is used to create the list you see in ThreadPane. When you select an email in the list, the index is pointing to the correct email in the mbox file, so it can then access the stored email in mbox file and display it's contents in Message Pane.
When you 'Repair folder' it repairs the index file so it matches the contents of the mbox file. However, with imap accounts, all imap folders are synchronised with their corresponding server folders. So Thunderbird checks mbox it is correct with what is on server and then rebuilds the index, so display is now correct.
You are more likely to get more of a change with some folders like Inbox than with a general storage folder.
re :older, one with about 5000 emails in it, taking up 200MB on disc Please note this means you are storing about 5000 emails in a single text file document which is 200MB in size.
Whether you use imap or pop, I would advise you create a backup every so often and always before updating to a major release eg: from 91* to 102* If you use Imap then you cannot truely say those downloaded emails are an independent copy because all imap folders synchronise with server folders to display whatever is held on server.
That's great, thanks for the detailed explanation.
A while after I'd repaired the other folder I had another look in the relevant folder, and the file size had gone up to 200MB again. So, either the repair process takes a lot longer than I thought, or it was waiting for some inactive time before downloading the rest of the messages.
Променено на
You probably already do this, but it is advisable to compact folders on a regular basis. In particular this applies to Inbox, Drafts and Junk/Spam folders as they tend to get the most activity, but it applies to any folder. eg: if you decide to reorganise and move emails into eg: subfolders
When you delete or move an email, that email reappears in another folder or Trash. However, the deleted/moved email is still in the original folder, but now it is marked as deleted and hidden. When you compact the folder, the mbox file is opened and a new copy is made but those hidden marked as deleted emails are not copied over. Then the new file replaces the old file and a new index is created. Basically the file is cleaned up and reduced in size. Compacting is good housekeeping and helps to maintain a healthy thunderbird.
As a user, I've also experienced issues with my email inbox before and have had to use the repair function. From my understanding, the repair folder function rebuilds the index of the folder, which could involve downloading emails from the server again or just reorganizing the existing contents of the folder. I'm not sure about the specifics of Thunderbird's repair process, but I do recall it taking a while to complete. If you have larger archive folders that need repairing, it's possible that it may take even longer. I hope this helps! By the way, if you ever need a [Laurel] Repair Laurel Service in your area, you can search online for local repair shops.
Toad-Hall said
When you 'Repair folder' it repairs the index file so it matches the contents of the mbox file.
Loosely put, "Repair" reads the mbox file and recreates the .msf index file, using message headers contained in the mbox file.