Answer the question
In order to leave comments, you need to log in
How to overcome the error "Job for httpd.service failed. See 'systemctl status httpd.service' and 'journalctl -xn' for details."?
I have a home server on CentOS 7 (I am studying Linux on it), I want to set up a web server on it, I installed everything (mysql, apache, php, phpmyadmin), everything works fine, but when I try to set up virtual hosts, this error appears at startup /restart apache (apachectl restart):
Job for httpd.service failed. See 'systemctl status httpd.service' and 'journalctl -xn' for details.
httpd.service - The Apache HTTP Server
Loaded: loaded (/usr/lib/systemd/system/httpd.service; enabled)
Active: failed (Result: exit-code) since Пт 2015-06-26 17:19:42 MSK; 2min 1s ago
Process: 2942 ExecStop=/bin/kill -WINCH ${MAINPID} (code=exited, status=1/FAILURE)
Process: 2940 ExecStart=/usr/sbin/httpd $OPTIONS -DFOREGROUND (code=exited, status=1/FAILURE)
Main PID: 2940 (code=exited, status=1/FAILURE)
июн 26 17:19:42 server.home systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE
июн 26 17:19:42 server.home kill[2942]: kill: cannot find process ""
июн 26 17:19:42 server.home systemd[1]: httpd.service: control process exited, code=exited status=1
июн 26 17:19:42 server.home systemd[1]: Failed to start The Apache HTTP Server.
июн 26 17:19:42 server.home systemd[1]: Unit httpd.service entered failed state.
-- Logs begin at Пт 2015-06-26 16:12:50 MSK, end at Пт 2015-06-26 17:22:47 MSK. --
июн 26 17:20:01 server.home systemd[1]: Created slice user-0.slice.
-- Subject: Unit user-0.slice has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit user-0.slice has finished starting up.
--
-- The start-up result is done.
июн 26 17:20:01 server.home systemd[1]: Starting Session 11 of user root.
-- Subject: Unit session-11.scope has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit session-11.scope has begun starting up.
июн 26 17:20:01 server.home systemd[1]: Started Session 11 of user root.
-- Subject: Unit session-11.scope has finished start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit session-11.scope has finished starting up.
--
-- The start-up result is done.
июн 26 17:20:01 server.home CROND[2952]: (root) CMD (/usr/lib64/sa/sa1 1 1)
июн 26 17:22:46 server.home systemd[1]: Starting The Apache HTTP Server...
-- Subject: Unit httpd.service has begun with start-up
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit httpd.service has begun starting up.
июн 26 17:22:47 server.home systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE
июн 26 17:22:47 server.home kill[2966]: kill: cannot find process ""
июн 26 17:22:47 server.home systemd[1]: httpd.service: control process exited, code=exited status=1
июн 26 17:22:47 server.home systemd[1]: Failed to start The Apache HTTP Server.
-- Subject: Unit httpd.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit httpd.service has failed.
--
-- The result is failed.
июн 26 17:22:47 server.home systemd[1]: Unit httpd.service entered failed state.
Answer the question
In order to leave comments, you need to log in
In general, the problem was found - SELinux, I still don’t know how to configure it, so I decided to just disable it for now ...
Instructions here how to do it: https://docs.fedoraproject.org/ru-RU/Fedora/13/htm..
After disabling SELinux, you must restart your computer .
Could not open configuration file /etc/httpd/sites-enabled/test.local.conf: No such file or directory
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question