[Dclug] sqlite vs Mysql (for embedded app use like Amarok 1.4)
maxpublic08 at maxwellspangler.com
Mon Mar 16 21:40:27 EDT 2009
I've been happily using Amarok 1.4 on Fedora for some time to manage a
rather large amount of mp3 and podcast files.
This weekend in concert with an upgrade from Fedora 9 to Fedora 10 I
decided to change the backend that Amarok uses to track information from
the default sqlite database to MySQL.
The performance increase is AMAZING.
I had thought sqlite would handle rather simple conditions like a list
of mp3 files quickly but for whatever reason, MySQL is magnitudes
faster. I notice this when going to the Collection tab and entering a
search phrase. What used to take many seconds to slowly resolve now
comes in at .5 to 1 seconds which is quite comfortable.
Setting it up wasn't very hard and basically consists of:
1) MySQL installed and running
2) Logging into mysql and making an amarok database, user and allowing
privileges to that user.
3) Changing the 3-4 settings in Amarok to tell it to use MySQL.
4) Rebuilding my mp3 collection
And then this part which really didn't go that well:
5) Re-entering all my podcast subscriptions and syncing up files again.
I didn't lose previously saved data, but Amarok lost its awareness of
the 20 gigabytes of podcast archives I had already on disk.
I'd hope that in the future Amarok will gain a simple backup/import
feature like Evolution. With Evolution's backup I can backup all my
settings and data with one activity to one single file and easily reload
it. For people like me who are regular users of Amarok, that'd be a
very useful feature to have.
Anyway, I hope this helps anyone interested. There are many
applications using sqlite as a default low-overhead database. From now
on I'm going to keep an eye on them and consider using MySQL instead.
Research Triangle Park, NC, USA
More information about the Dclug