この内容は古いバージョンです。最新バージョンを表示するには、戻るボタンを押してください。
バージョン:4
ページ更新者:atom
更新日時:2026-06-10 06:24:45

タイトル: エラー一覧

本稿はApache HTTP Serverのエラー一覧に関する記事です。設定エラー、起動失敗、HTTPステータス系の代表的なケースをまとめています。

子ページからエラー項目を選択してください。

エラーが出たときの基本の確認順

  1. エラーログを確認: /var/log/httpd/error_log(RHEL/CentOS)または /var/log/apache2/error.log(Debian/Ubuntu)
  2. 設定の文法チェック: httpd -t または apache2ctl configtest
  3. サービス状態: systemctl status httpd / systemctl status apache2
  4. ポート競合: ss -tlnp | grep :80 で80/443の使用状況を確認

よく見るエラーの分類

分類典型的なメッセージ主な原因
起動失敗could not bind to address [::]:80ポート競合(既に別プロセスが80番を使用)
設定ファイルSyntax error on line N of /etc/httpd/conf/httpd.conf設定ファイルの記述ミス
モジュールInvalid command, perhaps misspelled or defined by a module not includedmod_xxx の未ロード
権限Permission denied / AH00035DocumentRoot配下の権限、SELinux
クライアント側403 Forbidden / 404 Not Found / 500 Internal Server Error権限・パス・アプリ側のエラー
SSLSSL Library Error / certificate verify failed証明書・鍵パスの誤り、CA配置の問題

主要なログ確認コマンド

# RHEL/CentOS系
$ sudo tail -f /var/log/httpd/error_log
$ sudo tail -f /var/log/httpd/access_log

# Debian/Ubuntu系
$ sudo tail -f /var/log/apache2/error.log
$ sudo tail -f /var/log/apache2/access.log

設定変更後にやること

# 設定の文法チェック
$ sudo httpd -t
# 設定リロード(停止せずに反映)
$ sudo systemctl reload httpd
# 完全再起動
$ sudo systemctl restart httpd

注意点

  • SELinuxが有効なシステムでは、DocumentRoot変更後に chcon / restorecon で適切なコンテキストを付ける必要がある
  • 403が出るとき、ログには AH01630: client denied by server configuration 等の詳細が出る
  • reload は graceful restart で接続中のリクエストを切らない。設定変更時はまずこちらを使う

関連