[Pkg-roundcube-maintainers] Bug#720955: roundcube-core: fails to upgrade MySQL database (0.7.2-9 -> 0.9.2-2)

Matteo Checcucci matteo.checcucci at arnone.de.unifi.it
Tue Sep 3 10:19:01 UTC 2013


Hello Vincent,
thanks for your followup.


On 08/31/2013 02:10 PM, Vincent Bernat wrote:
> What is the history of your installation?

It was installed a while ago, probably before version 0.7.2-9

> Maybe the installation failed with another error and then you retried
> and you got this error.

If I recall correctly, the first attempt failed for a wrong password.
But I think that no change was applied to the database then.

After that, it seems that it migrated the database, but failed with the 
reported error.

By looking at the dbc.log, it almost seems that the migration was 
performed twice:


creating database backup in 
/var/cache/dbconfig-common/backups/roundcube_0.7.2-9.mysql.
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using 
password: YES).
unable to connect to mysql server.
creating database backup in 
/var/cache/dbconfig-common/backups/roundcube_0.7.2-9.mysql.
applying upgrade sql for 0.7.2-9 -> 0.9.1-1.
applying upgrade sql for 0.7.2-9 -> 0.9.1-1.
creating database backup in 
/var/cache/dbconfig-common/backups/roundcube_0.7.2-9.mysql.
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using 
password: YES).
unable to connect to mysql server.
creating database backup in 
/var/cache/dbconfig-common/backups/roundcube_0.7.2-9.mysql.
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using 
password: YES).
unable to connect to mysql server.
creating database backup in 
/var/cache/dbconfig-common/backups/roundcube_0.7.2-9.mysql.
applying upgrade sql for 0.7.2-9 -> 0.9.1-1.
creating database backup in 
/var/cache/dbconfig-common/backups/roundcube_0.7.2-9.mysql.
applying upgrade sql for 0.7.2-9 -> 0.9.1-1.
creating database backup in 
/var/cache/dbconfig-common/backups/roundcube_0.7.2-9.mysql.
applying upgrade sql for 0.7.2-9 -> 0.9.1-1.


>   Unfortunately, when there is an error during
> upgrade, there is no rollback done.

This is really unfortunate.

>   You need to recover from backup or
> handle things yourself by applying upgrades by hand. They are in
> /usr/share/dbconfig-common/data/roundcube/upgrade/mysql.

I did the following: I re-upgraded to version 0.9.2-2, and re-adapted 
the configuration files.
But the database migration was not performed again.
I do not understand why.

After that, roundcube was working, but failed to connect to its database.

By trying to do the database migration manually (one SQL command at a 
time), I found that
all changes had already been applied...
Maybe this is why the automatic migration was not attempted?

The only thing I had to fix was reconfiguring the -core package
(dpkg-reconfigure roundcube-core) and re-entering the roundcube MySQL 
database
password into /etc/roundcube/debian-db.php
I don't know why the password had been discarded.

After all this, roundcube works again.

Thanks for your help.
I hope the information I provided may help improving the package further.

Bye.


Dr. Matteo Checcucci
Mechanical Engineer

Dept. of Industrial Engineering
Via S. Marta, 3 Firenze, Italy 50139
http://arnone.de.unifi.it/tgroup
matteo.checcucci at arnone.de.unifi.it



More information about the Pkg-roundcube-maintainers mailing list