美文网首页
nginx: [emerg] bind() to 0.0.0.0

nginx: [emerg] bind() to 0.0.0.0

作者: 悟饭哪 | 来源:发表于2020-11-19 09:53 被阅读0次

使用systemctl start nginx启动nginx失败,

Job for nginx.service failed because the control process exited with error code.
See "systemctl status nginx.service" and "journalctl -xe" for details.

使用systemctl status nginx查询时,看到错误:nginx: [emerg] bind() to 0.0.0.0:8081 failed (98: Address already in use)

already in use.png
原因:有可能之前启动过的nginx影响到了,但还没有停用。
解决办法:
sudo pkill -f nginx & wait $!
sudo systemctl start nginx
running.png

Have fun.

相关文章

网友评论

      本文标题:nginx: [emerg] bind() to 0.0.0.0

      本文链接:https://www.haomeiwen.com/subject/cejkiktx.html