Heroku的"Puma Port 5000已在使用中"滑轨 [英] Heroku Open "Puma Port 5000 Already In Use" Rails
本文介绍了Heroku的"Puma Port 5000已在使用中"滑轨的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
当我Control-C退出"Heroku Open"(Heroku工具栏服务器命令)时.我无法重新启动.我收到此错误:
When I Control-C to quit "Heroku Open" (the Heroku Toolbar server command). I'm unable to restart. I receive this error:
/vendor/bundle/gems/puma-2.14.0/lib/puma/binder.rb:233:in `initialize': Address already in use - bind(2) for "0.0.0.0" port 5000 (Errno::EADDRINUSE)
web.1 | s/vendor/bundle/gems/puma-2.14.0/lib/puma/cluster.rb:304:in `run'
为避免出现此问题,它们是关闭Heroku工具栏本地Rails服务器的正确"方法吗?
Is their a "correct" way to shut down the Heroku Toolbar local rails server in order to avoid this problem?
推荐答案
我用来解决此问题的唯一方法是运行lsof来识别使用端口:5000的对象,然后对pid进行sudo kill s)正在访问该端口.
The only method I've used that works to resolve this problem is to run lsof to identify what is using port :5000 and then sudo kill on the pid(s) that are accessing that port.
lsof -i :5000
sudo kill -9 <pid>
这篇关于Heroku的"Puma Port 5000已在使用中"滑轨的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文