简体   繁体   中英

Django site 504 time out on nginx

We have django 1.1.1 website, that works fine on development server (python manage.py runserver). But when we use nginx + wsgi, ngnix is timed out and return "504 Gateway is time out". error.log is empty.

So, probably it is environment issue but I don't know where to start because it was working fine and now its not and I have no error to point me in the right direction. Restarting nginx doesn`t help.

I'm new enough to this environment, could someone possible give me some idea of how I could find the problem

Thanks, Derek

You can try setting DEBUG = True in settings.py and see if you can review the errors.

If that doesn't work, set DEBUG back to False try setting up the ADMINS so you receive emails with the error reports.

Those are my only suggestions at the moment. Good luck.

Look at the error logs for the Nginx server. My guess is that it's invoking something through FCGI or WSGI (whatever you had set up), but that it's not responding correctly. More detail should be in those logs.

事实证明,中间件配置是错误的……已将其修复并恢复正常。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM