Or software bestiality
Amarok - in my opinion - the most ingenious of all existing audio players, is equipped with a no less brilliant music library.
(It was the transition to Linux and Amarok that taught me to use this instrument of music organization, Winamp and wine-media player libari just scared with their incomprehensibility and absurdity.) As you know, this entire music library is spinning on a specific database. In the standard configuration, this is SqlLite. Such a wonderful lightweight
database that does not require
user passwords or
any settings, just turned it on and it works for itself. But, she has one serious drawback: she is slow,
no, no , not the right word, just a brake!
SqlLite is suitable for a music library of ten gigabytes, twenty, well, with a stretch of fifty gig. But forcing it to control a greater number of records is mutual understanding for both the user and the
database itself. About 150 gig of music is stored on my home machine, with a middle-aged but not the oldest Pentium4 2.4GHz, the initial creation of the library takes quite a long but excusable time, but the search is already scary. Each time the player’s window turns gray (yes, yes, compis) for ten seconds, and the processor grunt for one hundred percent. Yes, and other operations with the
database are carried out quite slowly and resource-intensive. It was necessary to do
something with it.
I, as I think most of the people involved in
web development MySQL is already on duty. If not, installing it is not a problem. So why not give her control over her music library? As practice shows, everything works ten times faster.
So, then I will describe the configuration of the database and the player, in general, there is nothing complicated, and you can easily figure it out.
Most likely, the majority of reading ubunto /
cubunto-water , but I do not belong to them, so I will try to describe in general terms what packages we need.
First of all, it is the database itself:
you drive into the search for your favorite package manager the word
mysql , and intuitively poke ticks in front of what you need :)
And most likely you need:
mysql-server (the rest should be pulled along as dependencies)
mysql-common (if the dependencies server is not pulled)
mysql-client (generally for the same reason)
mysql-admin (if of course you can’t manage databases, manually enter
Sql requests . Although, if you can, then why are you reading this manual at all?)
amarok (
God knows, what if you were going to customize the player without installing it?)
So, installing the necessary packages, proceed to the configuration.
For advanced, you can optionally twist the file /etc/my.cnf. But, as practice shows, this is not at all necessary.
First you need to run our database. To do this, you must either reboot or write in the console:
# / etc / init.d / mysqld start')
In any case, the next time you start the database will start itself.
Next, let's set up the tables and users. I think it will be more convenient for some to do this using phpMyAdmin, or manually using queries, but for me the most familiar and simplest tool is
mysql-administrator . We run it.
$ mysql-administratorWe are greeted by the authorization window in the database:

We do everything so that it was like in the picture. In the standard configuration, it should be set up as root and without a password. If not, try the administrator password on your computer, if
it does n't exist anyway, use the pad /etc/my.cnf, or write here, we'll figure it out.
If everything is good, then we should meet such a window:

Go to the tab «Catalogs». We click with the right key in the Schemata field, select “Create Schema”.

We set the name of the new table, in our case - amarok.
Next - go to User Administration.

We select the root user and set a password for it (it has no relation to the manual, but it is still so much safer) Do not forget that the next time you connect to the
mysql-administrator you will need to enter the set password.
Then we add the user amarok (the big such button at the bottom is “new user”). If desired, set a password for it.
Having selected a user, go to the tab (at the top, not at the side) of the “Schema Privileges”:

There, in the left column, select the amarok scheme that we create, in the right column, press ctrl + a and use the arrow to move all privileges to the central column (no, well, of course, you can manually select privileges for the user, but in my opinion, this is unnecessary).
With the configuration of the base is over, we exit the administrator.
It now remains to configure Amarok.
I will not dwell on how to use the library, and which folders you will scan.
Go to the settings in the "database", select MySQL. In the name of the site, or whatever, you register localhost. The database and user - those that you created, in our case - write amarok everywhere.

Voila! The player will re-create the music library (do not be afraid for the covers downloaded from the Internet, they will remain :)), it will take quite a bit of time. And now you can rejoice! The search for tracks in the database is much faster and more pleasant. Like working with dynamic playlists.
If, God forbid, there will be problems with tracks containing Cyrillic in the names (this happened to me at OpenSuse), try to enter “
default-character-set = utf8” in /etc/my.cnf in the [mysql] section.