check_pdh

Checks PDH paths and handles wildcard expansion.

Implementation

WindowsLinuxFreeBSDmacOS
✅

Check Specific Arguments

ArgumentDescription
CounterThe fully qualified counter name
counterThe fully qualified counter name
englishUse English names regardless of system language (requires Windows Vista or higher)
expand-indexTranslate indices
hostNetwork host to search for the counter (default: localhost)
instancesExpand wildcards and fetch all instances
typeExpected value type: large or float (default: large)

Attributes

Filter Keywords

Use these attributes in filters and thresholds, along with the default attributes:

AttributeDescription
countNumber of items matching the filter. Common option for all checks.
valueThe counter value (either float or int)

Examples

Default Check

check_pdh "counter=\System\System Up Time" "warn=value < 60" "crit=value < 30" english
OK - All 1 counter values are ok |'\System\System Up Time_value'=3600;60:;30:;0

Example using check_snclient and Naemon

Naemon Config

define command{
    command_name         check_snclient
    command_line         $USER1$/check_snclient -k -p 'your-password' -u 'https://$HOSTADDRESS$:8443' $ARG1$ $ARG2$
}

define service {
    host_name            testhost
    service_description  check_pdh
    use                  generic-service
    check_command        check_snclient!check_pdh!'counter=\System\System Up Time' 'warn=value < 60' 'crit=value < 30' english
}