Question

Wordpress Eror 502/504/524 (in certain time)

Helo. Recently, our website is getting error 502/504 in certain time. the error often happen at 10 AM and 02 PM in Indonesia time. besides, we get 524 error. in addition, when the website is error, our CPU and memory server is allright.

The error(s) might occure after we updated to wordpress 5.9.2. We’ve checked for plugin and other systesm, but we found nothing. We need your help to repair our website. Thank you.


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.

Hi @SandyLightCyanSubmarine,

The error you are seeing seems to be related to your Nginx service. I’ll recommend checking ou the logs. There you can see a more detailed message rather than the generic 502/504/524 error codes. The Nginx error log can be found at /var/log/nginx/error.log. When checking it, you can see the last 100 or 200 lines to see the error

  1. tail -n 200 /var/log/nginx/error.log

There is time and date on each entry so you can see the entry when you experienced the issue.

Once you know the exact error, you can either post it here or debug further with it.

Hello,

I could suggest checking your Nginx error log so that you could see the actual error rather than the generic 502/504 errors.

You can do that with the following command:

sudo tail -100 /var/log/nginx/error.log

Feel free to share the log here after removing any sensitive information from the output.

Also, I could suggest the following answer here on how to troubleshoot common Nginx problems:

https://www.digitalocean.com/community/questions/how-to-troubleshoot-common-nginx-issues-on-linux-server

Regards,

Bobby