作成
APACHE2.4が突然死んでいた。犯人は ssl.conf まわりだった
###memo 朝方にAPACHEが死んでました・・・ 前日にやってたことは、SSL用サイトの新規追加で vhosts や ssl.conf をいじって、service httpd reload で 設定ファイルだけ読み込んだ状態で起動放置していたら、朝方に apache が死んでました・・・ ###dl - 使用OS -- CentOS7 - WEBサーバー -- Apache2.4 ### title とりあえず色々試してみる。 ####command service httpd restart #### command error 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. ###center うーん・・・ ####command journalctl -xe #### command error ~省略~ Failed to start The Apache HTTP Server. ###center うーん・・・ #### command systemctl status httpd.service ### command error ● httpd.service - The Apache HTTP Server Loaded: loaded (/usr/lib/systemd/system/httpd.service; enabled; vendor preset: disabled) Active: failed (Result: exit-code) since 日 2018-08-19 03:55:38 JST; 5s ago Docs: man:httpd(8) man:apachectl(8) Process: 6489 ExecStop=/bin/kill -WINCH ${MAINPID} (code=exited, status=1/FAILURE) Process: 6359 ExecReload=/usr/sbin/httpd $OPTIONS -k graceful (code=exited, status=0/SUCCESS) Process: 6486 ExecStart=/usr/sbin/httpd $OPTIONS -DFOREGROUND (code=exited, status=1/FAILURE) Main PID: 6486 (code=exited, status=1/FAILURE) ###center うーん・・・ ### command error Unregistered Authentication Agent for unix-process:6571:1744996238 (system bus name :1.74550, object path /org/freedesktop/PolicyKit1/AuthenticationAgent, locale ja_JP.UTF-8) (disconnected from bus) ###center うーん・・・ ### command service httpd reload ### command error Redirecting to /bin/systemctl reload httpd.service ~省略~ Unregistered Authentication Agent for unix-process:6571:1744996238 (system bus name :1.74550, object path /org/freedesktop/PolicyKit1/AuthenticationAgent, locale ja_JP.UTF-8) (disconnected from bus) ###center うーん・・・ ### command apachectl -t ### command error [so:warn] [pid 6510] AH01574: module ssl_module is already loaded, skipping [so:warn] [pid 6510] AH01574: module ssl_module is already loaded, skipping ### memo あ、これ warn だけど気になる。 module ssl_module is already loaded, なんかみたことあるエラーだ・・・ で、ふぁっと思い出して。 ###title 原因 ### memo /etc/httpd/conf.d/ には大事な ssl.conf があるわけですが。 ssl.conf のバックアップファイル名を 20180818.ssl.conf にしていました。 ようは、/etc/httpd/conf.d/ は .conf の拡張子は自動で読み込まれてしまう。というのが理由でした。 ### title3 補足(うろおぼえ) ###memo 作業ミスだったわけですが、たぶん、Apache2.2 では起きなかったエラーだとおもいます。 Apache2.4 の仕様変更に伴い、ついクセでやってしまう作業ミスだと思います。 ###title 対処 ###memo 20180818.ssl.conf を 20180818.ssl.conf.bkup にファイル名を変更して、Apacheを再起動! これで治りました。 ###source success (対処方法) cd /etc/httpd/conf.d/ mv 20180818.ssl.conf 20180818.ssl.conf.bkup service httpd restart ###memo ログを見ると 5分程度で復帰できてましたが、久しぶりのサーバートラブルだったので、体感1時間ぐらいな気がしますw
wakatta 記法
投稿の仕方
基本的な記法
エンジニア向け記法
記法のサンプル
このコンテンツを見る