Power Failure then "Error establishing a database connection"
Posted by: freespirit (---.plus.com)
Date: July 20, 2017 11:00PM

Wamp Vs 3 32bit, Apache 2.4.17, PHP 5.6, My Sql 5.7.9
Windows 7, 32 bit

Working Perfectly then power failure. Rebooted server, clicked my website to get this.
Error establishing a database connection.

I launch phpmyadmin to login only to get !Cannot log in to the MySQL server.

I have looked online and a lot of the recommendations are for changing the password and I really don't think it is that. I don't mind doing it if I have to but would rather be guided through it if there is no other solution.

Any help would be appreciated as my site is down and people are asking why and I don't know.

The icon is Green and all services appear to be running.

regards
freespirit



Edited 1 time(s). Last edit at 07/20/2017 11:01PM by freespirit.

Options: ReplyQuote
Re: Power Failure then "Error establishing a database connection"
Posted by: RiggsFolly (Moderator)
Date: July 21, 2017 10:27AM

It is likely a database corruption and the auto recoevery has failed.

Look in the mysql error log and see what it is telling you. Then check with the MySQL Documentation on a recoevery stratagy.

See my signature for links to the MySQL Manual. And the note about regular backups of databases even when developing.

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: Power Failure then "Error establishing a database connection"
Posted by: freespirit (---.plus.com)
Date: July 21, 2017 02:13PM

Hi Riggs Folly,

Thank you for replying, as usual.

I've looked at the log, I only have 7 lines with line 6 and 7 saying

InnoDB: Progress in percent: 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99
2017-03-15T12:00:51.114257Z 0 [Warning] wampmysqld: Forcing close of thread 9 user: 'adminmoi'

i have no idea what this means and the reference manual looks like information overload for me with no idea of where to start. Im sorry, im not a developer so I don't undertstand what I am seeing.

Would it be simpler to uninstall and install the latest version of wamp?

Options: ReplyQuote
Re: Power Failure then "Error establishing a database connection"
Posted by: RiggsFolly (Moderator)
Date: July 21, 2017 03:33PM

If you dont mind loosing the data, it probably would be easier to install the latest version.

If you took a backup before things went wrong, you should be able to restore that to the new database

---------------------------------------------------------------------------------------------
(Windows 10 Pro 64bit) (Wampserver 3.3.4 64bit) Aestan Tray Menu 3.2.5.4
<Apache versions MULTIPE> <PHP versions MULTIPLE> <MySQL Versions MULTIPLE>
<MariaDB versions MULTIPLE> <phpMyAdmin versions MULTIPLE> <MySQL Workbench 8.0.23>

Read The Manuals Apache -- MySQL -- PHP -- phpMyAdmin
Get your Apache/MySQL/mariaDB/PHP ADDONs here from the WAMPServer alternate Repo
-X-X-X- Backup your databases regularly Here is How dont regret it later! Yes even when developing -X-X-X-

Options: ReplyQuote
Re: Power Failure then "Error establishing a database connection"
Posted by: freespirit (---.plus.com)
Date: July 21, 2017 03:41PM

Hi Riggs,

thanks for that. yes, I back up regularly. Ill do that, alot simpler n thank you again.

regards
freesp

Options: ReplyQuote


Sorry, only registered users may post in this forum.