Find the answer to your Linux question:
Results 1 to 3 of 3
I am installing web server in a remote dedicated server Fedora 3 I need to change the default document root (/var/www/html) to /hsphere/local/home (I have lot of scripts with this ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Oct 2005
    Posts
    15

    httpd.conf DocumentRoot


    I am installing web server in a remote dedicated server Fedora 3
    I need to change the default document root (/var/www/html) to /hsphere/local/home (I have lot of scripts with this root)
    It is not working for me: test Fedora pages opens instead of index.php
    This is what I did and its results

    In /etc/httpd/conf/httpd.conf
    I made these changes from default file

    #DocumentRoot "/var/www/html"
    DocumentRoot "/hsphere/local/home"

    #<Directory "/var/www/html">
    <Directory "/hsphere/local/home">
    ....
    AllowOverride All
    ...
    </Directory>

    DirectoryIndex index.php index.html index.htm index.html.var


    Both doc root have similar index.php
    When I set the default doc root, index is diplayed but
    if I set the new one Fedora's test page is opened
    Files an dirs in both roots are
    -rw-r--r-- 1 root root

    Thank you for any help

  2. #2
    Just Joined!
    Join Date
    Apr 2005
    Posts
    62
    if you have an apache user which is intented for owning www folders and file, try to as root #chown apache.apache -R /hsphere

    apache will become the owner of /hsphere and all files and folders on it..
    then see what happens next..

  3. #3
    Super Moderator Roxoff's Avatar
    Join Date
    Aug 2005
    Location
    Nottingham, England
    Posts
    3,879
    Make sure you have Directory section with this too:

    Code:
    <Directory "/hsphere/local/home">
    ...
    Order allow,deny
    ...
    </Directory>
    Linux user #126863 - see http://linuxcounter.net/

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •