#1 (permalink)  
Old 07-01-2009, 01:11 AM
Registered User
 
Join Date: May 2003
Posts: 20
kamnet
Roundcube cannot connect to database. Help please?

Client reported this evening that they get the following error trying to log into roundcube:

DATABASE ERROR: CONNECTION FAILED!

I honestly have NO CLUE where to start debugging this, I'm not finding any errors, I'm stressed I'm tired I could use an extra hand trying to resolve this from the beginning. Anybody care to guide me? Hold my hand? Tell me it's going to be alright? :-)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 07-01-2009, 05:58 AM
Infopro's Avatar
Forum Moderator
 
Join Date: May 2003
Location: Pennsylvania
Posts: 3,498
Infopro is on a distinguished road
Lightbulb

It'll be alright. No hand holding though...

Is MySQL up?

This thread may be related but out of date.
horder and roundcube can't connect to database error
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 07-01-2009, 07:18 AM
Registered User
 
Join Date: Jun 2007
Posts: 135
logicsupport is on a distinguished road
How to fix roundcube database error

Please try the following procedure.
=====

create database roundcube;
exit;

Then do the procedure:

mysql-u root-D roundcube-p </usr/local/cpanel/base/3rdparty/roundcube/SQL/mysql.initial.sql

After that, look for the file:

vi /usr/local/cpanel/base/3rdparty/roundcube/config/db.inc.php
In line similar to the database -> mysql://roundcube:SENHADOROUNDCUBE@localhost/roundcube

replace by:

mysql://root:SENHADEROOT@localhost/roundcube


Now try your webmail using roundcube


Also ,

* Check if db.inc.php and main.inc.php contains the correct entries such as username , password and database name
* Running the command /usr/local/cpanel/bin/update-roundcube --force will also help
* go to phpmyadmin and repair all round cube tables
* Also check and reset the mysql root password in whm just to make sure it is set .
*Last but not the least try /scripts/upcp --force


Make a copy of roundcube database under /var/lib/mysql before trying any of the above methods
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 07-01-2009, 12:58 PM
Registered User
 
Join Date: May 2003
Posts: 20
kamnet
OK, I did all of the above. User can log into RoundCube again, but two complaints:

1) Inbox is almost a week and a half behind
2) Cannot send new messages, it hangs with a message of "Sending message"
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 07-01-2009, 01:16 PM
Registered User
 
Join Date: Jul 2005
Location: New Jersey, USA
Posts: 385
PlatinumServerM is on a distinguished road
These are known common problems with roundcube. If all else fails, try updating cpanel and updating roundcube too.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6 (permalink)  
Old 07-02-2009, 12:56 AM
Registered User
 
Join Date: Jun 2007
Posts: 135
logicsupport is on a distinguished road
Hello kamnet ,

Check if you can get any errors from the logs .

Common fixes recommended are :-

1 ) vi /usr/local/cpanel/base/3rdparty/roundcube/config/main.inc.php

and change

$rcmail_config['smtp_user'] = '%u';
to
$rcmail_config['smtp_user'] = '';

2) If you are using csf , check csf configuration file for the entry

SMTP_BLOCK = "1"
SMTP_ALLOWLOCAL = "1"

If the value is 0 change it to 1 and restart csf

3) update cPanel ( /scripts/upcp --force ) to latest "STABLE" version.

4) increase the memory_limit in php.ini under /usr/local/cpanel/base/3rdpart/roundcube/

Try any of the above methods
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7 (permalink)  
Old 07-02-2009, 12:59 AM
Registered User
 
Join Date: May 2003
Posts: 20
kamnet
I forced an update of cpanel from the command line (suggested a few posts ago) and that helped to fix part of the problems but not all of them. After I logged back into WHM I was greeted with a new license screen for RoundCube, after I cleared that I tried doing a cPanel update from within WHM, and that appears to have cleared everything up.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #8 (permalink)  
Old 07-03-2009, 09:56 AM
Registered User
 
Join Date: Jan 2004
Posts: 664
Lyttek is on a distinguished road
Quote:
Originally Posted by logicsupport View Post
Make a copy of roundcube database under /var/lib/mysql before trying any of the above methods

Umm... shouldn't that be the *first* item of text rather than the last
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Database Error: Unable to connect to the database:Could not connect to MySQL bleustreak1 cPanel Newbies 4 03-05-2009 03:14 PM
11.24 Upgrade: Roundcube Database Connect Error RickG cPanel and WHM Discussions 6 12-31-2008 08:22 AM
horder and roundcube can't connect to database error dxm Mail 7 09-12-2008 06:25 AM
Roundcube Database Error Issue kamnet cPanel and WHM Discussions 3 07-26-2008 09:22 AM
Could not connect to database hoster22 cPanel and WHM Discussions 1 12-22-2004 10:33 AM


All times are GMT -5. The time now is 10:36 AM.


Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
© cPanel Inc