Question

Fixing bad gateway issue 502

Hi everyone,

From time to time my website is getting error 502 bad gateway or just simply doesent loading up. When I’m looking at the graphs of CPU usage I’ve realized that when I want to edit some posts on wordpress the CPU usage increasing to high levels like 90%.

What I’m supposed to do, restart the droplet or resize the plan? When I do this everything will be good?


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.

I’m using Nginx 1.1.0.5, Ubuntu 14.04.

How I am supposed to check which plugin is causing the problem? Screenshot of console

Hi @brzezickiandrzej

What web server are you using, Apache or Nginx? Which version? And which version of PHP? Are you running Ubuntu 14.04 or a different version?

When you have the problem with high CPU, which process is eating everything? You can run the command top to see processes and amount of CPU+RAM they eat.

Usually the problem is rooted in a bad plugin in WordPress, since the way it’s crashing. How big is your droplet?