Bug 303511

Summary: Amarok takes around 6 minutes to load if no other processes are using the CPU.
Product: [Applications] amarok Reporter: Rob D <Robert.M.Davies>
Component: Collections/LocalAssignee: Amarok Developers <amarok-bugs-dist>
Status: RESOLVED WORKSFORME    
Severity: major CC: ralf-engels
Priority: NOR    
Version: 2.5.0   
Target Milestone: 2.6   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Rob D 2012-07-14 02:14:28 UTC
When I use the latest version from the oneiric kubuntu backports ppa (2:2.5.0-0ubuntu4~oneiric~ppa1), amarok takes 5m54s to start up from running the executable to a responsive UI with an empty playlist.
Note the following lines of output, picked from the output when run with --debug:
amarok: END__: Playlists::PlaylistFilePtr Playlists::loadPlaylistFile(const KUrl&) [DELAY Took (quite long) 1.1e+02s]
marok: END__: Playlists::PlaylistFilePtr Playlists::loadPlaylistFile(const KUrl&) [DELAY Took (quite long) 94s]
amarok: END__: Playlists::PlaylistFilePtr Playlists::loadPlaylistFile(const KUrl&) [DELAY Took (quite long) 11s]
amarok: END__: Playlists::PlaylistFilePtr Playlists::loadPlaylistFile(const KUrl&) [DELAY Took (quite long) 24s]
amarok: END__: Playlists::PlaylistFilePtr Playlists::loadPlaylistFile(const KUrl&) [DELAY Took (quite long) 30s]

If I revert to the version from the standard repository (2:2.4.3-1ubuntu2.1), it takes 15s to present a usable UI (this includes spinning up a CD and reading from it).

Remove the CD and load again: 5s load time.

Enable the backports ppa and update to 2.5 again: it takes 6m12s to reach a responsive UI.

This is obviously unacceptably long. I've marked as major because I consider starting in less than 5 minutes on a relatively new computer (built about 15 months ago) a major feature I would expect to work.
I imagine it is doing some sort of scan on my collection (and have classified the bug under 'collection' accordingly), but this shouldn't make the UI unusable!

I'd be happy to provide as much information as I can, when I am at my computer.

Reproducible: Always




I have searched through past bugs, and while the list was very (very) long, have made some reasonable effort to find similar bugs using sensible search terms.

I am running AMD, 3 cores at 3.2Ghz each.
4GB RAM
1TB HDD (no SSD)
I have ~25,000 songs in my collection.
Comment 1 Myriam Schweingruber 2012-07-16 22:22:42 UTC
Please erase your amarok configuration files located in $HOME/.kde/share/config/ and try again, this is most likely a problem with old configuration files lying around. Also it apparently tries to load a rather big playlist.
Comment 2 Rob D 2012-07-17 14:42:03 UTC
I took a look through the amarokrc file and discovered 330 entries in the [Loaded Playlist Files] section.

I deleted these lines and amarok started reasonably fast again.

I wonder if these playlists will be added again...
I will post back here soon.
Comment 3 Rob D 2012-07-20 16:19:12 UTC
OK, So Amarok now starts normally, and upon re-adding all the correct folders to the media library, my playlist have been added to the media sources without noticeably affecting startup time.

This is all good.

O would mark the bug solved, but it might perhaps be worth ignoring the offending section in the config file if it's not necessary, or is it still used somewhere?

Rob
Comment 4 Myriam Schweingruber 2012-07-25 03:10:28 UTC
Thank you for the feedback. Previous versions of amarok added playlist information that could cause such problems, especially if some files were not directly accessible. It is in general saved to erase the amarokrc file though and this should then not happen again if you use no older version than 2.5