lausser / check_oracle_health

A plugin (monitoring-plugin, not nagios-plugin, see also http://is.gd/PP1330) which checks various parameters of Oracle database servers. (We also offer trainings: http://www.consol.de/open-source-monitoring/schulungen/workshops/#datenbank-monitoring)
http://labs.consol.de/nagios/check_oracle_health
GNU General Public License v2.0
34 stars 29 forks source link

Show 'UNKNOWN' status but get 'OK' information #28

Closed Hellofafar closed 5 years ago

Hellofafar commented 5 years ago

Hi,

I tried to use check_oracle_health for checking tablespace and custom sql query. Both commands works when I execute from command line on the server. But when I tested with Nagios deamon, I met a weird situation.

For example, I wanted to check row number of a table. It showed 'UNKNOWN' for the service on the "Service Status Details For All Host Groups" page.

Service Status Last Check Duration Attempt Status Information
Row Count for Last Day UNKNOWN 01-15-2019 20:19:30 0d 0h 48m 39s 3/3 OK - row_count: 7152433

However, when I click the service to see detail, I saw it actually received correct status information as "OK - row_count: 7152433", but it's still shown as UNKNOWN for Current Status.

Current Status: UNKNOWN   (for 0d 0h 42m 43s)
Status Information: OK - row_count: 7152433
Performance Data: 'row_count'=7152433;@6000000:7000000;6000000:
-- --

Version: Nagios Core (4.4.2) check_oracle_health (3.1.2.2)

Can any one help me on this issue? Thanks a lot!

lausser commented 5 years ago

Run it again on the command line and then check the exit code with echo $?

Hellofafar commented 5 years ago

Run it again on the command line and then check the exit code with echo $?

Thanks for reply.

I ran it on the command line but not exit code. I got following:

OK - row_count: 7034181 | 'row_count'=7034181;@6000000:7000000;6000000: Segmentation fault (core dumped)

Hellofafar commented 5 years ago

I still meet this issue. Can you please provide some ideas? Thanks!

lausser commented 5 years ago

Segmentation fault (core dumped) means there's a problem with the Oracle client installation or with the DBD::Oracle perl module.