“httpd.service 的作業失敗,因為控制進程以錯誤代碼退出。” 我該如何解決? ("Job for httpd.service failed because the control process exited with error code." How do I fix this?)


問題描述

“httpd.service 的作業失敗,因為控制進程以錯誤代碼退出。” 我該如何解決? ("Job for httpd.service failed because the control process exited with error code." How do I fix this?)

通過 Certbot 安裝 SSL 證書後,我的網站出現錯誤消息“重定向過多”。經過一些研究,我認為我必須在某個地方從 HTTPS ‑> HTTP 重定向,所以我嘗試修復它,但似乎我讓它變得更糟,Apache 將不再啟動。我是一個完全的初學者,所以我很難理解哪裡出了問題。

我正在設置一個 VPS,通過 SSH 訪問 CentOS7 來託管一個簡單的 html 網站。我設置了基礎知識(相關的可能是 UFW 防火牆、作為 DNS 的 Cloudflare、Apache 2.4.6)並設法在我的域上顯示了一個測試頁面。

然後我繼續使用本教程設置我的虛擬主機:

方法 2:

You should add in your configuration the certificate, key for this certificate and intermediate certificates. This look like:

SSLEngine on
SSLCertificateFile "/path/to/www.example.com.cert"
SSLCertificateKeyFile "/path/to/www.example.com.key"
SSLCACertificateFile "conf/ssl.crt/ca.crt"

For more details check apache documentation

(by RosARosARomeo Ninov)

參考文件

  1. "Job for httpd.service failed because the control process exited with error code." How do I fix this? (CC BY‑SA 2.5/3.0/4.0)

#Certbot #apache #Centos #SSL






相關問題

certbot-auto /letsencrypt 為指向同一服務器的多個域設置一個密鑰 (certbot-auto / letsencrypt setting up one key for multiple domains pointing to the same server)

certbot 工作時 Phpseclib 早期執行 (Phpseclib early execution while certbot working)

“httpd.service 的作業失敗,因為控制進程以錯誤代碼退出。” 我該如何解決? ("Job for httpd.service failed because the control process exited with error code." How do I fix this?)

無法使用 certbot renew/Letsencrypt 續訂證書 (Cannot renew certificates with certbot renew/Letsencrypt)

為 AWS 中託管的網站設置 HTTPS,但指向局域網中的 webAPI (Setting up HTTPS for a website hosted in AWS, but points to a webAPI in the local area network)

docker 發送內部 cerbot 日誌文件到主機 journald (docker send internal cerbot log file to host journald)

Nginx 允許來自任何域的流量 (Nginx allow traffic from any domain)

如何有效地為 2 個遠程節點使用 Kubernetes (How to use Kubernetes effectively for 2 distant nodes)

如何在 docker 映像中創建目錄? (How can I make dir inside docker image?)

更新 Certbot 時出現“連接超時(可能是防火牆問題)” ("Timeout during connect (likely firewall problem)" while renewing Certbot)

安裝certbot後找不到nginx頁面錯誤 (nginx page not found error after certbot installation)

Nginx 和 certbot 的 ERR_SSL_PROTOCOL_ERROR (ERR_SSL_PROTOCOL_ERROR with Nginx & certbot)







留言討論