[Nagios-users] $HOME is not set correctly for plug-ins

2010-11-24 Thread Alexander Haas
Hi Nagios users, this is my first post. I encountered a behavior I am not able to understand. Well, I guess I did understand it, but I don't know how to counter it :) When I write a plug-in for Nagios it is executed as nagios:nagios. Yet $HOME is set to /root. My /etc/password and nagios's

[Nagios-users] No output returned from plugin

2010-11-24 Thread Alexander Haas
Hi list, it's me again :) I wrote a plug-in which does work great. It works from the shell as root, from the shell as nagios and from nagios executed as plug-in. The only problem is when there is an error returned. It does not work when i execute it from nagios as a plug-in and there is an

Re: [Nagios-users] $HOME is not set correctly for plug-ins

2010-11-24 Thread Jon Adcock
Alexander, It sounds like you are saying that you login as root, then su to nagios. If that's the case, make sure that you use su - nagios The hyphen tells su to use the environmental variables of the user that you are switching to. Without using the hyphen, it continues to use the

Re: [Nagios-users] No output returned from plugin

2010-11-24 Thread Stuart Browne
-Original Message- From: Alexander Haas [mailto:a...@geloet.de] Subject: [Nagios-users] No output returned from plugin Hi list, it's me again :) I wrote a plug-in which does work great. It works from the shell as root, from the shell as nagios and from nagios executed as

Re: [Nagios-users] $HOME is not set correctly for plug-ins

2010-11-24 Thread Alexander Haas
Hi Jon, thank you for getting back on me. Of course I did do a su - nagios for my tests. I fact all my console tests run fine. I think it's Nagois doing some kind of su in its internals which causes my plug-in to get a wrong $HOME inherited. The bad behavior only occurs when executed by the

Re: [Nagios-users] No output returned from plugin

2010-11-24 Thread Alexander Haas
Hi Stuart, you got me on that one :) The output did in fact contain a empty new line. I did not pay very much attention to this fact because my own error messages are all single lined. But in this actual case PHP clutters STDOUT with some error messages and a IMHO very disputable new line:

Re: [Nagios-users] No output returned from plugin

2010-11-24 Thread Stuart Browne
-Original Message- From: Alexander Haas [mailto:a...@geloet.de] Subject: Re: [Nagios-users] No output returned from plugin Hi Stuart, you got me on that one :) The output did in fact contain a empty new line. I did not pay very much attention to this fact because my own error

[Nagios-users] Nagios Distributed monitoring GUI

2010-11-24 Thread Harish Kasture
Hi Nagios users, We have 4 Nagios host configured which all are monitoring the same hosts(more than 300). the results from each of the 4 Nagios monitors. For example: Host : ABC.com Nag1 (IN) OK 01-21-2009 1:0:00 0d 0h 0m 0s 1/4 HTTP OK: 154 processes Nag2 (US) OK 01-21-2009

Re: [Nagios-users] Nagios Distributed monitoring amp; GUI

2010-11-24 Thread Harish
Hi Nagios users, We have 4 Nagios host configured which all are monitoring the same hosts(more than 300). We want to see the results from each of the 4 Nagios monitors in below given format or similar. For example: Host : ABC.com Nag1 (IN)OK 01-21-2009 1:0:00 0d 0h 0m 0s 1/4 HTTP

[Nagios-users] Nagios Distributed monitoring GUI

2010-11-24 Thread Harish Kasture
Hi Nagios users, We have 4 Nagios host configured which all are monitoring the same hosts(more than 300). What I want is that, the Nag1 would show not just the local Nagios result but the result from each of the 4 Nagios monitors, or at the very least a link to each result (possibly at