Allow Apache (on gusty) to serve pages from /home/user/public_html

Sundar Nagarajan sundar.personal at gmail.com
Tue Dec 11 19:37:45 UTC 2007


Tony Yarusso wrote:
> On Dec 8, 2007 12:33 PM, Don Don <progwihz at yahoo.com 
> <mailto:progwihz at yahoo.com>> wrote:
> 
>     Hi all,
> 
>     I am trying to enable apache to serve pages from
>     /home/user/public_html.  It currenty give a 403 error saying
>     permission denied. but pages in /var/www have no problems
>     displaying.  I've made necessay configurations in apache conf,
>     sites-enalbed etc.
> 
>     Cheers
> 
>     ------------------------------------------------------------------------
>     Looking for last minute shopping deals? Find them fast with Yahoo!
>     Search.
>     <http://us.rd.yahoo.com/evt=51734/*http://tools.search.yahoo.com/newsearch/category.php?category=shopping>
> 
>     --
>     ubuntu-users mailing list
>     ubuntu-users at lists.ubuntu.com <mailto:ubuntu-users at lists.ubuntu.com>
>     Modify settings or unsubscribe at:
>     https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
> 
> 
> Have you checked the file permissions within ~/public_html to make sure 
> that both the directory and the files are actually readable by the 
> apache user?

If you do not want or need Directory Indexes (Options +Indexes), you 
need to only make the directory EXECUTABLE and the files readable by the 
apache user. If you want Directory listings, you need to make the 
directory readable also (by the apache user).

And, as Kim pointed out, you need to enable the userdir apache module. 
You can use the following command to do that:

sudo a2enmod userdir


Sundar Nagarajan.





More information about the ubuntu-users mailing list