nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use) 解决办法

遇到这个问题,是因为某个服务正在使用80端口;
解决步骤:
1.使用netstat命令查看80端口被哪个服务占用了

netstat -ant | grep 80
  • 1

2.关闭80端口

/etc/init.d/httpd stop
  • 1

3.启动nginx

service nginx restart
  • 1

总结:解决一个问题必须要挖掘到问题的根源或者说本质。

如果觉得文章真心好, 请打赏下我吧http://blog.csdn.net/assassinsshadow/article/details/76086401

猜你喜欢

转载自www.cnblogs.com/a8457013/p/9224003.html