Have had to reboot server twice in two days

Hi, I set up a WordPress blog on Digital Ocean and I’ve had to reboot the server twice in two days. After setting up the blog, and posting one story successfully, I returned to admire my beautiful work two hours later only to see the message (Error Establishing Database Connection). I then rebooted the server and got it working again, posted another heartbreaking story successfully, and, after waiting a period of time, I returned to admire my first two stories only to see Error Establishing Database Connection again, which I was able to fix by rebooting the server.

I used the tutorial on your website to setup wordpress with Apache and Mysql.

Is this expected behavior? Is there anything I could do to prevent this from happening?

Submit an answer

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!

Sign In or Sign Up to Answer

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.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Check out <a href=“”>10 Million hits a day with WordPress using a $15 server</a> (but notice that the author of that blog post now uses a $10/mo. DigitalOcean VPS).

Thanks, the solution provided by Kamal helped! Will also look at nginx. Thanks Pablo

Most people would not tolerate buying a Porsche that needed to be restarted every 2 hours (moving from shared hosting to a VPS is like upgrading from a Chevy Cavalier to a Porsche). Unless you know more about WordPress and web servers than the inventors of WordPress, why not mimic what they do? Check out: <br> <br>1.) <a href=“”>How To Migrate a WordPress Installation from Apache to Nginx on an Ubuntu VPS</a>; <br> <br>2.) <a href=“”>How To Configure Single and Multiple WordPress Site Settings with Nginx</a>; <br> <br>3.) <a href=“”>How To Install Wordpress, Nginx, PHP, and Varnish on Ubuntu 12.04</a>.