Click to See Complete Forum and Search --> : 403 Forbidden Error - Apache 2.0.53 - site will not render


GulfStream
04-07-2006, 10:21 AM
I have a few web sites configured on my server, yet one of them will not render cleanly and to the best of my knowledge and reseach, the settings are the same. I did not set up the sites that are working (the guy who did left to company and left no documentation, of course). So, perhaps I am missing a simple setting or .conf entry.


Details:
Fedora Core 4.
Apache 2.0.53

Using VirtualHost enties in httpd.conf.

<VirtualHost *:80>
ServerAdmin webmaster@centerpointnetworks.net
ServerName www2.reicinpollack.com
DocumentRoot "/home/rpco/web"
</VirtualHost>

here is the ls -l for the doc root.
-rw-r--r-- 1 rpco rpco 10614 Mar 31 14:19 5_methods_tax.html
-rw-r--r-- 1 rpco rpco 10945 Mar 31 14:19 about-us.html
-rw-r--r-- 1 rpco rpco 10677 Mar 31 14:19 accounting-and-auditing.html
-rw-r--r-- 1 rpco rpco 43870 Mar 31 14:19 associates.html
-rw-r--r-- 1 rpco rpco 19669 Mar 31 14:19 careers.html
-rw-r--r-- 1 rpco rpco 16016 Mar 31 14:19 contact2.html
-rw-r--r-- 1 rpco rpco 15121 Mar 31 14:19 contact.html
-rw-r--r-- 1 rpco rpco 1278 Mar 31 14:19 financial_tools_head.html
-rw-r--r-- 1 rpco rpco 1485 Mar 31 14:19 financial_tools.html
-rw-r--r-- 1 rpco rpco 1327 Mar 31 14:19 financial_tools_ORIG.html
drwxr-xr-x 3 rpco rpco 12288 Mar 31 14:27 images
-rw-r--r-- 1 rpco rpco 10129 Mar 31 14:30 index2.html
-rw-r--r-- 1 rpco rpco 9033 Mar 31 14:30 index3.html
-rw-r--r-- 1 rpco rpco 9992 Mar 31 14:30 index.html
-rw-r--r-- 1 rpco rpco 1268 Mar 31 14:30 info_center_head.html
-rw-r--r-- 1 rpco rpco 1501 Mar 31 14:30 info_center.html
-rw-r--r-- 1 rpco rpco 1315 Mar 31 14:30 info_center_ORIG.html
-rw-r--r-- 1 rpco rpco 10350 Mar 31 14:30 labor-services.html
-rw-r--r-- 1 rpco rpco 15427 Mar 31 14:30 nav.html
-rw-r--r-- 1 rpco rpco 1265 Mar 31 14:30 newsletter_head.html
-rw-r--r-- 1 rpco rpco 1472 Mar 31 14:30 newsletter.html
-rw-r--r-- 1 rpco rpco 1328 Mar 31 14:30 newsletter_ORIG.html
-rw-r--r-- 1 rpco rpco 19520 Mar 31 14:30 partners.html
-rw-r--r-- 1 rpco rpco 2510 Mar 31 14:30 postinfo.html
-rw-r--r-- 1 rpco rpco 9714 Mar 31 14:30 services.html
-rw-r--r-- 1 rpco rpco 10514 Mar 31 14:30 special_services.html
-rw-r--r-- 1 rpco rpco 9448 Mar 31 14:30 special-services.html
-rw-r--r-- 1 rpco rpco 3024 Mar 31 14:30 submit.html
-rw-r--r-- 1 rpco rpco 12095 Mar 31 14:30 tax-planning-compliance.html
-rw-r--r-- 1 rpco rpco 5521 Mar 31 14:30 tax-saving-strategies.html
-rw-r--r-- 1 rpco rpco 7981 Mar 31 14:30 tax-saving-strategies-nav.html
-rw-r--r-- 1 rpco rpco 13268 Mar 31 14:30 testimonials.html

Any insight or help would be appreacited. Thanks.

knute
04-07-2006, 12:25 PM
Are there any dotfiles at all?

ls -a would show you if there are any there.

Take a peek into one site that IS working and see if there are any hidden files that would tell apache that access to the WWW (or whatever) directory is ok.

HTH

GulfStream
04-07-2006, 12:42 PM
as it turns out there is a .htaccess and an .htaccess.move file in the www dir for the site that it working, yet these files do not exist in the docroot for the site that will not rended. I am not sure why there files do, but I will start there. Does this shed any light on the issue from your vantage point?

knute
04-07-2006, 12:45 PM
Yeah. Actually it does.

Are the .htaccess and .htaccess.move files blank?

If so, then in the www directory of the site that's not working issue:
touch .htaccess
touch .htaccess.move

and try looking at the site again. :)

GulfStream
04-07-2006, 12:49 PM
For the site that is working, the files look al most the same. here is the content from one of them:
# -FrontPage-

IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

<Limit GET POST>
order deny,allow
deny from all
allow from all
</Limit>
<Limit PUT DELETE>
order deny,allow
deny from all
</Limit>
AuthName mmm14
AuthUserFile /u/web/freibr/_vti_pvt/service.pwd
AuthGroupFile /u/web/freibr/_vti_pvt/service.grp


I will try the code you noted and repost as needed. Thanks a million

GulfStream
04-07-2006, 04:05 PM
I issues the two touch lines of code, restarted the httpd service, but still no dice. Also, as you likey know, the .htaccess and htaccess.move files are empty in www dir for the site that will not work. The site that is woking contains the infor that I posted in my prior reply. Any thoughts? - and, again, thanks.

knute
04-07-2006, 04:33 PM
http://httpd.apache.org/docs/1.3/howto/htaccess.html

Google search terms: apache htaccess

HTH

GulfStream
04-10-2006, 07:55 PM
I swear that I have read dozens of aricles on this topic and connot for the life of me figure out what I have wrong. Is there a <diretory> command that I can place in my httpd.conf file that would open this entrire directory up for the purpose of testing and debugging. At this point I am going nuts. thanks

knute
04-10-2006, 08:53 PM
Ok, then, why not copy the .htaccess file from one of the sites that DOES work, and compare that file with another one that does work and then make the appropriate changes for your site that doesn't work.

GulfStream
04-13-2006, 07:49 PM
OK, so I copied the .htaccess files over, restarted httpd, but no dice. here is something that is interesting and might shed some light. when I issue locate .htaccess if finds it in many locations including the direcroty for the site that works, but not within the site that I copied the file to. I cannot reconsile why this is the case. Any thoughts. PS. I issued chmod -R 755 /home/rpco/web/ which is the dir that holds the sites content, but still no dice

bwkaz
04-13-2006, 08:09 PM
It doesn't show the right files because locate doesn't actually search your filesystems. It only searches its own database, which is not automatically kept in sync with the filesystems.

To re-sync the database with the filesystem, run "updatedb". To forget about the database and just search the filesystem, use the "find" program. (I'd probably do something like find / -xdev -name '.htaccess' myself, but depending on your partitioning scheme, you might have to include more paths than just the root directory. You have to use -xdev because you don't want find searching through /proc, /sys, or /dev. Those are RAM-based FSes that don't include real files anyway -- well, except perhaps /dev, but in this case the file you want definitely won't be in there either. But since -xdev will make it stay on the root filesystem, if you have another partition mounted somewhere that you want to search, you'll have to include that partition's mount point in the find command in addition to "/".)

Note that running updatedb takes about as long as running find, so if you're only looking for one file, find should be quicker. (Because you won't have to wait for updatedb, and then still have to run locate.)

GulfStream
04-13-2006, 08:20 PM
Thank you for the input. The hardest part of this process is not knowing what in the heck I am doing. Coming from NT/IIS (with all of its flaws) at least I know where to look and how to debug a problem. At this point I feel like the blind leading the naked – But I will get there in time.

At this point, however, I would like to get this matter wrapped up. I searched the web for “per incident apache support” and was planning on calling a few of the companies that looked reasonable. Do you have any recommendations? This of course presumes that you do not know anything else that I can try.

knute
04-13-2006, 08:35 PM
ROFLMAO

Try this:

Change:
<VirtualHost *:80>
ServerAdmin webmaster@centerpointnetworks.net
ServerName www2.reicinpollack.com
DocumentRoot "/home/rpco/web"
</VirtualHost>

To:
<VirtualHost *:80>
ServerAdmin webmaster@centerpointnetworks.net
ServerName www2.reicinpollack.com
DocumentRoot /home/rpco/web
</VirtualHost>

GulfStream
04-13-2006, 08:48 PM
Thanks for the feedback and I am glad to see that you got a charge out of my post - even if your ROFLMAO is at my expense. Sadly, removing the quotes did not resolve the issue.
FYI --> when I update the DocumentRoot to the local of functional site it works - meaning that the other site's content renders when I target www2.reicinpollack.com. I will keep trying - other insight is appreciated. So, it clearly security related (not that that’s a shock), but I cannot see where the issue is.

knute
04-13-2006, 08:58 PM
Actually, I wasn't laughing at you. I did a search for examples, and when I found some example virtual host settings, none of them had the quotes. :D

Also, I have a backup from a webserver that I used to manage. It looks like the permissions are set for read and execute. Granted they may have changed during the copy, but......

HTH