LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-08-2003, 07:53 AM   #1
Sandman71
LQ Newbie
 
Registered: Jan 2002
Posts: 6

Rep: Reputation: 0
Apache path help


OK, this is driving me crazy, and hopefully someone will be able to help.

My DocumentRoot is /var/www/html
I've mounted a new disk to /var/www/html2 (as /var was getting full)

Using virtual hosts, I pointed a test subdomain to /var/www/html2, but no matter what I do I get a 403 Forbidden error.

/var/www/html2 is owned by user/group apache.
/var/www/html2/www is 777

Here is my Virtual host entry:

<VirtualHost *>
ServerName www3.somedomain.org
DocumentRoot /var/www/html2/www3
ServerAdmin sandman@somedomain.org
ErrorLog logs/www3_error.log
CustomLog logs/www3_access.log common
AddType application/x-httpd-php3 .php3
AddType application/x-httpd-php .php
</VirtualHost>

My virtual hosts hosted in /var/www/html work flawlessly.

Is it possible to have more than one DocumentRoot, or have apache recognize more than one path?
 
Old 10-08-2003, 09:18 AM   #2
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 234Reputation: 234Reputation: 234
You should be able to configure different roots when you have virtual hosts, I've got 3 domains using virtual hosts with different root paths....

What version of apache are you using?
 
Old 10-08-2003, 10:09 AM   #3
Sandman71
LQ Newbie
 
Registered: Jan 2002
Posts: 6

Original Poster
Rep: Reputation: 0
Quote:
Originally posted by trickykid
You should be able to configure different roots when you have virtual hosts, I've got 3 domains using virtual hosts with different root paths....

What version of apache are you using?
My version of Apache is 1.3.23
 
Old 10-08-2003, 11:11 AM   #4
trickykid
LQ Guru
 
Registered: Jan 2001
Posts: 24,149

Rep: Reputation: 234Reputation: 234Reputation: 234
You stated that the directory /var/www/html2 has rwxrwxrwx permissions but what about the files?

chmod 755 -R /var/www/html2/www3
 
Old 10-08-2003, 03:27 PM   #5
Sandman71
LQ Newbie
 
Registered: Jan 2002
Posts: 6

Original Poster
Rep: Reputation: 0
www3 directory is set to 777, so that's not the problem either.
 
Old 10-08-2003, 04:04 PM   #6
lenlutz
Member
 
Registered: May 2003
Location: philadelhpia pa
Posts: 92

Rep: Reputation: 15
i have a few virtual web sites running too....
im NOT sure, but, might i suggest:
<virtualhost>

other stuff..............

<Directory "/var/www/html2/www3/">
Options Indexes Includes FollowSymLinks
AllowOverride none
Order allow,deny
Allow from all
</Directory>

</virtualhost>

i DONT know, what most of this stuff means, only that it does appear to be working
 
Old 10-08-2003, 04:48 PM   #7
Sandman71
LQ Newbie
 
Registered: Jan 2002
Posts: 6

Original Poster
Rep: Reputation: 0
works with symlink

OK, this is pointing more and more to Apache not scanning or allowing /var/www/html2 mount.

I renamed the mount point and created a simlink and it works that way. It is very messy however

ln -s /mnt/otherhtml /var/www/html/html2

And changed my VirtualHost entry to point to /var/www/html/html2

So I know it's not a permissions error
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache path and kde path questions darkraider Debian 1 11-12-2005 06:07 AM
Apache 2 change www path problem MDK10.2 ewan Linux - Newbie 3 05-08-2005 05:38 AM
apache 2 named virtual servers : server path djbar Linux - Networking 0 03-21-2004 11:05 AM
Apache 2.0.40 and document path Drogo Linux - Software 11 06-27-2003 11:05 AM
Apache Document Root Path bowen Linux - General 8 11-29-2002 03:13 AM


All times are GMT -5. The time now is 08:11 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration