NRPEClient
NRPE client can be used both from command line and from queries to check remote systes via NRPE as well as configure the NRPE server
Queries
A quick reference for all available queries (check commands) in the NRPEClient module.
List of commands:
A list of all available queries (check commands)
Command | Description |
---|---|
check_nrpe | Request remote information via NRPE. |
exec_nrpe | Execute remote script via NRPE. (Most likely you want nrpe_query). |
nrpe_forward | Forward the request as-is to remote host via NRPE. |
nrpe_query | Request remote information via NRPE. |
submit_nrpe | Submit information to remote host via NRPE. (Most likely you want nrpe_query). |
check_nrpe
Request remote information via NRPE.
Command-line Arguments
Option | Default Value | Description |
---|---|---|
help | N/A | Show help screen (this screen) |
help-pb | N/A | Show help screen as a protocol buffer payload |
show-default | N/A | Show default values for a given command |
help-short | N/A | Show help screen (short format). |
host | The host of the host running the server | |
port | The port of the host running the server | |
address | The address (host:port) of the host running the server | |
timeout | Number of seconds before connection times out (default=10) | |
target | Target to use (lookup connection info from config) | |
retry | Number of times ti retry a failed connection attempt (default=2) | |
retries | legacy version of retry | |
source-host | Source/sender host name (default is auto which means use the name of the actual host) | |
sender-host | Source/sender host name (default is auto which means use the name of the actual host) | |
command | The name of the command that the remote daemon should run | |
argument | Set command line arguments | |
separator | Separator to use for the batch command (default is | |
batch | Add multiple records using the separator format is: command | |
certificate | Length of payload (has to be same as on the server) | |
dh | Length of payload (has to be same as on the server) | |
certificate-key | Client certificate to use | |
certificate-format | Client certificate format | |
ca | Certificate authority | |
verify | Client certificate format | |
allowed-ciphers | Client certificate format | |
ssl | 1 | Initial an ssl handshake with the server. |
insecure | N/A | Use insecure legacy mode |
payload-length | Length of payload (has to be same as on the server) | |
buffer-length | Length of payload to/from the NRPE agent. This is a hard specific value so you have to "configure" (read recompile) your NRPE agent to use the same value for it to work. |
ssl:
Initial an ssl handshake with the server.
Default Value: 1
exec_nrpe
Execute remote script via NRPE. (Most likely you want nrpe_query).
Command-line Arguments
Option | Default Value | Description |
---|---|---|
help | N/A | Show help screen (this screen) |
help-pb | N/A | Show help screen as a protocol buffer payload |
show-default | N/A | Show default values for a given command |
help-short | N/A | Show help screen (short format). |
host | The host of the host running the server | |
port | The port of the host running the server | |
address | The address (host:port) of the host running the server | |
timeout | Number of seconds before connection times out (default=10) | |
target | Target to use (lookup connection info from config) | |
retry | Number of times ti retry a failed connection attempt (default=2) | |
retries | legacy version of retry | |
source-host | Source/sender host name (default is auto which means use the name of the actual host) | |
sender-host | Source/sender host name (default is auto which means use the name of the actual host) | |
command | The name of the command that the remote daemon should run | |
argument | Set command line arguments | |
separator | Separator to use for the batch command (default is | |
batch | Add multiple records using the separator format is: command | |
certificate | Length of payload (has to be same as on the server) | |
dh | Length of payload (has to be same as on the server) | |
certificate-key | Client certificate to use | |
certificate-format | Client certificate format | |
ca | Certificate authority | |
verify | Client certificate format | |
allowed-ciphers | Client certificate format | |
ssl | 1 | Initial an ssl handshake with the server. |
insecure | N/A | Use insecure legacy mode |
payload-length | Length of payload (has to be same as on the server) | |
buffer-length | Length of payload to/from the NRPE agent. This is a hard specific value so you have to "configure" (read recompile) your NRPE agent to use the same value for it to work. |
ssl:
Initial an ssl handshake with the server.
Default Value: 1
nrpe_forward
Forward the request as-is to remote host via NRPE.
Command-line Arguments
Option | Default Value | Description |
---|---|---|
* |
nrpe_query
Request remote information via NRPE.
Command-line Arguments
Option | Default Value | Description |
---|---|---|
help | N/A | Show help screen (this screen) |
help-pb | N/A | Show help screen as a protocol buffer payload |
show-default | N/A | Show default values for a given command |
help-short | N/A | Show help screen (short format). |
host | The host of the host running the server | |
port | The port of the host running the server | |
address | The address (host:port) of the host running the server | |
timeout | Number of seconds before connection times out (default=10) | |
target | Target to use (lookup connection info from config) | |
retry | Number of times ti retry a failed connection attempt (default=2) | |
retries | legacy version of retry | |
source-host | Source/sender host name (default is auto which means use the name of the actual host) | |
sender-host | Source/sender host name (default is auto which means use the name of the actual host) | |
command | The name of the command that the remote daemon should run | |
argument | Set command line arguments | |
separator | Separator to use for the batch command (default is | |
batch | Add multiple records using the separator format is: command | |
certificate | Length of payload (has to be same as on the server) | |
dh | Length of payload (has to be same as on the server) | |
certificate-key | Client certificate to use | |
certificate-format | Client certificate format | |
ca | Certificate authority | |
verify | Client certificate format | |
allowed-ciphers | Client certificate format | |
ssl | 1 | Initial an ssl handshake with the server. |
insecure | N/A | Use insecure legacy mode |
payload-length | Length of payload (has to be same as on the server) | |
buffer-length | Length of payload to/from the NRPE agent. This is a hard specific value so you have to "configure" (read recompile) your NRPE agent to use the same value for it to work. |
ssl:
Initial an ssl handshake with the server.
Default Value: 1
submit_nrpe
Submit information to remote host via NRPE. (Most likely you want nrpe_query).
Command-line Arguments
Option | Default Value | Description |
---|---|---|
help | N/A | Show help screen (this screen) |
help-pb | N/A | Show help screen as a protocol buffer payload |
show-default | N/A | Show default values for a given command |
help-short | N/A | Show help screen (short format). |
host | The host of the host running the server | |
port | The port of the host running the server | |
address | The address (host:port) of the host running the server | |
timeout | Number of seconds before connection times out (default=10) | |
target | Target to use (lookup connection info from config) | |
retry | Number of times ti retry a failed connection attempt (default=2) | |
retries | legacy version of retry | |
source-host | Source/sender host name (default is auto which means use the name of the actual host) | |
sender-host | Source/sender host name (default is auto which means use the name of the actual host) | |
command | The name of the command that the remote daemon should run | |
alias | Same as command | |
message | Message | |
result | Result code either a number or OK, WARN, CRIT, UNKNOWN | |
separator | Separator to use for the batch command (default is | |
batch | Add multiple records using the separator format is: command | |
certificate | Length of payload (has to be same as on the server) | |
dh | Length of payload (has to be same as on the server) | |
certificate-key | Client certificate to use | |
certificate-format | Client certificate format | |
ca | Certificate authority | |
verify | Client certificate format | |
allowed-ciphers | Client certificate format | |
ssl | 1 | Initial an ssl handshake with the server. |
insecure | N/A | Use insecure legacy mode |
payload-length | Length of payload (has to be same as on the server) | |
buffer-length | Length of payload to/from the NRPE agent. This is a hard specific value so you have to "configure" (read recompile) your NRPE agent to use the same value for it to work. |
ssl:
Initial an ssl handshake with the server.
Default Value: 1
Configuration
Path / Section | Description |
---|---|
/settings/NRPE/client | NRPE CLIENT SECTION |
/settings/NRPE/client/handlers | CLIENT HANDLER SECTION |
/settings/NRPE/client/targets | REMOTE TARGET DEFINITIONS |
NRPE CLIENT SECTION
Section for NRPE active/passive check module.
Key | Default Value | Description |
---|---|---|
channel | NRPE | CHANNEL |
# Section for NRPE active/passive check module.
[/settings/NRPE/client]
channel=NRPE
CHANNEL
The channel to listen to.
Key | Description |
---|---|
Path: | /settings/NRPE/client |
Key: | channel |
Default value: | NRPE |
Used by: | NRPEClient |
Sample:
[/settings/NRPE/client]
# CHANNEL
channel=NRPE
CLIENT HANDLER SECTION
This is a section of objects. This means that you will create objects below this point by adding sections which all look the same.
REMOTE TARGET DEFINITIONS
This is a section of objects. This means that you will create objects below this point by adding sections which all look the same.
Keys:
Key | Default Value | Description |
---|---|---|
address | TARGET ADDRESS | |
allowed ciphers | ALLOWED CIPHERS | |
ca | CA | |
certificate | SSL CERTIFICATE | |
certificate format | CERTIFICATE FORMAT | |
certificate key | SSL CERTIFICATE | |
dh | DH KEY | |
host | TARGET HOST | |
insecure | Insecure legacy mode | |
payload length | PAYLOAD LENGTH | |
port | TARGET PORT | |
retries | 3 | RETRIES |
timeout | 30 | TIMEOUT |
use ssl | ENABLE SSL ENCRYPTION | |
verify mode | VERIFY MODE |
Sample:
# An example of a REMOTE TARGET DEFINITIONS section
[/settings/NRPE/client/targets/sample]
#address=...
#allowed ciphers=...
#ca=...
#certificate=...
#certificate format=...
#certificate key=...
#dh=...
#host=...
#insecure=...
#payload length=...
#port=...
retries=3
timeout=30
#use ssl=...
#verify mode=...