ansible playbook脚本启动失败-----------[start httpd service]

3 篇文章 0 订阅
2 篇文章 0 订阅
在尝试启动Apache HTTP服务时遇到错误,服务因地址已被使用而无法启动。系统日志显示httpd.service启动失败,主要原因是端口80被进程1593(squid-1)占用。通过`kill -9 1593`命令终止了占用端口的进程,但问题仍未解决。需要进一步排查为何httpd.service无法加载并启动。
摘要由CSDN通过智能技术生成

TASK [start httpd service] *****************************************************************************************
fatal: [192.168.118.18]: FAILED! => {“changed”: false, “msg”: “Unable to start service httpd: Job for httpd.service failed because the control process exited with error code. See “systemctl status httpd.service” and “journalctl -xe” for details.\n”}
在这里插入图片描述

可用尝试把受控制的那台服务器,所占用的端口给kill掉

[root@server conf]# systemctl status httpd
 httpd.service
   Loaded: not-found (Reason: No such file or directory)
   Active: failed (Result: exit-code) since  2021-08-08 17:01:31 CST; 4h 27min ago
 Main PID: 67778 (code=exited, status=1/FAILURE)

8 08 17:01:30 server systemd[1]: Starting The Apache HTTP Server...
8 08 17:01:30 server httpd[67778]: (98)Address already in use: AH00072: make_sock: could not bind to addr...:]:80
8 08 17:01:30 server httpd[67778]: (98)Address already in use: AH00072: make_sock: could not bind to addr....0:80
8 08 17:01:30 server httpd[67778]: no listening sockets available, shutting down
8 08 17:01:30 server httpd[67778]: AH00015: Unable to open logs
8 08 17:01:31 server systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE
8 08 17:01:31 server systemd[1]: Failed to start The Apache HTTP Server.
8 08 17:01:31 server systemd[1]: Unit httpd.service entered failed state.
8 08 17:01:31 server systemd[1]: httpd.service failed.
Hint: Some lines were ellipsized, use -l to show in full.
[root@server conf]# netstat -napt | grep :80
tcp        0      0 192.168.118.17:80       0.0.0.0:*               LISTEN      1593/(squid-1)      
[root@server conf]# kill -9 1593
[root@server conf]# netstat -napt | grep :80
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值