Oracle Database monitoring

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
spatil32
Posts: 13
Joined: Fri Aug 23, 2019 6:37 am

Oracle Database monitoring

Post by spatil32 »

Hi,

I have Nagios Core 3.4 in our environment. A of now we are monitoring only standard OS parameters for Linux. Now there is a requirement to monitoring Oracle Database. So please let me know the steps to configure Oracle DB monitoring in Nagios core.
I can see default oracle plugin i.e check_oracle is present in /usr/local/nagios/libexec and I want use this default plugin only.
So what configuration steps I need to follow.
for e.g
1) what check_command to define in <oraserver>.cfg on Nagios server
2) Do I need to define any command in command.cfg file
3) How to define commands and threshold to define in nrpe.cfg file on Oracle server
4) Where to define ORACLE_HOME
5) Do I need to create any oracle user for Nagios and what rights it should have.

Please let me know on this as I am first time doing oracle DB monitoring in Nagios.
Thanks.

Regards
SagarP
satheesh19870819
Posts: 43
Joined: Wed Mar 21, 2018 1:11 pm

Re: Oracle Database monitoring

Post by satheesh19870819 »

Hello Sagar,

There are lot of plugins in exchange with which you can monitor anything and everything in oracle .

They have the steps to be done as well in most cases .

https://exchange.nagios.org/directory/P ... ses/Oracle
User avatar
mbellerue
Posts: 1403
Joined: Fri Jul 12, 2019 11:10 am

Re: Oracle Database monitoring

Post by mbellerue »

Here is the help on the check_oracle plugin. It will help when defining a command.
https://nagios-plugins.org/doc/man/check_oracle.html

Here is a comprehensive list of object definitions for Nagios Core.
https://assets.nagios.com/downloads/nag ... tions.html

What you will need to do is configure a command that tells Nagios how to use the check_oracle plugin. There may already be an example command defined in your command configuration file (I know in Nagios Core 4 it's /usr/local/nagios/etc/objects/command.cfg, I don't know about 3). Once you have a command created, then you can use that command in your service definition.

So when reading the object definitions, pay particular attention to command definitions, and service definitions. Let us know if you get stuck at any specific point, and we will help you along.
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!
spatil32
Posts: 13
Joined: Fri Aug 23, 2019 6:37 am

Re: Oracle Database monitoring

Post by spatil32 »

Thanks Satheesh and mbellerue for your reply.
I will go through the details provided and let you know the result.
Thanks.

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

Re: Oracle Database monitoring

Post by mbellerue »

Sounds good. We will keep this thread open, and wait to hear back.
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!
spatil32
Posts: 13
Joined: Fri Aug 23, 2019 6:37 am

Re: Oracle Database monitoring

Post by spatil32 »

Hi,
Just a small query. Can we monitor Oracle DB installed on Windows platform using the same oracle plugin.
If not could you please provide details on how to monitor Oracle DB on windows.
Thanks.


Regards
SagarP
satheesh19870819
Posts: 43
Joined: Wed Mar 21, 2018 1:11 pm

Re: Oracle Database monitoring

Post by satheesh19870819 »

This plugin works irrespective of OS as they directly login to oracle DB not into OS .
benjaminsmith
Posts: 5324
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Oracle Database monitoring

Post by benjaminsmith »

Hi @satheesh19870819. Thanks for contributing.

That's right, the plugin is for monitoring the database and is not dependent upon the operating system.

Let us know if you need anything else.
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!
spatil32
Posts: 13
Joined: Fri Aug 23, 2019 6:37 am

Re: Oracle Database monitoring

Post by spatil32 »

Hi,
I managed to successfully configured oracle db on windows machine. But on Linux machine it is giving error as

NRPE: Command 'check_oracle_pmon' not defined

On Nagios server in remoteserver.cfg

define service{
use local-service
host_name remoteserver
service_description Oracle Status
check_command check_nrpe-n!check_oracle_pmon
}


On remote server Linux

In nrpe.cfg
command[check_oracle_pmon]=/usr/local/nagios/libexec/check_oracle --db SID

Status
[root@remoteserver etc]# /usr/local/nagios/libexec/check_oracle --db SID
SID OK - 17695 PMON process(es) running

Could you please help.
Thanks.

Regards
SagarP
benjaminsmith
Posts: 5324
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Oracle Database monitoring

Post by benjaminsmith »

Hello @spatil32,

That looks right. Did you restart NRPE after making changes to the configuration file? If that doesn't work, please post nrpe.cfg to the thread for us to review.

Also, check the permissions on the plugin and make sure you an run it as the nagios user instead of root.
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