check_pdh
Checks PDH paths and handles wildcard expansion.
Implementation
| Windows | Linux | FreeBSD | MacOSX |
|---|---|---|---|
| ✅ |
Check Specific Arguments
| Argument | Description |
|---|---|
| Counter | The fully qualified counter name |
| counter | The fully qualified counter name |
| english | Use English names regardless of system language (requires Windows Vista or higher) |
| expand-index | Should indices be translated? |
| host | The name of the machine in the network where the counter should be searched, defaults to localhost |
| instances | Expand wildcards and fetch all instances |
| type | This can be large or float depending on what you expect, default is large |
Attributes
Filter Keywords
these can be used in filters and thresholds (along with the default attributes):
| Attribute | Description |
|---|---|
| count | Number of items matching the filter. Common option for all checks. |
| value | The 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
}