Re: [Nagios-devel] [Nagios-users] "distributable" downtime delete

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
Guest

Re: [Nagios-devel] [Nagios-users] "distributable" downtime delete

Post by Guest »

On 02/08/2013 04:32 AM, Páll Guðjón Sigurðsson wrote:
> Thanks a lot Paul,
>
> We have been achieving the same goals with pynag scripts and
> DEL_SVC_DOWNTIME command.
>
> Is there anyone on the list that might take it into their hands to
> keep documentation up to date, maybe even write a routine in nagios
> to ask for every supported external command, so that external scripts
> know what external commands are supported ?
>

It wouldn't be hard to build a command query-handler in Nagios that
can list the available commands, along with a short description saying
what it does. The same could be used with macros and other things we
already have pre-compiled lists of.

I've been meaning to write one that can handle external commands from
users and reply with a result code to let people know how it actually
went parsing, understanding and applying it anyway, so it'll get done
eventually. Right now I'm working on something different though.

> The pynag team depends on the documentation to generate library
> functions, but we have found a few glitches in both external commands
> docs and the nagios.cfg docs. Anyone willing to help us on "getting
> it right" deserves a beer.
>

Use the code instead. The external commands are all listed in
include/common.h, so

sed -n 's/^#define CMD_\([A-Z_]*\).*/\1/p'

will list all of them (although some of them are disabled internally,
so you'll have to keep a list of those).

--
Andreas Ericsson [email protected]
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231

Considering the successes of the wars on alcohol, poverty, drugs and
terror, I think we should give some serious thought to declaring war
on peace.





This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
Locked