Help - Search - Members - Calendar
Full Version: Gentoo Apache problem [solved]
MandrivaUsers.org > Advanced Topics > Other Linux and Unix Distributions
mystified
I have nut, my ups monitor set up so I can access it via localhost/nut. My Document root setting is /var/www/localhost/htdocs
inside this I have forum, which is my test copy of the board and nut. But when I try to access localhost/nut I get access denied. I don't understand why it works for forum and not for nut.

I also have cgi set in httpd.conf because nut uses cgi-bin.

Any suggestions?
Leo
Are you accessing nut as an alias through apache or is nut in your document root?
mystified
My document root is /var/www/localhost/htdocs/
Which contains nut and forum
Leo
Apologies, I should have read your original post better.

Another silly question: have you checked that your permissions are all OK for nut (are you running any other security that could be preventing apache from serving nut)?
mystified
I don't have anything that I know of that would be causing problems.

I have cgi-bin in apache.

These are my permissions:
CODE
localhost log # ls -l /var/www/localhost/cgi-bin/nut
total 629
-rwxr-xr-x 1 root root 530156 May 11 16:18 htsearch
-rwxr-xr-x 1 root root    268 May 11 16:18 printenv
-rwxr-xr-x 1 root root    757 May 11 16:18 test-cgi
-rwxr-xr-x 1 root root  29120 Jun  1 16:27 upsimage.cgi
-rwxr-xr-x 1 root root  33024 Jun  1 16:27 upsset.cgi
-rwxr-xr-x 1 root root  32064 Jun  1 16:28 upsstats.cgi
localhost log # ls -l /var/www/localhost/htdocs/nut
total 16
-rwxr-xr-x 1 root root   62 May 11 16:13 bottom.html
-rwxr-xr-x 1 root root  623 May 11 16:14 header.html
-rwxr-xr-x 1 root root  503 May 11 16:14 index.html
-rwxr-xr-x 1 root root 2750 May 11 16:14 nut-banner.png

apache error_log says
CODE
[Sat Jun 02 10:51:39 2007] [error] [client 127.0.0.1] Directory index forbidden by rule: /var/www/localhost/htdocs/nut/


I haven't found anything in htdocs or nut that would interfere.
Mhn
What if you go to localhost/nut/index.html ?
mystified
Well it opens but I think I have an .htaccess problem.
When I click on Statistics I get cannot open /etc/hosts.conf. When I click on settings I get: Error: Can't open upsset.conf to verify security settings.
Refusing to start until this is fixed.

I have .htaccess in cgi-bin with the following:
<Files upsset.cgi>
deny from all
allow from 127.0.0.1
</Files>



In /etc/hosts.conf I have:
MONITOR belkin@localhost "Local UPS"



I also added this to httpd.conf. But I think I'm missing something somewhere.
According to a nut developer you need this to secure your ups.
mystified
Solved. I got help on the Gentoo forum. It was a variety of problems. Why they occured I don't know. Thanks.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.