Posted under » Ubuntu » Apache on 22 February 2011
To create virtual sites. All virtual sites config are called from
/etc/apache2/sites-enabled
Let's say you have 100 sites hosted on your apache. How does ubuntu decides what is the local site? Amazingly it is by alphatical order of the files that are in this folder.
To make your preferred site be the default, simply rename it to Asomething.www and not Bsomething.www
For Centos, the location is at
/etc/httpd/
Where are www files located?
By default it is at /var/www/ but if you want to have it elsewhere for perhaps archive purposes, you need to amend the /etc/apache2/apache2.conf file and go the line where "/var/www/" can be edited. Othewise, you will see this error on your logs.
client denied by server configuration: