plugin writing help
plugin writing help
Hey guys I am going to attempt to write my own plugin to check certain iyems on an apc pdu. Is there any docs out there that shouw how to write plugings using snmp polling?
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
-
npolovenko
- Support Tech
- Posts: 3457
- Joined: Mon May 15, 2017 5:00 pm
Re: plugin writing help
Hi, @benhank. I think we've got some plugins on the exchange that you can look at:
https://exchange.nagios.org/index.php?o ... =apc%20pdu
You might be able to find an existing plugin that does what you need.
https://exchange.nagios.org/index.php?o ... =apc%20pdu
You might be able to find an existing plugin that does what you need.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: plugin writing help
Those plugins will most likely work, But I am looking for info that will help me write my own.
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
Re: plugin writing help
Really depends on the language you wanna use. Straight-up Bash? Then any command you can run from the command line is up for grabs. Python? Perl? You'll wanna look into some of the libraries that are available to you:
Python: https://easysnmp.readthedocs.io/en/latest/
Perl: http://search.cpan.org/~dtown/Net-SNMP- ... et/SNMP.pm
Aside from the SNMP-specific stuff, the rest is just building the logic to determine thresholds and process arguments. That's a little outside the scope of what we can directly assist with, but Google is your friend here and there are plenty of guides and code samples to guide you.
Python: https://easysnmp.readthedocs.io/en/latest/
Perl: http://search.cpan.org/~dtown/Net-SNMP- ... et/SNMP.pm
Aside from the SNMP-specific stuff, the rest is just building the logic to determine thresholds and process arguments. That's a little outside the scope of what we can directly assist with, but Google is your friend here and there are plenty of guides and code samples to guide you.
Former Nagios employee
Re: plugin writing help
yeah I was thinking bash. you can lock this one.
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion