forum.coppermine-gallery.net

Support => cpg1.6.x Support => cpg1.6 miscellaneous => Topic started by: andyschlei on May 14, 2022, 11:00:02 pm

Title: Unable to Connect to Database
Post by: andyschlei on May 14, 2022, 11:00:02 pm
Sometime in the last couple of weeks, my Coppermine gallery stopped working.  I get the following error message, which unfortunately doesn't help much:
Quote
Coppermine critical error:
Unable to connect to database !

MySQLi said: :

I haven't changed anything in months, so I am at a loss to know what happened.  I don't get anything in the website error logs.

Any and all help would be greatly appreciated!
Title: Re: Unable to Connect to Database
Post by: andyschlei on May 14, 2022, 11:01:56 pm
One other important fact:  I can connect to the database in PHPMyAdmin without any problem.
Title: Re: Unable to Connect to Database
Post by: andyschlei on May 15, 2022, 12:54:29 am
I've tried upgrading and when I try to run the update.php script I get the same error.

I tried doing a clean install on the website and it works fine.
Title: Re: Unable to Connect to Database
Post by: andyschlei on May 15, 2022, 01:01:30 am
OK, the problem is fixed.

Believe it or not, all I did was to change the password on the database to the one from the config.inc.php file.  I have no idea how the password got mucked up on the backend, but it happened to two galleries on my site.

Gremlins or the mysterious hacker who just changes your MySQL users passwords.
Title: Re: Unable to Connect to Database
Post by: phill104 on May 15, 2022, 10:11:52 am
Glad you got it fixed.