By Carpe Diem
Hello there, Can someone please help me, I always got this Error Establishing Database Connection on my website and it almost appears every day. I am on 512mb / 20GB disk Plan ( Droplet) and my traffics range is only 500-800 traffics daily. Can someone please tell me how to fix this issue? Almost getting this issue from the beginning I created my website. My website Plugins posted below:
BackUpWordPress Complete Analytics Optimization Suite (CAOS) Easy Social Share Buttons for WordPress EasyRecipe Plus Envato Market Facebook Pixel Instant Articles for WP Jetpack by WordPress.com jQuery Pin It Button for Images Pro Nginx Helper Redirection W3 Total Cache Wordfence Security WP Smush WP-Optimize Yoast SEO
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi,
You’re getting that error because MySQL is crashing and so WordPress is no longer able to connect to it. MySQL and WordPress, especially with a lot of plugins installed, both require a lot of memory and a 512MB Droplet is not enough to handle those requirements.
I would recommend upgrading to a 1GB Droplet first—we have recently introduced new plans so you will be able to do that without any additional cost. But, you might want to also consider upgrading to a 2GB Droplet to make sure that both programs have some room to breathe.
Additionally, check out this tutorial on setting up Redis Caching. It is a bit old but the same instructions should work, though you might have to replace php5 with php7:
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.