Bug 274402 - mysqld process use a lot of IO time to time
Summary: mysqld process use a lot of IO time to time
Status: RESOLVED FIXED
Alias: None
Product: Akonadi
Classification: Frameworks and Libraries
Component: server (show other bugs)
Version: 4.7
Platform: Gentoo Packages Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-29 06:22 UTC by jlj.babydragon
Modified: 2013-03-02 18:50 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 jlj.babydragon 2011-05-29 06:22:36 UTC
Version:           4.7 (using Devel) 
OS:                Linux

The mysqld process use by akonadi server use a lot of system IO from time to time.  The sql mysqld execute at that time is:
SELECT PartTable.id, PartTable.pimItemId, PartTable.name, PartTable.data, PartTable.datasize, PartTable.version, PartTable.external FROM PartTable INNER JOIN PimItemTable ON ( pimItemId = PimItemTable.id ) WHERE ( PimItemTable.collectionId = ? AND PimItemTable.atime < ? AND PartTable.data IS NOT NULL AND substr( PartTable.name, 1, 4 ) = ( ? ) AND PimItemTable.dirty = ? AND PartTable.name NOT IN ( ?, ? ) )

When this sql is executing, the disk read will be 10MB/s to 30MB/s.
I'm not sure if this is caused by kdepim2.
The version of akonadi-server is 1.5.80, and the kdepim2 is cloned from kdepim-4.6 branch.

Reproducible: Always

Steps to Reproduce:
start akonadi-server

Actual Results:  
mysqld process always read disk

Expected Results:  
reduce system IO
Comment 1 jlj.babydragon 2011-07-04 01:39:35 UTC
Hi:
I update kdepim to 4.6.90, this problem still occur. I tried to enlarge innodb_buffer_pool_size to 800M, mysqld process still use a lot of IO time.
I use the sql in the comment of innodb_buffer_pool_size property, I think the result is a bit large:
SELECT sum(data_length) as bla, sum(index_length) as blub FROM information_schema.tables WHERE table_schema not in ("mysql", "information_schema");
bla            blub
5.68189e+09   2.76726e+07
Comment 2 Blindauer Emmanuel 2012-03-09 07:07:41 UTC
I confirm the problem with 4.8.1

These excessice I/O eat much of the laptop battery :/
Comment 3 Ingo Stierand 2012-03-15 13:16:47 UTC
@jlj, how do you figured out what command mysgl is executing?
I faced the same problem and dropped a bug (#295529) and would like to figure out
whether this is the same issue.
Comment 4 jlj.babydragon 2012-03-15 13:24:22 UTC
Mysql has a command, you can use:
show processlist;
or
select * from information_schema.PROCESSLIST;
to find active sql.

I have changed the hard driver of my laptop to SSD, so I it's OK now. But I still hope this issue could be fixed.
(In reply to comment #3)
> @jlj, how do you figured out what command mysgl is executing?
> I faced the same problem and dropped a bug (#295529) and would like to
> figure out
> whether this is the same issue.
Comment 5 Ingo Stierand 2012-03-15 13:39:19 UTC
Hello jlj.babydragon@gmail.com,

thanks, I try it as soon as I figured out which the correct db is.


> https://bugs.kde.org/show_bug.cgi?id=274402
> 
> --- Comment #4 from jlj.babydragon@gmail.com ---
> Mysql has a command, you can use:
> show processlist;
> or
> select * from information_schema.PROCESSLIST;
> to find active sql.
> 
> I have changed the hard driver of my laptop to SSD, so I it's OK now. But I
> still hope this issue could be fixed.
> (In reply to comment #3)
> 
> > @jlj, how do you figured out what command mysgl is executing?
> > I faced the same problem and dropped a bug (#295529) and would like to
> > figure out
> > whether this is the same issue.
Comment 6 Ingo Stierand 2012-03-15 13:57:19 UTC
While not finding the correct hook for checking mysql execution I found that
the KDE factory repository for my suse has provided an update of the 
akonadi_runtime package to 1.7.1. This update fixes the CPU issue for me.
Comment 7 Ingo Stierand 2012-05-15 07:21:01 UTC
In KDE 4.8.3 the issue is gone here.
Comment 8 Christophe Marin 2012-05-18 21:10:46 UTC
(In reply to comment #6)
> While not finding the correct hook for checking mysql execution I found that
> the KDE factory repository for my suse has provided an update of the 
> akonadi_runtime package to 1.7.1. This update fixes the CPU issue for me.

Thanks for the feedback.
Comment 9 Daniel Vrátil 2013-03-02 18:50:21 UTC
As reported, the issue is gone in recent releases, so closing as fixed.