二维码

Job for httpd.service failed because the control process exited with error code. See "systemctl 解决方案

1985 人阅读 | 时间:2019年10月22日 15:48

启动 httpd 服务时报错

Job for httpd.service failed because the control process exited with error code. See "systemctl status httpd.service" and "journalctl -xe" for details.

首先 systemctl status httpd 查看下状态:

8月 14 16:57:26 10-255-0-230 httpd[28061]: (98)Address already in use: AH00072: make_sock: could not bind to address [::]:80
8月 14 16:57:26 10-255-0-230 httpd[28061]: (98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:80
8月 14 16:57:26 10-255-0-230 httpd[28061]: no listening sockets available, shutting down
8月 14 16:57:26 10-255-0-230 httpd[28061]: AH00015: Unable to open logs
8月 14 16:57:26 10-255-0-230 systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE
8月 14 16:57:26 10-255-0-230 kill[28062]: kill: cannot find process ""
8月 14 16:57:26 10-255-0-230 systemd[1]: httpd.service: control process exited, code=exited status=1
8月 14 16:57:26 10-255-0-230 systemd[1]: Failed to start The Apache HTTP Server.
8月 14 16:57:26 10-255-0-230 systemd[1]: Unit httpd.service entered failed state.
8月 14 16:57:26 10-255-0-230 systemd[1]: httpd.service failed.


更具状态看出 80 端口被占用

netstat -antlp | grep 80

了解一下

原来是 nginx 占用了端口

停止即可



nginx如何停止,命令是什么?

Linux下nginx服务如果要停止的话我们需要通过命令来控制,下面为大家整理了linux下nginx停止命令的相关知识,希望对大家有帮助!

linux的nginx停止命令详解

nginx的停止有三种方式:

linux的nginx停止命令一、从容停止

1、查看进程号

1

[root@LinuxServer ~]# ps -ef|grep nginx

2、杀死进程

1

[root@LinuxServer ~]# kill -QUIT 2072

linux的nginx停止命令二、快速停止

1、查看进程号

1

[root@LinuxServer ~]# ps -ef|grep nginx

2、杀死进程

1

2

[root@LinuxServer ~]# kill -TERM 2132

或 [root@LinuxServer ~]# kill -INT 2132

linux的nginx停止命令三、强制停止

1

[root@LinuxServer ~]# pkill -9 nginx

更多Nginx相关技术文章,请访问Nginx使用教程栏目进行学习!

以上就是nginx如何停止命令的详细内容,更多请关注php中文网其它相关文章!


©著作权归作者所有:来自ZhiKuGroup博客作者没文化的原创作品,如需转载,请注明出处,否则将追究法律责任 来源:ZhiKuGroup博客,欢迎分享。

评论专区
  • 昵 称必填
  • 邮 箱选填
  • 网 址选填
◎已有 0 人评论
搜索
作者介绍
30天热门
×
×
本站会员尊享VIP特权,现在就加入我们吧!登录注册×
»
会员登录
新用户注册
×
会员注册
已有账号登录
×