This forum has been archived. All content is frozen. Please use KDE Discuss instead.

MySQL and amarok 1.4.7

Tags: None
(comma "," separated)
User avatar
Dieter Schroeder
Registered Member
Posts
714
Karma
7
OS

MySQL and amarok 1.4.7

Sun Aug 19, 2007 9:07 pm
Hi there,
after a long time, I decided to change from sqlite to MySQL. BUT:
1. Problems inserting existing data into the db, if the key length > 1000 byte.
Could be solved by manual edit of the dump.
2. Unable to insert new songs, because album.id and artist.id aren't auto_increment. So every song gets the same artist and album. IDs are always 0. Changing tables?
3. No speed-up in updating the database. Only the contextbrowser now "only" needs 11 sec. to update his information.
4. Didn't resolve the problem of skipping songs after some seconds, especially under load.
Some infos:
amarok-1.4.7
MySQL 5.0.26
about 30.000 titles in about 2.500 albums
Sorry, that I must say that, but amarok isn't getting better with every version. 1.4.7 is really a bug release.
More and more features, but less fixing, I think.

Waiting for 2.0
Greetings
m0nk


If men could get pregnant, abortion would be a sacrament.
Boni
Registered Member
Posts
49
Karma
0

Re: MySQL and amarok 1.4.7

Tue Aug 21, 2007 5:36 pm
I had those "bugs", too. Especially the second point is really a bad one...
User avatar
eean
KDE Developer
Posts
1016
Karma
0
OS

Re: MySQL and amarok 1.4.7

Tue Aug 21, 2007 5:40 pm
There were actually 0 features in 1.4.7, only changes and bug fixes. I think its funny that we get accused of favoring features over bug fixes even when there aren't any features.

Switching from sqlite to MySQL is not a supported operation. It would be a feature to add support for it.


Amarok Developer
User avatar
dangle_wtf
Moderator
Posts
1252
Karma
0

Re: MySQL and amarok 1.4.7

Tue Aug 21, 2007 9:40 pm
Hm, sometimes mysql breaks between point versions - are there any other versions you can try, or can you confirm that others have amarok working with the same version? I can't check which version I'm using at the moment, sorry.

Also, have you tried a completely clean database build? I'm not sure that many people have successfully managed to manually convert their sqlite databases to mysql. Note also, there are scripts on the wiki to do this kind of stuff, but I'm not sure whether they're up to date.


"There are two theories to arguing with women. Neither one works."
.
If men could get pregnant, we'd learn the true meaning of "screaming nancyboy wuss"
User avatar
Dieter Schroeder
Registered Member
Posts
714
Karma
7
OS

Re: MySQL and amarok 1.4.7

Wed Aug 22, 2007 7:37 am
Hello again,
@Ian: I didn't mean the 1.4.7 version especially. What I meant was the general development of amarok covering the latest versions. Sorry for the misunderstanding.
Converting the db from sqlite was the only way to get it worked. The schema amarok builds, doesn't work because of the problems with the keys. If you have multiple keys, they get summarized. With a new db, amarok creates the tables, but doesn't insert any data. So this converted database worked for me (by decreasing the key length). But I'm still not able to add new entries. Shouldn't be the ids auto_increment?
Don't get me wrong, I really like amarok and his features ;-). I can handle that. But if we run into this "It's not a bug, it's a feature" philosophy of another well-known OS, hoping for the apathy of the users to accept that, we're not better, aren't we?

Greetings
m0nk


If men could get pregnant, abortion would be a sacrament.
User avatar
eean
KDE Developer
Posts
1016
Karma
0
OS

Re: MySQL and amarok 1.4.7

Wed Aug 22, 2007 3:22 pm
I really have no idea what you are doing. You should probably start from the beginning.


Amarok Developer
User avatar
dangle_wtf
Moderator
Posts
1252
Karma
0

Re: MySQL and amarok 1.4.7

Wed Aug 22, 2007 7:32 pm
If you can get some debug output on what is happening, that would be helpful...


"There are two theories to arguing with women. Neither one works."
.
If men could get pregnant, we'd learn the true meaning of "screaming nancyboy wuss"
User avatar
Dieter Schroeder
Registered Member
Posts
714
Karma
7
OS

Re: MySQL and amarok 1.4.7

Sat Sep 01, 2007 10:27 am
Today I've tried it once again.
Step by step for Ian:
>mysql -u root -p
mysql>create database amarok;
mysql>insert into user values('localhost','amarok','PASSWORD','Y','Y','Y','Y','Y','Y','Y','Y','Y','Y','N','N','N','N','N','Y','Y','Y'
,'Y','Y','N','N','N','Y','Y','N',"","","","","","","","");
4 Warnings
mysql>GRANT ALL ON amarok.* To amarok@localhost IDENTIFIED BY 'PASSWORD';
mysql>flush privileges;
mysql>select host,user,password,select_priv,insert_priv,update_priv,alter_priv from user where user='amarok';
Here I saw that alter_priv='N' so:
mysql>update user set alter_priv='Y' where user='amarok' and host='localhost';
mysql>flush privileges;
mysql>quit
>mysql -u amarok -p
mysql>use amarok;
mysql>quit;

Then I removed amarokrc and collection* from ~/.kde...
I started amarok and entered the login informations for mysql
OK.
Amarok created the tables for db amarok (Controlled directly through 'mysql')
The status bar indicated the collection scan, but no entries were made.
I've tried to insert data into table 'artist' as a test and it worked. (insert into artist values(1,'Testme');
I deleted the data from the table.
So where's the problem?
Amarok isn't usable with sqlite anymore (to much data).

I don't know any solution.

Greetings
m0nk


If men could get pregnant, abortion would be a sacrament.
User avatar
Dieter Schroeder
Registered Member
Posts
714
Karma
7
OS

Postgresql 8.1.5 too

Sat Sep 01, 2007 6:46 pm
And now something completely different:
I've tested PostgreSQL 8.1.5 afterwards.
The same as with MySQL. Relations have been created, but no INSERT!?!
And before you ask, the db user 'amarok' has all rights on all tables on db 'amarok'
I show you the output:
>psql -U amarok -h localhost -W amarok
amarok=>\z
            Access privileges for database "amarok"
Schema |        Name        |  Type  |    Access privileges
--------+--------------------+----------+-------------------------
public | admin              | table    | {amarok=arwdRxt/amarok}
public | album              | table    | {amarok=arwdRxt/amarok}
public | album_seq          | sequence | {amarok=arwdRxt/amarok}
public | amazon            | table    | {amarok=arwdRxt/amarok}
public | artist            | table    | {amarok=arwdRxt/amarok}
public | artist_seq        | sequence | {amarok=arwdRxt/amarok}
public | composer          | table    | {amarok=arwdRxt/amarok}
public | composer_seq      | sequence | {amarok=arwdRxt/amarok}
public | devices            | table    | {amarok=arwdRxt/amarok}
public | devices_seq        | sequence | {amarok=arwdRxt/amarok}
public | directories        | table    | {amarok=arwdRxt/amarok}
public | embed              | table    | {amarok=arwdRxt/amarok}
public | genre              | table    | {amarok=arwdRxt/amarok}
----snip----

After about 40% of scanning:
amarok=>select * from artist;
id | name
----+------
(0 rows)

amarok=>select * from admin;
              noption              | value
------------------------------------+-------
Database Version                  | 35
Database Stats Version            | 12
Database Persistent Tables Version | 19
Database Podcast Tables Version    | 2
Database AFT Version              | 2
Database Devices Version          | 1
(6 rows)

The same as in MySQL: 'admin' is the only table filled with data
collection_scan.log runs through the files, no error messages.
Mysterious, isn't it?
And sorry for the long posting.

Greetings
m0nk  :confused:


If men could get pregnant, abortion would be a sacrament.
User avatar
Dieter Schroeder
Registered Member
Posts
714
Karma
7
OS

Finally solved by PostgreSQL

Tue Sep 04, 2007 7:26 am
Hi,
after giving PostgreSQL a second try, it finally works. But I really don't know why :smilie:.

Greetings
m0nk


If men could get pregnant, abortion would be a sacrament.


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], kde-naveen, Sogou [Bot]