Problems with check_oracle_health Tablespace check

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
nagiosEngie
Posts: 104
Joined: Thu May 03, 2018 7:57 am

Problems with check_oracle_health Tablespace check

Post by nagiosEngie »

Hello Nagios Crew,

I am having some problems with checking my Oracle DB's used tablespace.
Some DB's that are particularly big will take a long time to answer (over 60 sec) and I will get a critical alarm on timeout.

Our DBA has optimized to the maximum the nagios query on the DB server but we still go in timeout.
Is there a way to speed things up? Maybe parallel execution or other?

Thanks
Sandro
User avatar
mcapra
Posts: 3739
Joined: Thu May 05, 2016 3:54 pm

Re: Problems with check_oracle_health Tablespace check

Post by mcapra »

A previous post I made on this topic:
https://support.nagios.com/forum/viewto ... 77#p260977

In my opinion, the more optimal solution would be to break this particular check out of the main Nagios Core process by submitting it passively.

More info:
https://assets.nagios.com/downloads/nag ... hecks.html
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
Former Nagios employee
https://www.mcapra.com/
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: Problems with check_oracle_health Tablespace check

Post by npolovenko »

Thanks, @mcapra!
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
nagiosEngie
Posts: 104
Joined: Thu May 03, 2018 7:57 am

Re: Problems with check_oracle_health Tablespace check

Post by nagiosEngie »

Hello All,
thanks for the great suggestions. So at the moment I checked the version of the script I have: ad it was quite old. So I downloaded from https://labs.consol.de/nagios/check_ora ... index.html
the newest version and tested it. It's performance is quite improved. I now get answers under 30 sec on the biggest DB I have.
I will be keeping an eye on this and give feed back in a few days.

Thanks
Sandro
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: Problems with check_oracle_health Tablespace check

Post by npolovenko »

@nagiosEngie, Sounds good! Thanks for the update.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
nagiosEngie
Posts: 104
Joined: Thu May 03, 2018 7:57 am

Re: Problems with check_oracle_health Tablespace check

Post by nagiosEngie »

Well, I wish it was that easy.
I now get the critical 60.01 seconds timeout al least once an hour.
My service_check_timeout=120 is set to 2 minutes but still no way of solving this.

I tried the -t option in the check_oracle_health script but it seams to not work.

SAndro
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Problems with check_oracle_health Tablespace check

Post by lmiltchev »

Have you restarted nagios service after setting up:

Code: Select all

service_check_timeout=120
in the nagios.cfg file, so that changes can take effect?

Code: Select all

service nagios restart
Also, can you time your check while using the "-t" flag to see when it fails?
Example:

Code: Select all

time /usr/local/nagios/libexec/check_oracle_health <the rest of the command> -t 120 
Be sure to check out our Knowledgebase for helpful articles and solutions!
nagiosEngie
Posts: 104
Joined: Thu May 03, 2018 7:57 am

Re: Problems with check_oracle_health Tablespace check

Post by nagiosEngie »

Hello I set the service_check_timeout and restarted nagios.
What dose exactly the -t option do?

Is it the timeout for the command? Something like wait for a maximum of xx seconds before timeout?

Sandro
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Problems with check_oracle_health Tablespace check

Post by lmiltchev »

Yes, it is the timeout option for the plugin.

Quote from the plugin's usage (help) menu:
[root@main-nagios-xi ~]# /usr/local/nagios/libexec/check_oracle_health -h

Copyright (c) 2008 Gerhard Lausser

Check various parameters of Oracle databases

Usage:
check_oracle_health [-v] [-t <timeout>] --connect=<connect string>
--username=<username> --password=<password> --mode=<mode>
--tablespace=<tablespace>
check_oracle_health [-h | --help]
check_oracle_health [-V | --version]
Be sure to check out our Knowledgebase for helpful articles and solutions!
nagiosEngie
Posts: 104
Joined: Thu May 03, 2018 7:57 am

Re: Problems with check_oracle_health Tablespace check

Post by nagiosEngie »

Hello lmiltchev,

I have tried to set the -t option of the check_oracle_health script to 300. And the global nagios timeout (service_check_timeout=120)to 120.
Check will timeout in 120 sec anyway. image oracle01.jpg

As you can see the check fails and goes in time out after 120 sec instead of 300. why dose this happen?

As always Thankyou
Sandro
You do not have the required permissions to view the files attached to this post.
Locked