In another post, I’ve talked about how to fix the database connections problems is WordPress, it’s a big problem that stops thousands of blogs and site from working completely, however, the solution can be simple and I’ll show you a how to manage the user privileges in your MySQL databases to fix the problem. Indeed, in many cases, the database user permissions can be broken for any reason.
The first thing that you need to do is log into your cPanel control panel, then, find the database icon as the below screenshot.
Then, you need to find your database and the username, if you have a single database, that will be easy without the need to search which database are you using for that installation. Just click the database username as the below example.
The next page will be the MySQL Account Maintenance, from there you can see all the options that you can check or uncheck for your user.
If your applications show a database connection error or any other message, you will find all the user permissions unchecked, that way, you have the database and the user but the user can’t do anything to make the site works. So, you can correct the problem by just checking the top options that will check all the privileges at once. Then click the button to save the changes and go back to your site, things will work in general.
If you don’t have a user for your database, you can create it, every database should be linked to a user to be able to make a site works with PHP. At the same time, the database itself can be broken and in this case, you can read how to repair a broken database and that will be easy in a few steps.
In other cases, the server can be down for maintenance and in that case, you just need to wait a few minutes and then contact your web hosting company to solve the problem if nothing works. To verify that the PhpMyAdmin works or not, click its icon from your cPanel dashboard, then see if you can see your database tables or not. If the server has problems with connections, you will not be able to access the phpMyAdmin after a few moments, you will get a blank page or something with error messages. When you still get the same errors with your site, then it’s the time the change our hosting provider that will no longer work correctly or support you, you can use this web hosting comparison to find the best choice.