Yes you have read the correct word that we can increase the Site performace with AllowOverride.
We can increase our site performace by enabeling the AllowOverride ro only required directories.
This is how it works.
If AllowOverride is enabled for whole site then server must have to check for the .htaccess file in all directories your site have. Really server will check for all directories which may or may not have a htaccess file.
To prevent this, We have to disable AllowOverride in the root htaccess file and enable only for the directory for which we need to enable AlloOverride from server’s config file.
Disable AllowOverride
[cc lang=”apache”]
# Increase performace with AllowOverride
AllowOverride None
[/cc]
Enable AllowOverride for Specific Directory
[cc lang=”apache”]
# enable allowoverride for specific directory
AllowOverride Options
[/cc]
Note: If you do not have access to your server’s configuration file and want to use AllowOverride then do not use this Directive.
This is a great tip and would be very useful! Thanks!
Thanks Suman..
I do not mean to be perky, but isn’t AllowOverride normally set to None by default? Regardless I am positive that setting it to None will increase performance some bit! Good tip!
No, By Default its set to All, take a look at this : http://httpd.apache.org/docs/2.0/mod/core.html#allowoverride
Let us know your thought..