Search found 6 matches
- Wed Jul 24, 2013 4:03 pm
- Forum: Open Source Nagios Projects
- Topic: Writing a plugin
- Replies: 10
- Views: 3891
Re: Writing a plugin
Thanks for the replies and advice! Why are iswarning and iscritical different functions? They are both doing nearly the same thing, and they are both almost 100 lines long. You've effectively doubled the code it takes to check ranges. Perhaps think about it in terms of: def is_within_range(value, th...
- Wed Jul 24, 2013 3:41 pm
- Forum: Open Source Nagios Projects
- Topic: Writing a plugin
- Replies: 10
- Views: 3891
Re: Writing a plugin
Great idea, I'll definitely do that.yancy wrote:It would be helpful to show options if no args are run, like so:
-YancyCode: Select all
import sys if len(sys.argv)==1: parser.print_help() exit(0)
- Tue Jul 23, 2013 11:09 pm
- Forum: Open Source Nagios Projects
- Topic: Writing a plugin
- Replies: 10
- Views: 3891
Re: Writing a plugin
Thanks for looking sreinhardt! I think I have the final warning/critical threshold checks fully vetted, including the @ (inclusive) and ~ (negative infinity). I'd really appreciate if someone could take a look and run this through some tests to make sure it handles all contingencies. I ran it throug...
- Tue Jul 23, 2013 2:31 pm
- Forum: Open Source Nagios Projects
- Topic: Writing a plugin
- Replies: 10
- Views: 3891
Re: Writing a plugin
Nothing specific, I just mostly wanted another set of eyes on it to make sure I was interpreting the Nagios rules for warning/critical thresholds correctly.
- Mon Jul 22, 2013 10:50 am
- Forum: Open Source Nagios Projects
- Topic: Writing a plugin
- Replies: 10
- Views: 3891
Re: Writing a plugin
I'm trying to write this so it complies with the standard Nagios warning/critical thresholds like this: Table 4. Command line examples (snipped from Nagios documentation on writing plug-ins) Note that I do not have the "~" accounted for yet, I just want to make sure I'm on the right track....
- Sun Jul 21, 2013 10:40 pm
- Forum: Open Source Nagios Projects
- Topic: Writing a plugin
- Replies: 10
- Views: 3891
Writing a plugin
Is this the right place for help with writing a plugin? I couldn't find a forum on exchange.nagios.org, so I'll try here. I'm working on fine tuning the warning/critical threshold definition. My script is being written in Python and so far this is what I have. I'm hoping that someone can put a secon...