Re: [Nagios-users] Auditing External Commands

2008-09-18 Thread Mikael Fridh
On Thu, Sep 18, 2008 at 10:36 PM, Ton Voon <[EMAIL PROTECTED]> wrote:
> On 18 Sep 2008, at 20:15, Laack,Jacob C wrote:
>> Is there a native way for Nagios to attach to attach the CGI user,
>> ekaj in this case, to the DISABLE_SVC_NOTIFICATIONS command in
>> either the nagios.log file or somewhere else?  Any non-native way to
>> do it?
>>
> We had this request from a customer to add into Opsview. Patch is
> here: 
> http://trac.opsview.org/browser/trunk/opsview-base/patches/nagios_store_cmd_cgi_submissions.patch
>
> This tells the CGIs to write an additional line API LOG: to the
> nagios.log file and includes the user's name.

What about adding a comment automatically for each submitted command
(attached to the actual host/service the command is for), would it be
doable?

It would be an auditing solution instead of a hack.
It would be logged automatically.
It would be viewable in the CGI UI.
Generally no need to check logs for mistakes made (unless the user is
malicious and sends another command for comment deletion).

You'd need to filter so that you don't create comments on comment
deletion commands :).

What I guess is an issue, is that all services and hosts for which
you've ever sent a command, will have comments attached, and a little
icon saying "comments exists for XXX" on the overview ...
There should be a certain comment type, probably which you could
expire or type-set from the get-go so you can determine if a comment
is actual or historical...

--
Fridh

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] check_procs in reverse

2008-09-11 Thread Mikael Fridh
On Thu, Sep 11, 2008 at 11:55 AM, Thomas Kinghorn - MWEB
<[EMAIL PROTECTED]> wrote:
> If the number of processes drops to 4, I need to flag as a warning
>
> If it drops to 2, flag as critical.

-w 5:8 -c 3:8

Note that anything above 8 will be critical. Adjust your wmax and cmax
values as appropriate.

--
Fridh

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] mysql reporting from nagios

2008-09-04 Thread Mikael Fridh
> Are there any examples, tips or resources available to writing reports that
> will access the nagios data from the database?

Replying in this cross-post as well for completeness:
Examples in: ndoutils-1.4b7/db/queries/

--
Fridh

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] Problems with NDOUtils

2008-09-03 Thread Mikael Fridh
On Wed, Sep 3, 2008 at 10:25 PM, Ronaldo A. Bueno Filho
<[EMAIL PROTECTED]> wrote:
>
> Hi people!
>
> I've installed Nagios 3.0.2 on my Debian 4. I also installed NDOUtils 1.4b7.
> The problem is related with NDOUtils. I can not populate the nagios
> database. I followed all steps and rechecked everything. According to my
> serach, probably there is a bug. (Not sure).

[...]

> [1220472069] ndomod: Error writing to data sink!  Some output may get
> lost...
> [1220472085] ndomod: Successfully reconnected to data sink!  0 items lost,
> 84 queued items to flush.
> [1220472085] ndomod: Successfully flushed 84 queued items to data sink.
> [1220472085] ndomod: Error writing to data sink!  Some output may get
> lost...
> [1220472101] ndomod: Successfully reconnected to data sink!  0 items lost,
> 80 queued items to flush.
> [1220472101] ndomod: Successfully flushed 80 queued items to data sink.
> [1220472101] ndomod: Error writing to data sink!  Some output may get
> lost...
> [1220472117] ndomod: Successfully reconnected to data sink!  0 items lost,
> 80 queued items to flush.
> [1220472117] ndomod: Successfully flushed 80 queued items to data sink.
> [1220472117] ndomod: Error writing to data sink!  Some output may get
> lost...
>

Check the permissions/ownership on your ndo configuration files, I'd
created an rpm the other day with too strict permissions on these
files that made ndo unable to read them. It doesn't really alert you
about it, it just goes along with default values.

--
Fridh

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] nrpe and check_mailq

2008-08-22 Thread Mikael Fridh
On Fri, Aug 22, 2008 at 7:36 PM, Kevin Freels <[EMAIL PROTECTED]> wrote:
> Greetings!
>
> I'm having an odd issue with check_mailq and nrpe. When I run the
> check_mailq command natively (i.e., on the client), I get the proper
> response:
>
> testhost:/usr/local/nagios/libexec # ./check_mailq  -w 300 -c 500
> OK: mailq (01) is below threshold (300/500) | mailq = 01

You're root here, right?

> But if I run it remotely from the server:
>
> nagios# ./check_nrpe -H testhost -c check_mailq
>  | mailq =

If I remember correctly, you need to be root to run mailq on most
systems so you might need to give the nrpe user sudo access for it.

--
Fridh

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] event handler notification

2008-08-22 Thread Mikael Fridh
On Fri, Aug 22, 2008 at 6:02 PM, Marc Powell <[EMAIL PROTECTED]> wrote:
>
> On Aug 22, 2008, at 6:48 AM, Jordi Prats wrote:
>
>> Hi all,
>> I've found no way to send a notification if a event handler is
>> triggered. Is it possible?
>
> Please expand. The question above can be interpreted several ways.
> There's no reason I am aware of that a normal notification wouldn't go
> out if event handlers were enabled. If you want a notification that
> the event handler itself fired, your event handler would have to do
> that.

Apologies Marc, for my erroneous reply to you.

Jordi: An Event Handler can execute any command, so just define a command
that executes your normal notification script.
The official Nagios documentation should contain enough info.

--
Fridh

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] Acknowledge: manual removal only ?

2008-08-20 Thread Mikael Fridh
On Wed, Aug 20, 2008 at 1:56 PM, Thomas Guyot-Sionnest <[EMAIL PROTECTED]> 
wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
>
> On 20/08/08 04:47 AM, Mikael Fridh wrote:
>> On Wed, Aug 20, 2008 at 9:46 AM, Marcus <[EMAIL PROTECTED]> wrote:
>>>
>>>
>>> How about integrating a trouble-ticket, so no catastrophes are missed
>>> anymore?
>>
>> I'm thinking if you're the one deciding when the service is OK or not,
>> and not Nagios:
>> ACK + disable active checks until you're done.
>>
>> That way there would be no flapping of the service, it will be
>> considered and logged as DOWN until you decide it's working.
>
> Personally I prefer disabling notifications, so I can still see state
> changes going on. I don't have flapping detection enabled neither.

Yes, it's up to personal or site preference.

> Another method is using scheduled downtimes; that way you can't forget
> to re-enable the service.

A problem could be it would then count as just that in the statistics
- scheduled downtime, which it is not.

--
Fridh

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] ndoutils Query optimisation

2008-08-20 Thread Mikael Fridh
On Wed, Aug 20, 2008 at 8:46 PM, Alan Cooper <[EMAIL PROTECTED]> wrote:
> Thanks for the replies,
>
> Unfortunately, all the tables are already indexed so I'm back to the
> underlying problem is that there are so many joins on big tables so
> MySQL has to copy to temp tables each time - I'd really like to
> eliminate the need for this if possible.

Show the EXPLAIN output as well as SHOW CREATE TABLE for all tables in
your query.

--
Fridh

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] Acknowledge: manual removal only ?

2008-08-20 Thread Mikael Fridh
On Wed, Aug 20, 2008 at 9:46 AM, Marcus <[EMAIL PROTECTED]> wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA1
>
> Ernst Heiri schrieb:
>
>> Question:
>> Is there a possibility to prevent the automatic removal of the
>> acknowledge if the host or service recovers?
>
> Isn't there a "Persistent Comment" box to flag which should prevent the
> ack from automatically disapearing?
> Cite:
> "If you would like the service comment to remain once the
> acknowledgement is removed, check the 'Persistent Comment' checkbox."
>
> So if the box recovers and fails again, then another admin sees: Ah,
> first admin is already at it, there is a comment from 30 minutes ago...
>
>
> How about integrating a trouble-ticket, so no catastrophes are missed
> anymore?

I'm thinking if you're the one deciding when the service is OK or not,
and not Nagios:
ACK + disable active checks until you're done.

That way there would be no flapping of the service, it will be
considered and logged as DOWN until you decide it's working.

--
Fridh

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] Nagios 3.x rpms?

2008-08-18 Thread Mikael Fridh
On Mon, Aug 18, 2008 at 4:24 PM, Assaf Flatto <[EMAIL PROTECTED]> wrote:
> Mandriva has rpms for nagios 3.x
> you can try getting the src or just hope they will work directly.
>

Here's a 3.x I made based on rpmforge's 2.x iirc...
Note that the selinux package is just bogus at the moment.

http://dasen.se/software/nagios/

files:
nagios-3.0.3-1.its.el5.i386.rpm
nagios-3.0.3-1.its.el5.src.rpm
nagios-devel-3.0.3-1.its.el5.i386.rpm
nagios-selinux-3.0.3-1.its.el5.i386.rpm

Regards,
--
Mike

-
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
___
Nagios-users mailing list
Nagios-users@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


Re: [Nagios-users] Dummy objects?!?!?

2008-06-13 Thread Mikael Fridh
On 6/12/08, mirko stefanelli <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> I need to add, if can be possible, some dummy object in status map.
> how can I add some object that are only container object (without
> ipaddress).

Add a host and a dummy host_check command that always return OK. Set
notifications_enabled 0.

Something like that should do it.

--
Fridh

-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
___
Nagios-users mailing list
Nagios-users@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