I added a new service to Icinga 2, to monitor the uptime of the machine. So far it is working but, the default plugin check unit is in minutes. The plugin itself supports an argument, with which you can change the unit to (seconds | minutes | hours | days).
Now my question is, how can I add arguments to the service? I tried the following, without success:
Hello,
Service is the wrong place for this modification, you need to edit the related CheckCommand.
The problem is that uptime is part of the ITL (icinga template library, it’s basically default configuration provided with icinga), so i wouldn’t advise you to directly edit its definition since your modification can be erased by a future update.
So, what you can do instead is a wrapper check command, basically, define your check command uptime_custom and import uptime command in it in this way :
Hello HigH-Hawk
I am looking for this check and I was trying to implement this one, but unfortunetely its not working for me. I get the following error:
execvpe(/usr/lib64/nagios/plugins/check_uptime) failed: No such file or directory
can anyone help me where do i ge the check_uptime file?
The error message execvpe(/usr/lib64/nagios/plugins/check_uptime) failed: No such file or directory says that the file is not available, which might be due to the plugin not being installed.
But if you tell us what operating system this is on, we can surely help you installing the required plugin.
my OS System is Linux. I was lookin for the check_uptime file its not in my plugin folder, where do I get it from ? I tried so many different uptime plugins but can’t find a working one. So I hope the one you are using will help.