AW: Strange situation..

Thomas.Zimmer at oppenheim.de Thomas.Zimmer at oppenheim.de
Thu Mar 16 10:51:05 CET 2006


Again.:) 
What are the logfile-permissions?

Thomas Zimmer
Produktservice & Betrieb
Betrieb & Support
Sal. Oppenheim jr. & Cie., Frankfurt a. Main
Telefon: +49 69 7134 5192
Internet: http://www.oppenheim.de
E-Mail: thomas.zimmer at oppenheim.de



-----Ursprüngliche Nachricht-----
Von: nagios-users-admin at lists.sourceforge.net
[mailto:nagios-users-admin at lists.sourceforge.net] Im Auftrag von Marco
Borsani
Gesendet: Donnerstag, 16. März 2006 10:30
An: 'NAGIOS'
Betreff: [Nagios-users] Strange situation..
Wichtigkeit: Hoch


Hi all!

I prepare a very simple check (called check_fax) that read a text file.

If check_fax find an "OK" it will return a status 0, if check_fax find a
"CRITICAL" it will return a status 2.

Well, when I run manually check_fax (like nagios user or root user) it work
correctly (returns 0), but when Nagios run check_fax, it returns a status 2.

I try to modify check_fax permissions like:
-rwxr-xr-x   1 root       sys            654 Mar 16 09:42 check_fax
-rwxr-xr-x   1 nagios     nagios         654 Mar 16 09:42 check_fax
But nothing has been changed.

Here it is the check_fax:
----------------------------------------------------------------------
#!/bin/csh
#
set dir2 = /tmp

set STATUS = `cat $dir2/Invio_Rice.log | grep -c OK`

if ( "$STATUS" == "1" ) then
        echo "FAX OK - Invio e ricezione di prova avvenuto" > $dir2/Rice.log
        echo "FAX OK - Invio e ricezione di prova avvenuto" else
        echo "FAX CRITICAL - Invio e ricezione di prova NON avvenuto" >
$dir2/Rice.log
        echo "FAX CRITICAL - Invio e ricezione di prova NON avvenuto"
        exit 2
endif

exit 0
------------------------------------------------------------------------

Any idea?
Regards

Marco Borsani                        
Unix & Monitoring System Administrator
Technical Operation
Tel.    +39 010 4310115
Fax     +39 010 4327454
E-mail: m.borsani at IT.net

ITnet S.r.l. - Direzione e Coordinamento di WIND Telecomunicazioni S.p.A.
Internet Service Provider
Sede legale:                     Via C.G.Viola, 48 - 00148 Roma
Dir. Centrale e Amministrativa:  	Via Pacinotti, 39
	                             16151 Genova (Italy)
                                            	
http://www.it.net                                
mailto:info at IT.net 
_______________________________________________________________
Altre sedi ITnet:
MILANO tel.: +39 02 30114900    info-milano at IT.net
ROMA    tel.: +39 06 83116707    info-roma at IT.net
_______________________________________________________________
ITnet is associated to CIX (Commercial IP eXchange) and RIPE ITnet is
associated to AIIP (Associazione Italiana Internet Providers)




-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
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

-------------- next part --------------
A non-text attachment was scrubbed...
Name: Zimmer, Thomas (Produktservices und Betrieb).vcf
Type: application/octet-stream
Size: 254 bytes
Desc: not available
URL: <https://www.monitoring-lists.org/archive/users/attachments/20060316/316f43f0/attachment.obj>


More information about the Users mailing list