Thread: 403 error after changing apache2 document root
hi folks, time.
decided change apache document root /var/www home folder, /home/blair/www
followed video tutorial: youtube.com/watch?v=qw95e7ewzew
created new www directory in /home/blair, , modified /etc/apache2/sites-available/default:
as can see modified the fourth line down /var/www /home/blair/www<virtualhost *:80>
serveradmin webmaster@localhost
documentroot /home/blair/www
<directory />
options followsymlinks
allowoverride none
</directory>
<directory /var/www/>
options indexes followsymlinks multiviews
allowoverride none
order allow,deny
allow all
</directory>
scriptalias /cgi-bin/ /usr/lib/cgi-bin/
<directory "/usr/lib/cgi-bin">
allowoverride none
options +execcgi -multiviews +symlinksifownermatch
order allow,deny
allow all
</directory>
errorlog ${apache_log_dir}/error.log
# possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
loglevel warn
customlog ${apache_log_dir}/access.log combined
alias /doc/ "/usr/share/doc/"
<directory "/usr/share/doc/">
options indexes multiviews followsymlinks
allowoverride none
order deny,allow
deny all
allow 127.0.0.0/255.0.0.0 ::1/128
</directory>
</virtualhost>
then, restarted apache running sudo /etc/init.d/apache2 restart
now, when point browser http://localhost, 403 forbidden error.
might way off, i'm speculating might apache2 not have permission access new www folder. if case, how can grant such access?
again!
my document root owned www-data. so:
chmod www-data:www-data <dir>
long files in directory world-readable, things should ok.
steve.
Forum The Ubuntu Forum Community Ubuntu Official Flavours Support General Help [ubuntu] 403 error after changing apache2 document root
Ubuntu
Comments
Post a Comment