Oracle Monitoring Help

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
pr0t
Posts: 2
Joined: Thu Sep 05, 2019 4:42 am

Oracle Monitoring Help

Post by pr0t »

Hello everyone,

I don't want to start a new topic as my problem regards the one described in the above post. I downloaded the official template (OVF) of Nagios XI server and deployed it on VMware ESXi server. Initial and necessary configuration has already been done (ethernet, yum update, etc.). I followed the instruction: "How To Install & Configure The Oracle Client & Plugin", but I feel that I'm missing something..

When I go to command management and want to edit check_xi_oraclequery - according to the manual - I should edit it in the following way:

/usr/bin/env LD_LIBRARY_PATH=/usr/lib/oracle/19.3/client64/lib ORACLE_HOME=/usr/lib/oracle/19.3/client && $USER1$/check_oracle_health $ARG1$

a. LD_LIBRARY_PATH and ORACLE_HOME are Nagios server local paths, right? Based on other article I found, $USER1 is a user-defined macro which in this case is the following path: /usr/local/nagios/libexec/

b. As for $ARG1$ - should I follow man for check_oracle_health and customize it or this is also a pre-defined macro?

c. I'm a little bit confused when it comes the packages I should install on the servers I want to monitor - I already created nagios user, generated ssh keys and added public one to authorized_keys file, I followed the instruction I mentioned above, but I still don't know what should be done there on the Oracle server - should I also download and install plugins on the Oracle server?

d. As for the above command (the one which is in bold) - how does it work exactly?

I've found Nagios very interesting and read a lot about it, but I'll need a helping hand to better understand its idea. Thank you for any tips in advance!
User avatar
mbellerue
Posts: 1403
Joined: Fri Jul 12, 2019 11:10 am

Re: Oracle Monitoring Help

Post by mbellerue »

Hey pr0t,
I don't want to start a new topic as my problem regards the one described in the above post.
In any other forum, this would probably be the way to go. But here we like to keep the problems tied to a single user, and if multiple people are having the same problem, we'll type the answer up twice. But it's all good, I just spun your post off to its own thread.

Now, to keep you on your toes, let's answer your last question first.
/usr/bin/env LD_LIBRARY_PATH=/usr/lib/oracle/19.3/client64/lib ORACLE_HOME=/usr/lib/oracle/19.3/client && $USER1$/check_oracle_health $ARG1$
...
d. As for the above command (the one which is in bold) - how does it work exactly?
What's happening with the command is that you're adding an Oracle library path to LD_LIBRARY_PATH, and setting ORACLE_HOME prior to the actual check executing. This way when the check executes, it has access to everything in those directories.
a. LD_LIBRARY_PATH and ORACLE_HOME are Nagios server local paths, right? Based on other article I found, $USER1 is a user-defined macro which in this case is the following path: /usr/local/nagios/libexec/
This is all correct.
b. As for $ARG1$ - should I follow man for check_oracle_health and customize it or this is also a pre-defined macro?
$ARG1$ (and $ARG2$, $ARG3$, and so on) are placeholders for arguments that will be passed to the command. This way multiple services could use the same command, but provide different arguments.
c. I'm a little bit confused when it comes the packages I should install on the servers I want to monitor - I already created nagios user, generated ssh keys and added public one to authorized_keys file, I followed the instruction I mentioned above, but I still don't know what should be done there on the Oracle server - should I also download and install plugins on the Oracle server?
It's most common to install a client application, like NCPA for example.
https://www.nagios.org/ncpa/

The Oracle checks will use the Oracle client tools to check on the health of Oracle. The NCPA client will help you in monitoring the health of the rest of the server.

Quick question. Are you using Nagios Core, or Nagios XI?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
pr0t
Posts: 2
Joined: Thu Sep 05, 2019 4:42 am

Re: Oracle Monitoring Help

Post by pr0t »

Hi mbellerue,
Quick question. Are you using Nagios Core, or Nagios XI?
I'm using Nagios XI.

I've followed your advice and installed NCPA client on a Windows machine. I configured it using NCPA Wizard and it works like a charm! Thank you so much! ;) I assume that it works the same way on any Linux.

I'm still struggling to run Oracle related checks. There was a mistake in my first post - ORACLE_HOME was supposed to be set to /usr/lib/oracle/19.3/client64. Please, correct me if I'm wrong here - Oracle checks are based on local (i.e. nagios) binaries or do I have to install any additional plugins on my Oracle servers?

BTW. By default, in the nagios core command configuration for check_xi_oraclequery we have the following: $USER1$/check_oracle_health $ARG1$ - there is no such a binary file in /usr/local/nagios/libexec/ - there's only check_oracle - is it supposed to be that way?

Regards,
User avatar
mbellerue
Posts: 1403
Joined: Fri Jul 12, 2019 11:10 am

Re: Oracle Monitoring Help

Post by mbellerue »

pr0t wrote:Hi mbellerue,
Quick question. Are you using Nagios Core, or Nagios XI?
I'm using Nagios XI.

I've followed your advice and installed NCPA client on a Windows machine. I configured it using NCPA Wizard and it works like a charm! Thank you so much! ;) I assume that it works the same way on any Linux.
Yes, NCPA will function the same way on Linux.
I'm still struggling to run Oracle related checks. There was a mistake in my first post - ORACLE_HOME was supposed to be set to /usr/lib/oracle/19.3/client64. Please, correct me if I'm wrong here - Oracle checks are based on local (i.e. nagios) binaries or do I have to install any additional plugins on my Oracle servers?

BTW. By default, in the nagios core command configuration for check_xi_oraclequery we have the following: $USER1$/check_oracle_health $ARG1$ - there is no such a binary file in /usr/local/nagios/libexec/ - there's only check_oracle - is it supposed to be that way?

Regards,
Yes, the plugins live on the Nagios server in /usr/local/nagios/libexec/. It's odd that the other Oracle plugins aren't there. Have you run through the Oracle configuration wizards yet? That may be the point where they get installed.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked