Monday, April 14, 2014

Roundcube DATABASE ERROR: CONNECTION FAILED

Solutions / Roundcube

DATABASE ERROR: CONNECTION FAILED

Make sure the MySQL password is right
root@server[~]$ grep db_dsnw /usr/local/cpanel/base/3rdparty/roundcube/config/db.inc.php
$rcmail_config['db_dsnw'] = 'mysql://roundcube:mUh8j6kv6_QFSMSA@localhost/roundcube';
The password in this case is set in the config as: "mUh8j6kv6_QFSMSA". See if the hash matches what is set for the user:
root@server[~]$ mysql
mysql> use mysql;
mysql> select PASSWORD('mUh8j6kv6_QFSMSA');
mysql> select * from user where User = 'roundcube';
mysql> update user set Password = PASSWORD('mUh8j6kv6_QFSMSA') where User = 'roundcube';
If the above did not fix it, try to update. Update RoundCube (the right way)
root@server[~]$ mysqldump roundcube > /path/to/backup.sql
root@server[~]$ /usr/local/cpanel/bin/update-roundcube --force
root@server[~]$ mysql roundcube < /path/to/backup.sql
If THAT didn't work, just download this Roundcube SQL backup and import it. Then the force update should run and fix everything. Please keep in mind that this will OVERWRITE the current database. You may be able to play with the backup you took in the previous step to re-import anything that is now missing.
root@server[~]$ wget http://howtofixservers.com/files/sql/roundcube.sql
root@server[~]$ mysql roundcube < roundcube.sql
root@server[~]$ /usr/local/cpanel/bin/update-roundcube --force

No comments:

Post a Comment