Summary: | amarok puts high load on mysqld when stopping playback | ||
---|---|---|---|
Product: | [Applications] amarok | Reporter: | Andreas Pakulat <apaku> |
Component: | general | Assignee: | Amarok Developers <amarok-bugs-dist> |
Status: | RESOLVED WORKSFORME | ||
Severity: | normal | CC: | andrewturner512+kdebugs, richlv |
Priority: | NOR | ||
Version: | 1.4.1 | ||
Target Milestone: | --- | ||
Platform: | Debian testing | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: | output from show index from statistics |
Description
Andreas Pakulat
2006-08-07 17:55:06 UTC
does this happen only when stopping playback ? do you see any additional slowdown upon starting amarok, moving around collection, song advancing etc ? which mysql version is this (judging by your debian report it probably is the same as client libs - 5.0.22 - but just to make sure) ? could you, please, post here output of echo "describe statistics" | mysql -u <amarok_user> -p<password> -h <dbhost> <amarok_database> this seems quite similar to problems i got with some field types that sort of should have been been updated, sort of should have not... I did not test collection moving (got only 1 which is too large to move around) but the load is also rather high upon starting amarok (something between 30 to 75% CPU time for mysqld), song advancing doesn't put any load on mysqld. Yes, it's mysqld 5.0.22-4. The describe output is: Field Type Null Key Default Extra url varchar(255) YES UNI NULL createdate int(11) YES NULL accessdate int(11) YES NULL percentage float YES MUL NULL playcounter int(11) YES MUL NULL rating int(11) YES MUL 0 Andreas ok, maybe you could try this... a disclaimer first. my knowledge of these things is veeery limited and it might cause loss of data and other problems. so make sure to back things up properly ;) dump your mysql database. look into the file, find a string : CREATE TABLE `statistics` ( in there, look for `url` value, which should have varchar. replace that line (the url one, not table creation one) with `url` varbinary(255) NOT NULL default '', (note the varbinary <-> varchar change) i'm not completely sure, but i believe this should import nicely back ;) now, import your db dump & try again. That's what I call an easy fix ;-) I used phpmyadmin, which would let me alter the type of the column directly. SQL code for this should be ALTER TABLE statistics CHANGE url VARBINARY(255) So there's no need for a dump. Do you know what query amarok executes that is so complex for varchar and easy for varbinary? Andreas Andreas, please can you say what version of Amarok you have. Also, can you please run: SHOW INDEX FROM statistics I'm using amarok 1.4.1 I'll create an attachment for the indexes. Andreas Created attachment 17306 [details]
output from show index from statistics
Well, the type of the statistics table URL column has been changed to VARBINARY for 1.4.2-beta1. Quite why you have such serious issues with VARCHAR, I really can't tell, given there are two indices on the URL column. Should be fixed with the field change. Test 1.4.3 or 1.4.4 and reopen if necessary. |