Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -791,7 +791,7 @@ docs_plugin_links:
set -e; \
for CHK in $(DOC_PLUGINS); do \
echo "updating docs/checks/commands/$$CHK.md"; \
printf -- '---\ntitle: %s\ncomment: auto-generated by make docs, do not edit\n---\n\n%s is a built-in check plugin. Its documentation is in the [plugins section](../plugins/%s/).\n' "$${CHK#check_}" "$$CHK" "$$CHK" > docs/checks/commands/$$CHK.md ; \
printf -- '---\ntitle: %s\ncomment: auto-generated by make docs, do not edit\n---\n\n%s is a built-in check plugin. Its documentation is in the [plugins section](../plugins/%s/).\n' "$$CHK" "$$CHK" "$$CHK" > docs/checks/commands/$$CHK.md ; \
done

docs_check_service:
Expand Down
8 changes: 3 additions & 5 deletions docs/checks/commands/_index.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
---
title: Check Commands
title: Built-in commands
weight: 2000
---

The following build in commands are available:
This is the list of built-in check commands. Most of them are drop-in replacements for the NSClient++ equivalent.

This is the list of built-in checks. They work like check commands in NSClient++.

Each check usually has a help page which can be accessed by the `help` argument.
Each check command has a help page which can be accessed by the `help` argument.

For example:

Expand Down
64 changes: 31 additions & 33 deletions docs/checks/commands/check_connections.md
Original file line number Diff line number Diff line change
@@ -1,50 +1,20 @@
---
title: connections
title: check_connections
comment: auto-generated by make docs, do not edit
---

## check_connections
Checks the number of TCP connections.

Checks the number of tcp connections.

- [Examples](#examples)
- [Argument Defaults](#argument-defaults)
- [Attributes](#attributes)
- [Examples](#examples)

## Implementation

| Windows | Linux | FreeBSD | MacOSX |
|:------------------:|:------------------:|:-------:|:------------------:|
| :white_check_mark: | :white_check_mark: | | :white_check_mark: |

## Examples

### Default Check

check_connections
OK - total connections 60

Check only ipv6 connections:

check_connections inet=ipv6
OK - total ipv6 connections 13

### Example using NRPE and Naemon

Naemon Config

define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -n -c $ARG1$ -a $ARG2$
}

define service {
host_name testhost
service_description check_connections
use generic-service
check_command check_nrpe!check_connections!'warn=total > 500' 'crit=total > 1500'
}

## Argument Defaults

| Argument | Default Value |
Expand Down Expand Up @@ -87,3 +57,31 @@ these can be used in filters and thresholds (along with the default attributes):
| listen | total number of connections of type: listen |
| closing | total number of connections of type: closing |
| new_syn_recv | total number of connections of type: new_syn_recv |

## Examples

### Default Check

check_connections
OK - total connections 60

Check only ipv6 connections:

check_connections inet=ipv6
OK - total ipv6 connections 13

### Example using NRPE and Naemon

Naemon Config

define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -n -c $ARG1$ -a $ARG2$
}

define service {
host_name testhost
service_description check_connections
use generic-service
check_command check_nrpe!check_connections!'warn=total > 500' 'crit=total > 1500'
}
64 changes: 31 additions & 33 deletions docs/checks/commands/check_cpu.md
Original file line number Diff line number Diff line change
@@ -1,50 +1,20 @@
---
title: cpu
title: check_cpu
comment: auto-generated by make docs, do not edit
---

## check_cpu
Checks the CPU usage metrics.

Checks the cpu usage metrics.

- [Examples](#examples)
- [Argument Defaults](#argument-defaults)
- [Attributes](#attributes)
- [Examples](#examples)

## Implementation

| Windows | Linux | FreeBSD | MacOSX |
|:------------------:|:------------------:|:------------------:|:------------------:|
| :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |

## Examples

### Default Check

check_cpu
OK - CPU load is ok. |'total 5m'=13%;80;90 'total 1m'=13%;80;90 'total 5s'=13%;80;90

Checking **each core** by adding filter=none (disabling the filter):

check_cpu filter=none
OK - CPU load is ok. |'core1 5m'=13%;80;90 'core1 1m'=12%;80;90 'core1 5s'=9%;80;90...

### Example using NRPE and Naemon

Naemon Config

define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -n -c $ARG1$ -a $ARG2$
}

define service {
host_name testhost
service_description check_cpu
use generic-service
check_command check_nrpe!check_cpu!'warn=load > 80' 'crit=load > 95'
}

## Argument Defaults

| Argument | Default Value |
Expand Down Expand Up @@ -80,3 +50,31 @@ these can be used in filters and thresholds (along with the default attributes):
| kernel | Current kernel load for a given core (currently not supported) |
| load | Current load for a given core |
| time | Time frame checked |

## Examples

### Default Check

check_cpu
OK - CPU load is ok. |'total 5m'=13%;80;90 'total 1m'=13%;80;90 'total 5s'=13%;80;90

Checking **each core** by adding filter=none (disabling the filter):

check_cpu filter=none
OK - CPU load is ok. |'core1 5m'=13%;80;90 'core1 1m'=12%;80;90 'core1 5s'=9%;80;90...

### Example using NRPE and Naemon

Naemon Config

define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -n -c $ARG1$ -a $ARG2$
}

define service {
host_name testhost
service_description check_cpu
use generic-service
check_command check_nrpe!check_cpu!'warn=load > 80' 'crit=load > 95'
}
72 changes: 35 additions & 37 deletions docs/checks/commands/check_cpu_utilization.md
Original file line number Diff line number Diff line change
@@ -1,45 +1,20 @@
---
title: cpu_utilization
title: check_cpu_utilization
comment: auto-generated by make docs, do not edit
---

## check_cpu_utilization
Checks the CPU utilization metrics.

Checks the cpu utilization metrics.

- [Examples](#examples)
- [Argument Defaults](#argument-defaults)
- [Attributes](#attributes)
- [Examples](#examples)

## Implementation

| Windows | Linux | FreeBSD | MacOSX |
|:------------------:|:------------------:|:------------------:|:------------------:|
| :white_check_mark: | :white_check_mark: | :white_check_mark: | :white_check_mark: |

## Examples

### Default Check

check_cpu_utilization
OK - user: 2% - system: 1% - iowait: 0% - steal: 0% - guest: 0 - idle: 96% |'total'=3.4%;90;95;0; 'user'=2.11%;;;0;...

### Example using NRPE and Naemon

Naemon Config

define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -n -c $ARG1$ -a $ARG2$
}

define service {
host_name testhost
service_description check_cpu_utilization
use generic-service
check_command check_nrpe!check_cpu_utilization!'warn=total > 90%' 'crit=total > 95%'
}

## Argument Defaults

| Argument | Default Value |
Expand All @@ -66,12 +41,35 @@ Naemon Config

these can be used in filters and thresholds (along with the default attributes):

| Attribute | Description |
| --------- | ---------------------------------------------------- |
| total | Sum of user,system,iowait,steal and guest in percent |
| user | User cpu utilization in percent |
| system | System cpu utilization in percent |
| iowait | IOWait cpu utilization in percent |
| steal | Steal cpu utilization in percent |
| guest | Guest cpu utilization in percent |
| idle | Idle cpu utilization in percent |
| Attribute | Description |
| --------- | ------------------------------------------------------- |
| total | Sum of user, system, iowait, steal and guest in percent |
| user | User CPU utilization in percent |
| system | System CPU utilization in percent |
| iowait | IOWait CPU utilization in percent |
| steal | Steal CPU utilization in percent |
| guest | Guest CPU utilization in percent |
| idle | Idle CPU utilization in percent |

## Examples

### Default Check

check_cpu_utilization
OK - user: 2% - system: 1% - iowait: 0% - steal: 0% - guest: 0 - idle: 96% |'total'=3.4%;90;95;0; 'user'=2.11%;;;0;...

### Example using NRPE and Naemon

Naemon Config

define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -n -c $ARG1$ -a $ARG2$
}

define service {
host_name testhost
service_description check_cpu_utilization
use generic-service
check_command check_nrpe!check_cpu_utilization!'warn=total > 90%' 'crit=total > 95%'
}
2 changes: 1 addition & 1 deletion docs/checks/commands/check_dns.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: dns
title: check_dns
comment: auto-generated by make docs, do not edit
---

Expand Down
Loading
Loading