Client check examples

This forum was archived to /woltlab and is now in read-only mode.
  • Hi All

    Coming from Nagios to Icinga. Trying to understand how the checks work and what the parameters mean. I am looking for example service checks similar to this disk check below that works for me.

    I have almost completed the docs but I find there are not many service check examples. Is there any other resource with such ncsp examples? I am monitoring a Windows host.

    1. object Service "disk" { import "generic-service"
    2. host_name = "remote-windows-host"
    3. check_command = "nscp"
    4. vars.nscp_variable = "USEDDISKSPACE" vars.nscp_params = "c" vars.nscp_warn = 70 vars.nscp_crit = 80
    5. }
  • I am sorry, I forgot to mention, I am looking for

    1. Checks for a specific service

    2. CPU Usage

    3. Uptime


    Any online resource that anyone knows of, please point me and I will go read. Thanks.

  • Well, many hours of reading later I am getting the hang of this but I am having a little problem with the uptime check. The correct values show up in icingaweb2. I want it to warn me when the uptime is less than 1 hour and when it is more than 80 days. I am not getting any warnings though when I reboot the server and the uptime is less than 1 hour. I enabled debugging on the server and the commange looks ok. This is my check below:

    object Service "Uptime" {

    import "generic-service"

    host_name = "server_name"

    check_command = "nscp"

    vars.nscp_password = "password"

    vars.nscp_variable = "UPTIME"

    vars.nscp_params = "days"

    vars.nscp_maxcrit = 80d

    vars.nscp_mincrit = 1h


    Any ideas why this doesn't work as expected?

  • vars.nscp_maxcrit = 80d

    vars.nscp_mincrit = 1h

    these parameters are not available in icinga2

    there are only the Parameters warn and crit allowed.

    vars.nscp_warning = 1h

    vars.nscp_critical = 80d

    I would do this with nrpe:


    1. apply Service "Uptime" {
    2. import "win-std"
    3. check_command = "nrpe"
    4. vars.nrpe_version_2 = true
    5. vars.nrpe_command = "check_uptime"
    6. vars.nrpe_arguments = [ "crit=uptime >80d or uptime <1h" ]
    7. assign where host.vars.os == "Windows"
    8. }