ubuntu启动nginx显示(98: Address already in use)

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

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

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

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

nginx: [emerg] still could not bind()

原因80端口被占用

使用命令 lsof -i:80 查看哪些进程占用了80端口

然后使用 kill -9:(具体的进程)

然后重启nginx 

猜你喜欢

转载自blog.csdn.net/shixiansen6535/article/details/87359302