Knowledgebase
How to upgrade the web configuration from Apache 2.2 to Apache 2.4 ( ADM 3.0)
Posted by Quote Lin on 25 August 2017 02:34 AM
How to upgrade the web configuration from Apache 2.2 to Apache 2.4 ( ADM 3.0)
Apache 2.2 and Apache 2.4 has difference configuration .
When you upgrade to ADM 3.0, it is Apache 2.4 for web service.
Some of configuration of your available site will need to be modified .

Here are some examples of old and new ways to do the same access control.

In this example, there is no authentication and all requests are denied.

2.2 configuration:

Order deny,allow
Deny from all

2.4 configuration:

Require all denied

In this example, there is no authentication and all requests are allowed.

2.2 configuration:

Order allow,deny
Allow from all

2.4 configuration:

Require all granted

In the following example, there is no authentication and all hosts in the example.org domain are allowed access; all other hosts are denied access.

2.2 configuration:

Order Deny,Allow
Deny from all
Allow from example.org

2.4 configuration:

Require host example.org

In the following example, mixing old and new directives leads to unexpected results.

Mixing old and new directives: NOT WORKING AS EXPECTED

DocumentRoot "/var/www/html"

<Directory "/">
    AllowOverride None
    Order deny,allow
    Deny from all
</Directory>

<Location "/server-status">
    SetHandler server-status
    Require local
</Location>

access.log - GET /server-status 403 127.0.0.1
error.log - AH01797: client denied by server configuration: /var/www/html/server-status
You can refer the following URL for more information
https://httpd.apache.org/docs/trunk/upgrading.html
(0 vote(s))
This article was helpful
This article was not helpful

Comments (0)
Post a new comment
 
 
Full Name:
Email:
Comments:
Help Desk Software by Kayako Fusion