Page 1 of 1
CPU load monitor for remote host
Posted: Tue Oct 26, 2021 4:44 am
by preethu.d
Hi Team,
I want to monitor CPU load on a remote host (linux server) which is added in Nagios via NCPA. I used check_local_load (attached the screenshot)but it is fetching data from Nagios server not from remote host. How can I monitor CPU load on remote host ?
Regards,
Preethu
Re: CPU load monitor for remote host
Posted: Tue Oct 26, 2021 3:55 pm
by benjaminsmith
Hi,
The default API in NCPA does not include a load check but it does have a check for CPU usage. Please let me know if that would be sufficient.
See:
NCPA CPU module
Otherwise, you can install the nagios plugins ( with check_load ) locally on the remote host and use the Plugin endpoint to setup load checks.
See:
Nagios XI - Using Scripts / Plugins With NCPA |
Nagios Plugins
Let me know if you need help with that process.
--Benjamin
Re: CPU load monitor for remote host
Posted: Wed Oct 27, 2021 8:59 am
by preethu.d
Hi Benjamin,
yes, can you please share the steps on how to monitor CPU load on remote host using plugin.
Regards,
Preethu
Re: CPU load monitor for remote host
Posted: Wed Oct 27, 2021 5:10 pm
by benjaminsmith
Hi Preethu,
So you'll want to follow the instructions below to install the nagios plugins on the remote system. If you do not want to install all of the plugins, do not run
make install, but copy over the check_load plugin to your ncpa plugin directory after running make. However, it will be easiest to follow the instructions and install the entire set.
https://support.nagios.com/kb/article/n ... e-569.html
Once you have the plugins installed, open up the following file:
...and set the plugin path to the correct directory.
Code: Select all
[plugin directives]
#
# Plugin path where all plugins will be ran from.
#
plugin_path = /usr/local/nagios/libexec
Restart the NCPA listener.
Then log into Nagios XI and run the NCPA Configuration Wizard. Select the plugin from the GUI on the second step.
ncpa-plugin.png
Please note the plugin syntax, it should be as follows.
Code: Select all
/usr/local/nagios/libexec/check_ncpa.py -H 192.168.XX.XX -t 'mytoken' -P 5693 -M 'plugins/check_load' -q 'args=-w "2,2,2" -c "5,4,4"'
Let us know if you need further assistance
--Benjamin
Re: CPU load monitor for remote host
Posted: Thu Nov 11, 2021 5:33 am
by preethu.d
Hi Benjamin,
It is working, thank you for the help. You can close the thread.
Regards,
Preethu