KMail problems

Duncan 1i5t5.duncan at
Tue Feb 9 02:09:10 GMT 2010

Frank Weng \(a.k.a. Franklin\) posted on Tue, 09 Feb 2010 07:18:28 +0800
as excerpted:

> Actually I have been had these problems from KDE 4.1.  I'd like to know
> if anyone had the same experiences.
> 1. When logging into KDE, the kde-wallet would launch a dialog asking my
> question to open a wallet.  At the same time, many other KDE/non-KDE
> applications are launching too.  If I input my password BEFORE KMail
> launch, then KMail will NEVER launch automatically.  I need to launch it
> myself.  If I WAIT there, KMail will launch automatically, and then I
> input my password and everything goes normally.
> I can reproduce it on the PCs in my office and my home.  Do you guys
> have the same problem?  Or did anyone discuss it before?  I did some
> simple search in kde-user but didn't find anything.

I have seen a couple mentions of this on the lists, here or the kde-linux 
list, but haven't seemed to have the issue here.  I don't know why, except 
possibly that I'm running a considerably beefier system than most will be 
running (total 4-cores CPU, 6 gig RAM, 4-disk md/kernel RAID-1), and/or 
because I have another app (pan, a news client) that does a LOT of I/O at 
start, and I start it with KDE also.

I can say that kmail is going thru a SERIOUS rewrite, using akonadi as its 
backend instead of the current basically independent solution, with that 
work scheduled to hit in 4.5, August.  Thus, there's very few changes of 
any size going into kmail itself right now, as kmail as we know it will 
soon disappear, to be replaced with a MUCH smaller code-wise front-end to 
the shared-code akonadi back-end.  So unless it's a "trivial" fix, don't 
expect to see it in the 4.4.0 just coming out or any of the 4.4.* updates 
over the next six months.  Beyond that, all bets concerning kmail are off 
as it'll really not be the same application it is now, at all.  Hopefully, 
tho, the UI doesn't stray too far from current, as I really like kmail. 

> 2. Recently, maybe just one or two days ago, when KMail started, it
> would do a lot of hard drive I/Os.  The whole system was slowed down.  I
> used top to see which process was doing hard drive I/O, and no doubt it
> was KMail.  KMail took nearly 50% of CPU time.  Its process status was
> mostly D.  My hard drive access LED flashed very frequently.  After
> about seven or eight minutes (or longer), it then stopped, and
> everything is okay.
> Does anyone know what KMail is doing when it starts?  I tried to stop
> receiving mail but hard drive accesses were still going.

Very likely, it's cleaning up and compacting old files.  This is 
especially true if you have mostly mbox based mail files (each kmail 
folder as a single mbox file) as opposed to maildir (each message as its 
own file, but kmail still keeps indexes that will need updated from time 
to time).

The following is kind of hard to describe but here's my try at it...

If you have particular folders with many existing messages that also have 
lots of new messages coming in, some deleted, some saved, this will tend 
to cause kde to need to compact those folder more often.  This type of 
pattern would be common for those who don't use filters to automatically 
sort stuff into directories as it comes in, as I do, but who rather tend 
to accumulate everything in one big inbox, deleting spam, etc, but saving 
valid messages.  Such a pattern, especially on mbox, will lead to "holey" 
files, files with many gaps where messages have been deleted.  Maildir 
will be better since the messages themselves are one to a file, but the 
index files will still get "holey" and need compacted.

Another use case that would trigger it would be if you had a bunch of 
generally unsorted messages in a folder, then moved say 10% or a quarter 
of them out, to their own folder, as might happen if you decided to sort 
your mail differently and moved everything from, perhaps, one author, or 
all work related messages, out to its own folder.  

By contrast, my usage tends to be very close to append-only.  That is, 
most of the messages I actually value are sorted by various kmail filters 
into their own folders as they come in.  There they stay, and I have mail 
dating back many years on some of these folders, as I don't normally 
delete mail of that sort at all.  What's left is mostly spam, some of 
which gets sorted to the trash automatically by my filters, so all I have 
to do is empty trash, with the rest going to "maybe spam" folders, 
generally one per email address (of which I have several).  But the "maybe 
spam" folders are kept empty or close to it, as I manually sort messages I 
want to keep into their appropriate folders, creating new filters to help 
the autosort if I get more than a few on a subject or from a particular 
person, deleting the spam, so there's nothing left in the "maybe spam" 
folders when I'm done.  Thus, they compact very fast since they're empty, 
and the folders that tend to accumulate mail seldom have any deletions, so 
seldom need compacted at all.

Duncan - List replies preferred.   No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master."  Richard Stallman

This message is from the kde mailing list.
Account management:
More info:

More information about the kde mailing list