Dear all,

I can't setup the httpd server document root other from the default.

The default setting is DocumentRoot "/var/www/html". However, when I set the default web link to DocumentRoot "/home/webadmin/public_html", the httpd service can't start and display "failed".

Can anyone help me? Thanks!


12 Years
Discussion Span
Last Post by Cain

typically you add a document root and access ( i dont ever delete the original)

then i add a virtual host (both bits are needed):

NameVirtualHost 10.1.1.x
<VirtualHost 10.1.1.x>
ServerName virtualservername.crap.com
DocumentRoot /pathtodocumentroot

<Directory /pathtodocumentroot
order allow,deny
allow from 10.1.1.
allow from .crap.com

add virtualservername.crap.com to /etc/hosts
and restart httpd. if its good,
add a reverse and a .crap.com entry to DNS

are you certain that there wasnt anything required in /var/www/html
that needs to be in /home/webadmin/public_html if youre moving it in its entirety?

is your syntax in httpd.conf correct?
did your change/add all instances of /var/www/html to match /home/webadmin/public_html ? you do need to set access to this document root
as well.. look for a string like this (as with the virtualhost above): <Directory /var/www/html>
copy it and modify it to suit your needs then allow your networks
and attempt to restart your webserver.

are you restarting httpd as the root user? if not does your user have permissions
and access rights to files or to start the webserver?

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.