Question

Apache won't start after installing SSL certificate

Hi guys,

I am using CentOS 7 and running Apache/2.4.6. When I installed an SSL certificate for one of the virtual servers and tried to restart Apache, I got the following error:

# service httpd restart
Redirecting to /bin/systemctl restart httpd.service
Job for httpd.service failed because the control process exited with error code. See "systemctl status httpd.service" and "journalctl -xe" for details.

Running the status command gives the following output:

# systemctl status httpd.service -l
● httpd.service - The Apache HTTP Server
   Loaded: loaded (/usr/lib/systemd/system/httpd.service; enabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Fri 2017-10-06 11:06:01 CEST; 40s ago
     Docs: man:httpd(8)
           man:apachectl(8)
  Process: 13387 ExecStop=/bin/kill -WINCH ${MAINPID} (code=exited, status=1/FAILURE)
  Process: 13385 ExecStart=/usr/sbin/httpd $OPTIONS -DFOREGROUND (code=exited, status=1/FAILURE)
 Main PID: 13385 (code=exited, status=1/FAILURE)

Oct 06 11:06:01 server.3pdevelopment.info systemd[1]: Starting The Apache HTTP Server...
Oct 06 11:06:01 server.3pdevelopment.info httpd[13385]: [Fri Oct 06 11:06:01.011935 2017] [so:warn] [pid 13385] AH01574: module rewrite_module is already loaded, skipping
Oct 06 11:06:01 server.3pdevelopment.info systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE
Oct 06 11:06:01 server.3pdevelopment.info kill[13387]: kill: cannot find process ""
Oct 06 11:06:01 server.3pdevelopment.info systemd[1]: httpd.service: control process exited, code=exited status=1
Oct 06 11:06:01 server.3pdevelopment.info systemd[1]: Failed to start The Apache HTTP Server.
Oct 06 11:06:01 server.3pdevelopment.info systemd[1]: Unit httpd.service entered failed state.
Oct 06 11:06:01 server.3pdevelopment.info systemd[1]: httpd.service failed.

And running the journalctl -xn provides the following:

# journalctl -xn
-- Logs begin at Fri 2017-10-06 10:49:08 CEST, end at Fri 2017-10-06 11:07:57 CEST. --
Oct 06 11:07:43 server.3pdevelopment.info sshd[13400]: Failed password for root from 59.45.175.36 port 48556 ssh2
Oct 06 11:07:44 server.3pdevelopment.info sshd[13400]: pam_succeed_if(sshd:auth): requirement "uid >= 1000" not met by user "root"
Oct 06 11:07:46 server.3pdevelopment.info sshd[13400]: Failed password for root from 59.45.175.36 port 48556 ssh2
Oct 06 11:07:46 server.3pdevelopment.info sshd[13400]: pam_succeed_if(sshd:auth): requirement "uid >= 1000" not met by user "root"
Oct 06 11:07:48 server.3pdevelopment.info sshd[13400]: Failed password for root from 59.45.175.36 port 48556 ssh2
Oct 06 11:07:51 server.3pdevelopment.info sshd[13400]: Received disconnect from 59.45.175.36 port 48556:11:  [preauth]
Oct 06 11:07:51 server.3pdevelopment.info sshd[13400]: Disconnected from 59.45.175.36 port 48556 [preauth]
Oct 06 11:07:51 server.3pdevelopment.info sshd[13400]: PAM 2 more authentication failures; logname= uid=0 euid=0 tty=ssh ruser= rhost=59.45.175.36  user=root
Oct 06 11:07:57 server.3pdevelopment.info sshd[13402]: Received disconnect from 121.18.238.106 port 47931:11:  [preauth]
Oct 06 11:07:57 server.3pdevelopment.info sshd[13402]: Disconnected from 121.18.238.106 port 47931 [preauth]

I am a software developer so this is not my area of expertise, so any help would be greatly appreciated.

Thanks in advance!

Show comments

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

-bash: apachectl: command not found

same error while installing ssl with cent os web panel how can i fix without rebuilding the server :-)

Do you get any errors typing “apachectl configtest”?