Error establishing a database connection

All my wordpress sites have went down about 9 sites - and all saying the same error "Error establishing a database connection" - I reset the linode - but no joy.

I use serverpilot

Please assist, thanks

1 Reply

There are a few reasons why you may be seeing this error, a few of which we cover in response to this question.

The first step is likely to check the status of your database service. If checking the status shows a specific error, you can try to research that to get more information about what caused it or look at any related service logs.

You can then try to restart the service and enable the service if needed.

Our guide to Troubleshooting Web Servers, Databases and Other Services shows how to check to make sure you have adequate disk space. You can also check your memory usage. If you find you're running out of resources, you can size up to a plan with more space and RAM or you can take steps to Optimize your Database performance to address the RAM.

Seeing that specific error suggest the Linode that hosts your websites is connected to networking. If your database in on a different server than your web server, then it's worth looking for any possible networking issues and making sure that nothing is blocking the connection. These guides should help with that:

I did a little digging into ServerPilot's documentation to see if they have any suggestions specific to them, and they suggest the most common cause of this issue is WordPress running out of memory, and provided this information about how to fix it. If it's not memory issues, they recommend updating your credentials.

Finally, my assumption here is that this is a database you manage on your own Linode. If there is an issue with a Managed Database Cluster, it's possible we may need to do something on our end. If that's the case, please contact the support team and we'll do our best to help, though these guides could be a good starting point for you.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct