Apache 1.3 + Nagios CGI = failure

Andreas Ericsson ae at op5.se
Fri Nov 4 15:32:30 CET 2005


lukasz szmit wrote:
> ----- Original Message -----
> From: Andreas Ericsson <ae at op5.se>
> Date: Thursday, November 3, 2005 8:42 pm
> Subject: Re: [Nagios-users] Apache 1.3 + Nagios CGI = failure
> 
> 
>>Lukasz Szmit wrote:
>>
>>>On Thu, 2005-11-03 at 13:07 -0200, Marcel Mitsuto Fucatu Sugano 
>>
>>wrote:> 
>>
>>>>On Thu, 2005-11-03 at 14:42 +0000, Lukasz Szmit wrote:
>>>>
>>>>
>>>>>[Thu Nov  3 14:13:26 2005] [error] (13)Permission denied: exec
>>>>>of /usr/nagios/sbin/tac.cgi failed
>>>>>[Thu Nov  3 14:13:26 2005] [error] [client x.y.z.a] malformed 
>>
>>header>>>from script. Bad
>>
>>>>>header=Launching... /usr/lib/apache-s: /usr/nagios/sbin/tac.cgi
>>>>
>>>>Let me guess, apache runs as user nobody and group nobody?
>>>>You should make the owner or group of the apache process access the
>>>>CGIs. It is all documented, on configuring web-interface.
>>>
>>>
>>>No, it isn't. Debian default is www-data (both user and group).
>>>Changing the group on /usr/nagios (recursively) to www-data 
>>
>>doesn't make
>>
>>>a difference - I still get exactly the same error. 
>>>For some strange reason if I copy e.g. tac.cgi to the server
>>>default /cgi-bin directory (Debian default for that
>>>is /usr/lib/cgi-bin), which is owned by user:group root and has
>>>permissions set to 755 - Apache is a happy camper and runs the 
>>
>>script. 
>>
>>>I have even double-checked if /usr is by any chance mounted with 
>>
>>noexec,> which it isn't. 
>>
>>It's SELinux related. Browse the archives. The correct solution has 
>>been 
>>given many times.
> 
> 
> Fine, but the problem is that my kernel is compiled without selinux support.
> 

Oh. And here I was thinking you'd checked that the webuser has regular 
unix access to execute the cgi-files. Apparently you didn't, although 
the log shouts it out loud and clear.

Hint; The permission denied can be from any of the directories above 
where the files are stored. The apache user needs +x on every directory 
along the way.

> regards,



-- 
Andreas Ericsson                   andreas.ericsson at op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231


-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP.  Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list