nginx: [emerg] bind() to [::]:80 failed (98: Address already in use) 错误

(1)查看80端口是不是被占用了

$ netstat -anp |grep 80
tcp        0      0 0.0.0.0:80              0.0.0.0:*               LISTEN      2679/nginx: master  
tcp        0      0 144.34.160.104:58030    142.250.72.227:443      TIME_WAIT   -                   
tcp        0      0 144.34.160.104:58832    119.29.29.29:80         TIME_WAIT   -            

直接把进程 2679 kill 掉:

kill 2679

(2) 重新启动 Nginx:

nginx

参考:

  1. Nginx
©️2020 CSDN 皮肤主题: 酷酷鲨 设计师:CSDN官方博客 返回首页