Bug 122028 - Corrupt index files after crash, all messages blank
Summary: Corrupt index files after crash, all messages blank
Status: RESOLVED UNMAINTAINED
Alias: None
Product: kmail
Classification: Applications
Component: index (show other bugs)
Version: 1.12.0
Platform: unspecified Linux
: VHI grave
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
: 128259 150853 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-02-15 14:41 UTC by Christian D.
Modified: 2015-04-13 08:36 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christian D. 2006-02-15 14:41:41 UTC
Version:           1.9.1 (using KDE 3.5.1, Kubuntu Package 4:3.5.1-0ubuntu5 dapper)
Compiler:          Target: i486-linux-gnu
OS:                Linux (i686) release 2.6.15-15-686

This happened to me at least five times and now i'm fed up and have to report this one :-)

When I do the steps described in http://bugs.kde.org/show_bug.cgi?id=122027 after killing the KMail process, KMail corrupts the index files of the active mail-folder. If you show the folders contents everything seems normal at first sight, but when you actually click on a mail to view it, its subject line gets changed to "No Subject" and the content is DESTROYED. After deleting the *ids* .index files you can view the folder again but all markings are LOST COMPLETELY.
Comment 1 Peter Paulsen 2006-02-15 15:36:43 UTC
I also had a kmail crash. But I didn't need to delete the files you specified. I just noticed all my marks like the red flag where gone.
Comment 2 Nicolas Goutte 2006-02-17 08:24:36 UTC
Raising severity to "grave" as there is loss of data.
Comment 3 Thiago Macieira 2006-02-19 18:26:31 UTC
Crashing is known to corrupt index files, yes.
Comment 4 Martin Koller 2006-10-28 22:40:54 UTC
If it's known, then we can confirm this bug.
Comment 5 Adrien Cordonnier 2006-12-09 19:25:45 UTC
It seems to be also the cause of Bug 50462 ("mail is permanently lost if disk is full"), see Comments #42 and #57.

Bug 50462 as more than 800 votes!
Comment 6 Philippe 2007-02-26 07:27:05 UTC
Seems to be e the cause of Bug 140660 too http://bugs.kde.org/show_bug.cgi?id=140660   ?
Comment 7 Thomas McGuire 2007-07-17 15:32:25 UTC
See also bug 121272.
Comment 8 Thomas McGuire 2007-07-17 15:34:16 UTC
*** Bug 128259 has been marked as a duplicate of this bug. ***
Comment 9 Thomas McGuire 2007-10-19 19:21:12 UTC
*** Bug 150853 has been marked as a duplicate of this bug. ***
Comment 10 Myriam Schweingruber 2009-08-01 21:14:10 UTC
Is there a chance to have this fixed one day?
I tried again today with version 1.12.0 (using kde 4.3 final), downloaded my mails (I luckily have them on a server), experienced like 5 crashes while filtering and have a corrupt index again. This makes kmail pretty much unusable to me, every single time I try to use this application it crashes multiple times and corrupts the mail index :(

Rebuilding an index from a backup is not doable, as I do backups only every night, having 5 crashes in a row and hundreds of lost mails really is not acceptable.

You should flag Kmail as highly unstable and warn people to use it, I have these index corruptions since 5 years, through all the versions, and it didn't get better by a yota.

As much as I love KDE, this is a serious drawback to the everyday use.

A bug marked as 'grave' should have a high priority for the developers, hence changing the priority.
Comment 11 Martin Steigerwald 2009-08-01 22:07:51 UTC
Hmmm, I didn't have crashes and index file data losses at all with KMail from KDE 4 yet. I once thought I had a problem with an index as I couldn't find a mail, but I just didn't account for the threaded view and it was there. What is a pity IMHO is that rebuilding the index discarded the flags. Actually I thought they were stored in the names of the mail files in MailDir format, but apparently this at least doesn't hold true for all flags or KMail doesn't account for those flags when rebuilding the index, which wouldn't make much sense for me. So I agree that index handling seems still be to fragile to me.

Anyway, I guess, we will have to wait for Akonadi. Does anyone know when it is planned to switch KMail to Akonadi storage? Maybe for KDE 4.4? Anyway even then Akonadi might have bugs that will have to be fixed, before it all becomes stable.

As far as I read there are not many KMail developers, so this is as with any other open-source project: Either fix it yourself, sponsor fixing it by throwing money at a capable KDE developer like Thomas McGuire or a team of them or just wait till its done. Of course sponsoring would only work when the developer(s) in question can take off their regular jobs for a while or when they work at a company which does paid development work on KDE.

That written I think adding moaning over moaning to each bug report that has been open longer, doesn't really help to get it fixed. As much as I understand that the situation is frustrating.
Comment 12 Martin Steigerwald 2009-08-02 11:32:03 UTC
There seems to be quite some work going on regarding mail related Akonadi resources (IMAP, POP3, Maildir).

The new IMAP4 IDOL, I mean IDLE
http://ervin.ipsquad.net/2009/07/31/the-new-imap4-idol-i-mean-idle/
Comment 13 Nathaniel Taylor 2010-03-16 10:40:34 UTC
I've noticed many times the problem of one or several emails being shown as 
empty.  I can't confirm it for KDE4, which I don't use, but it's been with us 
at least several years in KDE3.  

It sounds as though any fix will be by the change to a different underlying program, but I offer the following advice in case it saves time for Kmail users.

From my experience of the problem, nothing on the IMAP server is messed up, but only kmail's memory (index) of the content.  Using another mail client allows the messages to be read. Deleting Kmail's index files then restarting kmail removes the problem:  I have this --
rm -vf $HOME/.kde/share/apps/kmail/imap/.XXXXXXXXX.directory/.IN*
in a script that I run when the problem arises (of course, the number replaced with XXXXX... will have to be set to whatever your one is).

If the problem is different for local rather than IMAP storage, I'd at least suggest setting kmail to use separate files for storing the emails, rather than mailspool files: limit the extent of corruption!
Comment 14 Martin Steigerwald 2012-08-11 22:23:50 UTC
Is this still happening for KDEPIM 4.8.4 / 4.9 or even the 4.4.11 I still have on Debian? I haven´t seen this since ages?
Comment 15 Laurent Montel 2015-04-12 10:08:43 UTC
Thank you for taking the time to file a bug report.

KMail2 was released in 2011, and the entire code base went through significant changes. We are currently in the process of porting to Qt5 and KF5. It is unlikely that these bugs are still valid in KMail2.

We welcome you to try out KMail 2 with the KDE 4.14 release and give your feedback.
Comment 16 g.sora 2015-04-13 08:36:50 UTC
Hi Laurent,
Thank you for your work.
Well, Now I will monitor if this will appear on next versions.
Unfortunately for now I only can use, on my main machine, just KDE
4.11.5 (with the Kmail for this release) with OpenSuSE 13.1.
On my other machines I will try some more tests, but they are not used
in such a heavy testing mode.
By the way I am infighting  with another annoying bug, not impossible to
handle, but just tedious: from time to time, when I start reading my
mail, I got more and more duplicate messages.
Just annoying, I do not know if this could be useful to know.
I will keep you informed on how it will be going on,
Thank you
Best regards
Giovanni Sora
 
 
Il 12/04/2015 12:08, Laurent Montel ha scritto:
> https://bugs.kde.org/show_bug.cgi?id=122028
>
> Laurent Montel <montel@kde.org> changed:
>
>            What    |Removed                     |Added
> ----------------------------------------------------------------------------
>          Resolution|---                         |UNMAINTAINED
>              Status|CONFIRMED                   |RESOLVED
>
> --- Comment #15 from Laurent Montel <montel@kde.org> ---
> Thank you for taking the time to file a bug report.
>
> KMail2 was released in 2011, and the entire code base went through significant
> changes. We are currently in the process of porting to Qt5 and KF5. It is
> unlikely that these bugs are still valid in KMail2.
>
> We welcome you to try out KMail 2 with the KDE 4.14 release and give your
> feedback.
>