After upgrading from apache 2.2 to 2.4 I have a strange apache config error. My vhost config file contains the following directory directive:
<Directory "C:/data/projectx/src/htdocs">  
            Options None 
            AllowOverride None
            #Order allow,deny   # old config style
            #Allow from all     # old config style
            Require all granted # new config style (replaces both rules above)
</Directory>
Which is conform with the new directive syntax. However, when I start apache I get this message, indicating some error on the Require all directive:
AH00526: Syntax error on line 22 of C:/data/projectx/src/admin/local.conf:
Argument for 'Require all' must be 'granted' or 'denied'
Obviously the error is somewhat misleading, as everything is correct. What is wrong with this directive?
Solution: remove the comment after the Require all directive:
<Directory "C:/data/projectx/src/htdocs">  
            Options None 
            AllowOverride None
            #Order allow,deny   # old config style
            #Allow from all     # old config style
            # -->> moved comment into own line: new config style ...
            Require all granted 
</Directory>
                        If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With