Fixing Database Connection Error

When a site throws the error: "Error establishing a database connection", this usually means there is a miscommunication between the database and the files in the File Manager that needs correcting.

1. Open up the Files and Tables section in Installatron.

Fixing_Database_Connection_1.png

2. Compare the four sections in red to the database file in the File Manager.

3. Open up the File Manager and navigate to where the site is installed; in this case, it’s right in the public_html folder.

The database file that’s within the installation can vary depending on the application. Since this is a WordPress installation, you’ll work with the wp-config.php file:

Fixing_Database_Connection_2.png

You can edit the file right within the File Manager.

4. Click Edit in toolbar across the top of the screen.

Fixing_Database_Connection_3.png

From here just make sure that the database name/username, password, and host all match to the Files and Tables section in Installatron. If any are incorrect, you can change them directly in the wp-config.php file. Once they all match, click Save Changes and reload the site.

Was this article helpful?
0 out of 0 found this helpful

Articles in this section

See more
Reclaim Hosting Support Hours
8:00 am - 5:00 pm ET, Monday through Friday
Submit a Ticket
Get a quick and helpful response from the pros.
Need Extra Support?
No problem, we're here to help! Talk to us about Professional Services or custom Service Level Agreements.