Kmail extremely slow

For years I have used Kmail without problems. I load the emails down on my file server and open them from there - this way I can check my mails from any computer in the network. It has worked without until today. I have upgraded to 13.1 (i586) KDE desktop approx. 3 weeks ago and Kmail still worked afterwards. However now, when I try to open the mail or delete mail it takes ages more than 30 minutes and Kmail is just sitting there. At the bottom right the green slider is going left and right as if indicating the programme is doing anything but nothing happens. A right click for mark message as read does not work either. However I can move the files into different folder and I can open other files from the server (no email) so the connection is not the problem. I just try to open a 3 line text email and it was 17 minutes until it opened. Any ideas how this can be solved - otherwise my email system is useless.

Just a few additional information - the command top gave:

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND                                              
 1756 uli           20   0  586256 171584   4824 S  35.16   8.6124     0:59.90 mysqld                                               
 4286 uli           20   0  288468 112080  46888 S  33.17   5.625    25:04.47 kmail                                                
 1740 uli           20   0  279384  16460   6948  S  21.56   0.826    25:25.22 akonadiserver                                        
  685 root         20   0  119520  63788  44352  S   3.317   3.202     4:14.49 Xorg                                                 
 1589 uli           20   0  527804 103464  32848 S   2.654  5.193     2:51.69 skype                                                
 1466 uli           20   0  328892  55180  27832 S    1.990  2.770     2:22.83 kwin                                                 
 7273 uli           20   0  166016  27284  19168 S    0.995  1.369     0:00.91 konsole                                              
 7300 uli           20   0    4916   1448   1032    R    0.332  0.073     0:00.08 top                                                  
    1 root           20   0    6096   3272   2140    S    0.000  0.164     0:00.87 systemd   

So 90% of the CPU time was mysql, kmail and akonadiserver

On 2013-12-16 00:06, fuerstu wrote:
> For years I have used Kmail without problems. I load the emails down on
> my file server and open them from there - this way I can check my mails
> from any computer in the network.

It is more efficient to set up an imap server (dovecot) and store emails
there than using a file server. Then you point any mail client you use
(or several of them) to the server and off you go. If one day you don’t
want to use kmail, just start thunderbird instead. Another day
outlook… Whatever.

Cheers / Saludos,

Carlos E. R.
(from 12.3 x86_64 “Dartmouth” at Telcontar)

Thanks, robin_listas, but that does not help me at the moment. I need the akonadi server since it tells kmail where the resources are stored but it seems that kmail does not work. I cannot ask kmail to open the emails and come back several hours later to check what is written since it takes so long to open the emails. I will have a look at dovecot (any links will be appreciated) but I need to get kmail working now.

It could be this bug.
Are you willing to try a patched package?

Yes this looks at least similar to this bug but I don’t know how to apply the patch which is listed there as text file. Is there a patched version (.rpm) available?

Yes, in KDE:Release:411. Can you test that? Note that ideally, you should switch completely to that repo, as you’ll have multiple dependency issues otherwise.

Ok, building now only kdepim4 in a separate repo, will post address once it’s done.

Thanks, sumski, I presume when you say switch completely that means all KDE applications or only all of kmail?

I mean all packages available in the repo. Which is, for KR411 repo, whole SC release. As said in last post, i’m now building kdepim4 in separate repo. The same is valid, that you should switch completely to that repo, but it will contain only a few packages.
Address is

To summarize:
Just add the repo in this post, and switch all packages to it. Forgot anything i said about KDE:Release:411 repo =)

When I use this URL and go to Yast View -> Repositories to switch I don’t see any packages - although if I go direct to your URL and click on i586 I see the package group. What am I doing wrong?

Try to refresh the repos now, the i586 packages where published later than x86_64 ones.

OK - I probably was too impatient - now all is updated but it does not seem to have solved anything - I opened kmail and refreshed the folders but it sits there and does not open the mail. I will restart and see what happens then. Cheers
OK - after the restart and folder updating it seems to work now again - thank you very much sumski

That’s great to hear =)
I’ll submit the fix to 13.1 update, hopefully it will catch the ‘4.11.4 update’ train.

That’s great, @sumski. I was hit by the bug at a customer’s, where all was still on 12.1. We tested 13.1 on a couple of machines (they preferred that over 12.3), all was well for a week, then the bug hit some of their workers. I remove ~/.local/share/akonadi and everything rebuilt fine (i.e. mail settings needed some adjustments, but they were glad all was still there and back to usable).

Just a follow up - fix will be contained in the 4.11.4 update stack =)

Cheers, and congrats

Many thanks from me, too. That solved my kmail-problems in OSS 13.1.


I am using kmail on KDE 4.12.0, I moved from 4.11 to 4.12 because just about everything seemed broken when I upgraded to 13.1. The whole Akonadi system failed to start for numerous reasons. I was going to just go back to 12.3 and wait for 13.1 to become more stable but before doing so I installed KDE 4.12 and switched my system packages to those repositories. Most of my issues were solved in the switch. Kmail and Korganizer worked again, but the problem I am finding is that I cannot move any more than 4 emails at a time or I have to restart akonadi. My guess is it is related to this bug: Considering it is the holiday season, I don’t expect that there will be any fixes anytime soon.

I literally have to reset Akonadi about once an hour of regular use. II have wiped the and started fresh numerous times the akonadi database so there is no reason for issues there. It does seem as though it is the imap akonadi resource that is taking down Akonadi but once it hangs all Akonadi resources seize up. I opened the Akonadi console to see if I could get any errors out of it but it thinks everything is working properly… I really don’t know where the error is in this system but it works sometimes. I just hope that it will get fixed soon. I have become spoiled over the years of everything just working properly.