Wordpress Error - "Error Establishing Connection"


I just launched a droplet of $5 for my new wordpress blog. i was customizing it and one error continuously appearing.

Website has no content but still it shows the following error

“Error Establishing Connection”

how to solve this?


Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hello, @oasysdigital

I will recommend you to double check the database details from the wp-config.php file and also make sure that MySQL/MariaDB is running as well.

Also make sure to double check our existing tutorial on how to troubleshoot this error on your droplet.

Hope that this helps! Regards, Alex

The error itself is simply telling you it cannot connect to the assuming local mysql server?

You want to ensure the DB server is actually running, you can usually do this via SSH and simply type in mysqladmin -u root -p status, if its running then you should get a prompt, otherwise it will error out telling you the DB server is not running.

If it is running then you will want to check you WP-config to see what DB server / port it’s looking at. Ensure the username and password are working as well.

Hi Thanks for reply Dikshit

I tried to run few commands but it shows error

like when I run the command

sudo netstat -plt

it says

sudo: netstat: command not found

am i doing right?

Hey @oasysdigital

From what I understand is that when you attempted to load your WordPress site you’re getting a message stating “Error establishing a database connection” the cause is most often one of the following:

  • The database has crashed, often due to the server running out of memory
  • The database login credentials are incorrect in your WordPress configuration
  • The WordPress database tables have been damaged

Also, you can refer to the tutorial link below:



Its “Error Establishing Database Connection”