
That message, "Error establishing a database connection", usually means one of two things:
1. Database server is down (not operating)
2. You have wrong information in your wp-config.php--either the DB_HOST, DB_USER, DB_PASSWORD, or DB_NAME is incorrect.
Be sure the database is name is complete and correct along with the database username and that the username is added to the database with all or proper privileges.
The error Error Establishing a Database Connection can also occur if the MySQL / MariaDB service is not up and running. Be sure the service is up and operational.
This can also occur if there is database corruption. Log into your hosting control panel with us and select MySQL the database and repair options.