fedora 16 httpd啟動失敗 Starting httpd (via systemctl): Job failed. See system logs and 'systemctl status' for details. error 4 in mod_perl.so


http://hi.baidu.com/maclinuxp/item/28d8b62828ee1d88af48f585

https://bugzilla.redhat.com/show_bug.cgi?id=730832

http://forums.fedoraforum.org/showthread.php?t=272154

 

[root@localhost ~]# service httpd start
Starting httpd (via systemctl): Job failed. See system logs and 'systemctl status' for details.
[FAILED]

 

[root@localhost ~]# systemctl --failed
UNIT LOAD ACTIVE SUB JOB DESCRIPTION
httpd.service loaded failed failed The Apache HTTP Server (prefork MPM)

LOAD = Reflects whether the unit definition was properly loaded.
ACTIVE = The high-level unit activation state, i.e. generalization of SUB.
SUB = The low-level unit activation state, values depend on unit type.
JOB = Pending job for the unit.

1 units listed. Pass --all to see inactive units, too.

 

[root@localhost ~]# systemctl status httpd.service

 

 

問題描訴:

 

 service httpd start

Starting httpd (via systemctl):  Job failed. See system logs and 'systemctl status' for details.

這里有兩個文件可以查看

1./var/log/httpd/error-log

基本沒收獲,這個問題根本沒有寫這個文件

2./var/log/messages

這個文件基本所有程序都會向里面寫東西,我先清空該文件,方便我們觀察錯誤

echo "" >/var/log/messages

然后執行  service httpd start

當然肯定錯誤還是有,這個時候我們在查看message文件

[root@localhost log]# more messages

Feb 18 21:06:31 localhost kernel: [13315.945323] intel ips 0000:00:1f.6: MCP lim

it exceeded: Avg temp 9279, limit 9000

Feb 18 21:06:34 localhost httpd[15298]: httpd: Could not reliably determine the 

server's fully qualified domain name, using localhost.localdomain for ServerName

Feb 18 21:06:34 localhost httpd[15298]: (98)Address already in use: make_sock: c

ould not bind to address [::]:443

Feb 18 21:06:34 localhost httpd[15298]: (98)Address already in use: make_sock: c

ould not bind to address 0.0.0.0:443

Feb 18 21:06:34 localhost httpd[15298]: no listening sockets available, shutting

 down

==============

可以看出 我們電腦的443端口被其他程序占用了
我們來查看該端口到底運行的什么程序----------

[root@localhost log]# lsof -i:443

COMMAND    PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME

hostd-wor 1722 root   28u  IPv4  23805      0t0  TCP *:https (LISTEN)

hostd-wor 1722 root   29u  IPv6  23806      0t0  TCP *:https (LISTEN)

好了,看得出 是 hostd-wor 命令 占用了改端口。果斷殺之

[root@localhost log]# kill 1722

然后在啟動試試

[root@localhost log]# service httpd start

Starting httpd (via systemctl):                            [確定]

=============

看樣子是成功了。。。。。。。。。。。。

 

然后我們改變一下端口試試,httpd 默認的監聽端口是 80,我改為 9999

 

 

這是因為 9999端口被selinx 禁止了

我們添加上

semanage port -a -t http_port_t -p tcp 9999

然后在啟動就行了

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



猜您在找 Apache重啟失敗,提示:Job for httpd.service failed. See 'systemctl status httpd.service' and 'journalctl -xn' for details. Restarting network (via systemctl): Job for network.service failed because the control process exited with error code. See "systemctl status network.service" and "journalctl -xe" for details. docker 啟動失敗 Job for docker.service failed because the control process exited with error code. See "systemctl status docker.service" and "journalctl -xe" for details. 啟動Nginx服務失敗:Job for nginx.service failed because the control process exited with error code. See "systemctl status nginx.service" and "journalctl -xe" for details. Job for httpd.service failed because the control process exited with error code. See "systemctl status httpd.service" and "journalctl -xe" for details Linux 重啟網卡失敗 Job for network.service failed because the control process exited with error code. See "systemctl status network.service" and "journalctl -xe" for details. centos7啟動MySQL報 Job for mysqld.service failed because the control process exited with error code. See "systemctl status mysqld.service" and "journalctl -xe" for details. 【問題管理】 -- RabbitMQ啟動時報錯:Job for rabbitmq-server.service failed because the control process exited with error code. See "systemctl status rabbl -xe" for details. linux----------啟動network的時候報錯Job for network.service failed because the control process exited with error code. See "systemctl status network.service" and "journalctl -xe" for details. 啟動Jenkins報錯"Job for jenkins.service failed because the control process exited with error code. See "systemctl status jenkins.service" and "journalctl -xe" for details."解決辦法
 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM