Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Gunicorn Connection in Use: ('0.0.0.0', 5000)

I installed redis this afternoon and it caused a few errors, so I uninstalled it but this error is persisting when I launch the app with foreman start. Any ideas on a fix?

foreman start
22:46:26 web.1  | started with pid 1727
22:46:26 web.1  | 2013-05-25 22:46:26 [1727] [INFO] Starting gunicorn 0.17.4
22:46:26 web.1  | 2013-05-25 22:46:26 [1727] [ERROR] Connection in use: ('0.0.0.0', 5000)
like image 620
Craig Cannon Avatar asked May 26 '13 05:05

Craig Cannon


3 Answers

Just type

sudo fuser -k 5000/tcp

.This will kill all process associated with port 5000

like image 145
Emil George James Avatar answered Oct 23 '22 04:10

Emil George James


This should do the trick for you:

kill -9 $(lsof -i:5000 -t) 2> /dev/null

where 5000 is the port you want to kill

like image 40
Sean-Roberts Avatar answered Oct 23 '22 05:10

Sean-Roberts


Check your processes. You may have had an unclean exit, leaving a zombie'd process behind that's still running.

like image 13
Jack Shedd Avatar answered Oct 23 '22 06:10

Jack Shedd