Using ncpa and nagiosxi-nagiosplugins from nagios-base

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
gdksc
Posts: 20
Joined: Fri Feb 01, 2019 9:58 am

Using ncpa and nagiosxi-nagiosplugins from nagios-base

Post by gdksc »

Hello. Looking for guidance regarding using nagiosxi-nagiosplugins with ncpa.

On a RHEL 8 monitored host, I've installed ncpa 2.4.0 from the nagios-base repo.

For ncpa, the plugins directory is located here:

Code: Select all

/usr/local/ncpa/plugins/
To get plugins on the monitored host for ncpa to use, I installed the nagiosxi-nagiosplugins RPM from the nagios-base repo.

However, for nagiosxi-nagiosplugins, the plugins are installed here:

Code: Select all

/usr/local/nagios/libexec/
I can workaround this manually, but I suspect that may be prone to future issues during upgrades, etc.

What is the best-practice for getting the nagiosxi-nagiosplugins plugins into the ncpa plugins/ directory?

Thanks.
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Using ncpa and nagiosxi-nagiosplugins from nagios-base

Post by pbroste »

Hello @gdksc

Thanks for reaching out and you are correct that it would be best to use the default 'plugins' directory so that it looks like this:
check_ncpa.py -H <ncpaserver> -t mytoken -M 'plugins/test.sh' -a "-u 'one argument' -p 'another argument'"
Move the contents of the folder to the /usr/local/ncpa/plugins/ directory and verify the group and ownership (nagios:nagios)

Thanks,
Perry
gdksc
Posts: 20
Joined: Fri Feb 01, 2019 9:58 am

Re: Using ncpa and nagiosxi-nagiosplugins from nagios-base

Post by gdksc »

Hi, @pbroste. Thanks for the reply.

To confirm, the recommended approach is to move or copy the plugins to the ncpa plugins/ directory.

And, the following approach would not be recommended, correct?

Code: Select all

# rm -rf /usr/local/ncpa/plugins/
 # ln -sf /usr/local/nagios/libexec/ /usr/local/ncpa/plugins
Thanks again.
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Using ncpa and nagiosxi-nagiosplugins from nagios-base

Post by pbroste »

Hmmm, I did not think of that but the symbolic link would probably work. Probably worth a try and if it works then you are good to go.

Thanks,
Perry
gdksc
Posts: 20
Joined: Fri Feb 01, 2019 9:58 am

Re: Using ncpa and nagiosxi-nagiosplugins from nagios-base

Post by gdksc »

Using the symbolic link seems to work, but I'm not sure of that could create future issues after ncpa updates, for example.

Based upon your experience, would you say that the most common practice is to just copy or move the plugins, as needed?

Trying to get a gauge here on best-practice.

Thanks.
User avatar
pbroste
Posts: 1288
Joined: Tue Jun 01, 2021 1:27 pm

Re: Using ncpa and nagiosxi-nagiosplugins from nagios-base

Post by pbroste »

If you are looking for best practices you are correct that we maintain the plugins in the default directories.

Thanks,
Perry
gdksc
Posts: 20
Joined: Fri Feb 01, 2019 9:58 am

Re: Using ncpa and nagiosxi-nagiosplugins from nagios-base

Post by gdksc »

Ok, thanks. That answers my question. We can close this thread.
Locked