Engintron v1.16版本更新bug,导致80端口被占用无法重启

本文记录了一次Nginx服务启动失败的问题排查过程。在更新engintron版本后,尝试重启Nginx时遇到“地址已在使用”的错误提示。通过检查端口使用情况和对比不同版本的配置文件,最终确定了问题的原因并给出了解决方案。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Nginx Status:

Redirecting to /bin/systemctl status nginx.service
● nginx.service - nginx - high performance web server
   Loaded: loaded (/usr/lib/systemd/system/nginx.service; enabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Mon 2021-11-01 21:14:06 MDT; 2s ago
     Docs: http://nginx.org/en/docs/
  Process: 27317 ExecStop=/bin/sh -c /bin/kill -s TERM $(/bin/cat /var/run/nginx.pid) (code=exited, status=0/SUCCESS)
  Process: 27276 ExecReload=/bin/sh -c /bin/kill -s HUP $(/bin/cat /var/run/nginx.pid) (code=exited, status=0/SUCCESS)
  Process: 27321 ExecStart=/usr/sbin/nginx -c /etc/nginx/nginx.conf (code=exited, status=1/FAILURE)
 Main PID: 26667 (code=exited, status=0/SUCCESS)

Nov 01 21:14:03 server.sunnylab.org nginx[27321]: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
Nov 01 21:14:04 server.sunnylab.org nginx[27321]: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
Nov 01 21:14:04 server.sunnylab.org nginx[27321]: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
Nov 01 21:14:05 server.sunnylab.org nginx[27321]: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
Nov 01 21:14:05 server.sunnylab.org nginx[27321]: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
Nov 01 21:14:06 server.sunnylab.org nginx[27321]: nginx: [emerg] still could not bind()
Nov 01 21:14:06 server.sunnylab.org systemd[1]: nginx.service: control process exited, code=exited status=1
Nov 01 21:14:06 server.sunnylab.org systemd[1]: Failed to start nginx - high performance web server.
Nov 01 21:14:06 server.sunnylab.org systemd[1]: Unit nginx.service entered failed state.
Nov 01 21:14:06 server.sunnylab.org systemd[1]: nginx.service failed.

在配置了新的server以后,重启engintron,会出现以上错误,查端口80发现,并没有80端口被占用。

后来与之前版本对比,发现以下不同。

engintron v1.16 的default.conf

 engintron v1.11 的default.conf

 只需要将这部分换成老版本的配置,就可以成功重启了。

因此可能是engintron v1.16更新导致的bug。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值