How to resolve error "Invalid command 'SetEnv'" in Apache2.4 Print

  • 1

By default module 'mod_env' will not be enabled in apache2.4. This will cause below error while using 'SetEnv' in htacess file.

Invalid command 'SetEnv', perhaps misspelled or defined by a module not included in the server configuration

To resolve this problem, we need to install the module 'mod_env' manually.

For easyapache4 users,

#yum install ea-apache24-mod_env.x86_64


Was this answer helpful?

« Back