NtopNG Rest API
Pack Assetsβ
Templatesβ
The Centreon Pack NtopNG brings 1 host template:
- App-Monitoring-Ntopng-Restapi-custom
It brings the following Service Templates:
Service Alias | Service Template | Default | Discovery |
---|---|---|---|
Alerts | App-Monitoring-Ntopng-Restapi-Alerts | X | |
Host-Flows | App-Monitoring-Ntopng-Restapi-Host-Flows | ||
Netflow-Health | App-Monitoring-Ntopng-Restapi-Netflow-Health | X | |
Probe-Health | App-Monitoring-Ntopng-Restapi-Probe-Health | X |
Collected metrics & statusβ
- Alerts
- Host-Flows
- Netflow-Health
- Probe-Health
Metric name | Description | Unit |
---|---|---|
alerts.severity.error.count | Number of alerts with error severity | |
alerts.severity.warning.count | Number of alerts with warning severity | |
alerts.severity.info.count | Number of alerts with informational severity | |
alert status | Current alert status | |
type#alerts.type.detected.count | Number of alerts detected by type |
Metric name | Description | Unit |
---|---|---|
ipaddress#host.packets.received.persecond | Number of incoming packets per IP address | |
ipaddress#host.packets.sent.persecond | Number of outgoing packets per IP address | |
ipaddress#host.traffic.in.bitspersecond | Incoming traffic per IP address | b/s |
ipaddress#host.traffic.out.bitspersecond | Outgoing traffic per IP address | b/s |
Metric name | Description | Unit |
---|---|---|
flows.detected.count | Number of flows detected | |
flows.alerted.detected.count | Number of alerted flows detected | |
flows.alerted.percentage | Percentage of alerted flows detected | % |
packets.download.persecond | Number of incoming packets | |
packets.upload.persecond | Number of outgoing packets | |
traffic.in.bitspersecond | Incoming traffic | b/s |
traffic.out.bitspersecond | Outgoing traffic | b/s |
Metric name | Description | Unit |
---|---|---|
cpu.utilization.percentage | Average total CPU usage | |
cpu.load.percentage | System CPU load | |
memory.usage.percentage | Current memory usage | % |
alerts.dropped.persecond | Number of dropped alerts |
Prerequisitesβ
To monitor your NtopNG, the Rest API must be configured. E.g: https://www.ntop.org/guides/ntopng/api/
Setupβ
- Online License
- Offline License
- Install the Centreon package on every Centreon poller expected to monitor NtopNG RestAPI resources:
yum install centreon-plugin-Applications-Monitoring-Ntopng-Restapi
- On the Centreon Web interface, install the NtopNG RestAPI Centreon Pack on the Configuration > Monitoring Connectors Manager page.
- Install the Centreon package on every Centreon poller expected to monitor NtopNG RestAPI resources:
yum install centreon-plugin-Applications-Monitoring-Ntopng-Restapi
- Install the NtopNG RestAPI Centreon Pack RPM on the Centreon Central server:
yum install centreon-pack-applications-monitoring-ntopng-restapi
- On the Centreon Web interface, install the NtopNG RestAPI Centreon Pack on the Configuration > Monitoring Connectors Manager page.
Configurationβ
Hostβ
- Log into Centreon and add a new Host through Configuration > Hosts.
- Fill the Name, Alias & IP Address / DNS fields according to your NtopNG RestAPI server settings.
- Apply the App-Monitoring-Ntopng-Restapi-custom template to the host.
- Once the template is applied, fill in the corresponding macros. Some macros are mandatory.
Mandatory | Name | Description |
---|---|---|
X | NTOPNGAPIPORT | Port used (Default: 3000) |
X | NTOPNGAPIPROTO | Specify https if needed (default: 'http') |
X | NTOPNGAPIUSERNAME | Api username |
X | NTOPNGAPIPASSWORD | Api password |
NTOPNGAPIEXTRAOPTIONS | Any extra option you may want to add to the command (eg. a --verbose flag) |
How to check in the CLI that the configuration is OK and what are the main options for?β
Once the plugin is installed, log into your Centreon poller's CLI using the
centreon-engine user account (su - centreon-engine
) and test the plugin by
running the following command:
/usr/lib/centreon/plugins/centreon_monitoring_ntopng_restapi.pl \
--plugin=apps::monitoring::ntopng::restapi::plugin \
--mode=probe-health \
--hostname='10.0.0.1' \
--port='443' \
--proto='https' \
--api-username='my-username' \
--api-password='my-password' \
--verbose
The expected command output is shown below:
OK: cpu utilization: 2.10%, cpu load: 0.06, memory used: 11.83 %, dropped alerts: 0.00/s | 'cpu.utilization.percentage'=2.10%;;;0;100 'cpu.load.percentage'=0.06;;;0; 'memory.usage.percentage'=11.83%;;;0;100 'alerts.dropped.persecond'=0.00/s;;;0;
All available options for a given mode can be displayed by adding the
--help
parameter to the command:
/usr/lib/centreon/plugins/centreon_monitoring_ntopng_restapi.pl \
--plugin=apps::monitoring::ntopng::restapi::plugin \
--mode=probe-health \
--help
All available modes can be displayed by adding the
--list-mode
parameter to the command:
/usr/lib/centreon/plugins/centreon_monitoring_ntopng_restapi.pl \
--plugin=apps::monitoring::ntopng::restapi::plugin \
--list-mode
Troubleshootingβ
Please find the troubleshooting documentation for the API-based plugins in this chapter.