Where are the amarok MySQL database stored? is restoring an old database as simple as copying a file from my old installation? Do I have to type anything in the konsole to initiate it properly?
Announcement
Collapse
No announcement yet.
Where are the amarok MySQL database stored?
Collapse
This topic is closed.
X
X
-
Re: Where are the amarok MySQL database stored?
The MySQL database would be stored on whatever MySQL server you've set it up with... if you've set amarok to use it, that is.
The SQLite database, if that is what you have chosen (or it may be the default, I forget) is stored in ~/.kde/share/apps/amarok/collection.db along with your playlists and other data... it should be relatively straightforward to copy things across to a new install.
- Top
- Bottom
-
Re: Where are the amarok MySQL database stored?
Originally posted by JamesMThe MySQL database would be stored on whatever MySQL server you've set it up with... if you've set amarok to use it, that is.
- Top
- Bottom
Comment
-
Re: Where are the amarok MySQL database stored?
MySQL is a database server; you generally don't interact with its storage files. You interact with it by using an SQL client.
If you're looking to copy a database between MySQL servers, then you'll want to do something like
On the old machine: mysqldump -u amarok -ppassword databasename > amarok.sql
Copy the file amarok.sql to the new machine
On the new machine: mysql -u something -psomethingelse < amarok.sql
You'll have to replace the bits in italic to whatever your configuration is.
- Top
- Bottom
Comment
-
Re: Where are the amarok MySQL database stored?
The actual data is stored in /var/lib/mysql
However you will really need to import the data after exporting it from the old database. If you are not used to CLI manipulation of mysql (I know I am not for it is a dark and evil art practiced only by gnarly wizened BOFHs) a mysql front end to connect to the server is the answer. Many good ones exist, but the easiest IMHO is phpmyadmin or you you could use the mysql-admin package which is a rather nice gtk frontend.
The table you want is called statistics in the amarok database.
- Top
- Bottom
Comment
-
Re: Where are the amarok MySQL database stored?
Originally posted by stealthbananaThe actual data is stored in /var/lib/mysql. However you will really need to import the data after exporting it from the old database... The table you want is called statistics in the amarok database.Originally posted by JamesMMySQL is a database server; you generally don't interact with its storage files. You interact with it by using an SQL client.
Can I still make a dump if that linux installation is stuffed? Maybe through recovery using the installation cd? except that logs in as root instead of my user?
- Top
- Bottom
Comment
-
Re: Where are the amarok MySQL database stored?
Originally posted by stealthbananaIf you have the raw files, you should just be able to drop them in to or copy the entirety to /var/lib/mysql/amarok on the new machine.
and hey thanks for checking on this thread. I really appreciate your help. I have this thread favourited just incase you or JamesM have any updates.
- Top
- Bottom
Comment
-
Re: Where are the amarok MySQL database stored?
YUS I figured it out!.
Thanks Stealthbanana and JamesM
1. I copied the '/var/lib/mysql ' to my new computer
2. I followed the instructions from the MySQL HowTo (which is what i did on my old computer)
a. sudo apt-get install mysql-server (chose PASSWORD_CHANGE_ME when asked)
b. mysql -p -u root
CREATE DATABASE amarok;
USE amarok;
GRANT ALL ON amarok.* TO amarok@localhost IDENTIFIED BY 'PASSWORD_CHANGE_ME';
FLUSH PRIVILEGES;
c. load amarok. (already had mysql collection settings: host"localhost" Database"amarok" Username"amarok" Password"PASSWORD_CHANGE_ME"
Also I think this solution may be dependent on having the songs stored in the same location as the original database? Wasn't a problem for me coz it was actually the same computer, not a new one.
Anyway. That is the end of my frustration. I'd actually abandoned linux because of losing my amarok stuff, but now I have a reason to use it again!
- Top
- Bottom
Comment
Comment