How to repair a defective e-mail in one of kmail’s local maildir folders?

The symptom is probably that you can see the e-mail in the overview (title, date), but no contet is shown and you cannot move the e-mail to another kmail folder, or delete it. Solution:

  1. Find the file that corresponds to the e-mail. Your e-mails are normally stored somewhere below ~./kmail/.
  2. Move this file to another folder outside the kmail folder.
  3. Re-start kmail. Now, the e-mail is gone.
  4. In kmail, do “File -> Open …” and open the e-mail’s file that you moved in step 2.
  5. In the window that opens for this e-mail, say “File -> Save as …” and save as an .mbox file somewhere.
  6. In kmail, do “File -> Import e-mail …”, select “Import of mbox files (Unix, Evolution)”, then select the .mbox file you saved in step 5. You cannot import the e-mail’s (from step 2) file directly, as the KMail import filter cannot handle that, except if placed in a kmail maildir-style folder structure.
  7. The .mbox file is imported in a newly created folder “MBOX-[…]”. Move the e-mail from there to a folder you choose, and delete the empty folder after that.







Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.