Report this

What is the reason for this report?

Rebooted server via ubuntu command line, now website returns 502

Posted on March 6, 2019

Hi, My website has been running since I deployed it yesterday. I rebooted the server this morning, and now the website won’t load. Im using nginx and gunicorn - i have tested both and the tests were successful.

What reasons are there that the website now wont load, after nothing was changed during the reboot



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!

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.

502 Bad Gateway means nginx is unable to communicate to gunicorn.

Make sure that gunicorn is running on the expected port. You can verify it using :

netstat -tulpn

If you find it running and the website still shows 502, try restarting nginx and gunicorn.

Let me know if you have any further questions.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.