Ubuntu20.04にApacheをインストールした際、
次のエラーが発生した場合の対処法を紹介します。
・Invalid command 'RewriteEngine'
・Invalid command 'SSLEngine'
・Invalid command 'Header'
Invalid command 'RewriteEngine'
エラー内容
Jan 19 03:14:28 linuxmaster-01 apachectl[2433]: Invalid command 'RewriteEngine', perhaps misspelled or defined by a module not included in the server configuration
対応手順
$ sudo a2enmod rewrite
Enabling module rewrite.
To activate the new configuration, you need to run:
systemctl restart apache2
・Ubuntu20.04+Apacheのインストールエラー対策のもっと高い技術を身につけたいならこちら
Invalid command 'SSLEngine'
エラー内容
Jan 19 03:15:25 linuxmaster-01 apachectl[2485]: Invalid command 'SSLEngine', perhaps misspelled or defined by a module not included in the server configuration
対応手順
$ sudo a2enmod ssl
Considering dependency setenvif for ssl:
Module setenvif already enabled
Considering dependency mime for ssl:
Module mime already enabled
Considering dependency socache_shmcb for ssl:
Enabling module socache_shmcb.
Enabling module ssl.
See /usr/share/doc/apache2/README.Debian.gz on how to configure SSL and create
self-signed certificates.
To activate the new configuration, you need to run:
systemctl restart apache2
Invalid command 'Header'
エラー内容
Jan 19 03:18:15 linuxmaster-01 apachectl[2599]: Invalid command 'Header', perhaps misspelled or defined by a module not included in the server configuration
対応手順
$ sudo a2enmod headers
Enabling module headers.
To activate the new configuration, you need to run:
systemctl restart apache2
P.S
Ubuntu20.04+Apacheのインストールエラー対策のもっと高い技術を身につけたいならこちら
<<関連記事>>
・rpmdbが壊れた場合の修復手順
・FortiGuardのスパムメールブロックを解除方法
・LinuxにUSB外付けHDDを接続する(NTFSフォーマットの場合要注意)
・viエディタ(vim)で「readonlyオプションが設定されています」と表示された場合
・yumコマンドがロックファイルエラーになった時の対処
- 次のページへ:LibClamAV Warning: cli_scanxz: decompress file size exceeds limits
- 前のページへ:rpmdbが壊れた場合の修復手順
- この記事の属するカテゴリ:Linuxエラー対処法へ戻る