Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

apache2 not reading DocumentRoot

  • 03-06-2005 10:48AM
    #1
    Closed Accounts Posts: 2,485 ✭✭✭


    When starting apache I get the following message:
    Stopping httpd: [ OK ]
    Starting httpd: Warning: DocumentRoot [/home/auctrev/public_html] does not exist
    [FAILED]
    I'm trying to set up several sites and get apache to read documents from their respective /home/*/public_html folders.
    IIRC the permissions are set correctly:
    [root@naom home]# ls -l
    total 72
    drwxr-xr-x 3 auctrev auctrev 4096 Jun 2 11:31 auctrev
    [root@naom auctrev]# ls -la
    total 76
    drwxr-xr-x 3 auctrev auctrev 4096 Jun 2 11:31 .
    drwxr-xr-x 11 root root 4096 Jun 1 17:10 ..
    drwxrwxrwx 23 auctrev auctrev 4096 Jun 2 13:00 public_html
    lrwxrwxrwx 1 root root 26 Jun 2 11:31 www -> /home/auctrev/public_html/

    Here is the relevant part of httpd.conf (that I know of anyway):
    NameVirtualHost 192.168.50.10
    </VirtualHost>

    <VirtualHost 192.168.50.10>
    #BytesLog domlogs/dc2-web31-bytes_log
    ServerName naom.mydomain.ie
    DocumentRoot /var/www/html
    </VirtualHost>

    <VirtualHost 192.168.50.10>
    ServerAlias www.mydomain.com mydomain.com
    ServerAdmin webmaster@mydomain.com
    DocumentRoot /home/auctrev/public_html
    ServerName www.mydomain.com
    CustomLog domlogs/mydomain.com combined
    ScriptAlias /cgi-bin/ /home/auctrev/public_html/cgi-bin/
    <Directory /home/auctrev/public_html/>
    Options All MultiViews

    AllowOverride All

    Order allow,deny
    Allow from all
    </Directory>
    </VirtualHost>


    Thanks


Comments

  • Closed Accounts Posts: 2,485 ✭✭✭sovtek


    After playing around all day it turns out that it was SELinux restrictions on Apache.
    I disabled it in /etc/sysconfig/selinux and can now server documents from users public_html directory.
    Happy Days.


  • Hosted Moderators Posts: 7,486 ✭✭✭Red Alert


    I wouldn't disable SELinux lightly - i'm installing openbsd on my firewall just so i can have systrace but i'm putting together a linux server for someone, so if i get the SELinux apache policy right i'll stick it up here!


Advertisement