954,249 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

httpd setup problem

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!

Gavin

gavinchoi
Newbie Poster
1 post since Jul 2005
Reputation Points: 10
Solved Threads: 0
 

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

ServerName virtualservername.crap.com
DocumentRoot /pathtodocumentroot

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):
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?

Cain
Posting Whiz in Training
298 posts since Aug 2004
Reputation Points: 18
Solved Threads: 2
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: