gunicorn.socket: Failed with result 'service-start-limit-hit'

隐身守侯 提交于 2020-01-24 11:22:52

问题


I was deploying a django app and it failed because for some reason the gunicorn.socket file was not created even though before adding nginx it worked perfectly fine so I searched the internet and found this answer where the guy says that the reason for this is the virtual environment but I'm sure there must be a way around it using venv right?

the log I get from nginx:

connect() to unix:/run/gunicorn.sock failed (11 1: Connection refused) while connecting to upstream,

error from gunicorn:

gunicorn.socket: Failed with result 'service-start-limit-hit'.

I'm 100% sure the problem is with gunicorn not with the setup of nginx becuase I did check for the gunicorn file and it did not exist.


回答1:


I don't know django, but I am going to assume that this issue is similar to an issue I saw trying to get the MySQL service to start on one of my servers today (see here: https://stackoverflow.com/a/55141733/708323)

Basically, the "start-limit-hit" message is a red herring - service start tries to start which ever service name you provide multiple times, and if after the fifth failed attempt (for me, at least) it crashes out on the sixth attempt with "start-limit-hit". You'll need to investigate the actual syslog (possibly /var/log/syslog) to see what the real errors are that are preventing the service from starting on attempts 1-5.



来源:https://stackoverflow.com/questions/55093622/gunicorn-socket-failed-with-result-service-start-limit-hit

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!