Page 1 of 1

Oracle Check Errors

Posted: Thu Mar 14, 2013 10:45 am
by asmgiadmin
Followed documentation - http://assets.nagios.com/downloads/nagi ... lation.pdf

Ran oracle monitor wizard with user / pass combo provided by DBA

Receive error:

Code: Select all

CRITICAL - cannot connect to pdboinsp03.safe-prop.com:1521. install_driver(Oracle) failed: Can't locate DBD/Oracle.pm in @INC (@INC contains: /usr/local/nagios/libexec /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/p
Perhaps the DBD::Oracle perl module hasn't been fully installed,
or perhaps the capitalisation of 'Oracle' isn't right.
Available drivers: DBM, ExampleP, File, Gofer, Proxy, SQLite, Sponge, mysql.
at /usr/local/nagios/libexec/check_oracle_health line 4755
Referenced Common Problems section of above documentation:
This is due to the Perl module not being installed properly. To remedy this problem, execute the following from the command line:
export ORACLE_HOME=<path to your Oracle which was given by the script>
export LD_LIBRARY_PATH=$ORACLE_HOME/lib
cpan -i DBD::Oracle
Executed the following:

Code: Select all

[root@nagiosxi client64]# export ORACLE_HOME=/usr/lib/oracle/11.2/client64
[root@nagiosxi client64]# export LD_LIBRARY_PATH=$ORACLE_HOME/lib
[root@nagiosxi client64]# cpan -i DBD::Oracle
Executed commands returned following info, including warnings:

Code: Select all

  CPAN.pm: Going to build P/PY/PYTHIAN/DBD-Oracle-1.58.tar.gz

Multiple copies of Driver.xst found in: /usr/local/lib64/perl5/auto/DBI/ /usr/lib64/perl5/auto/DBI/ at Makefile.PL line 39
Using DBI 1.623 (for perl 5.010001 on x86_64-linux-thread-multi) installed in /usr/local/lib64/perl5/auto/DBI/

Configuring DBD::Oracle for perl 5.010001 on linux (x86_64-linux-thread-multi)

Remember to actually *READ* the README file! Especially if you have any problems.

Installing on a linux, Ver#2.6
Using Oracle in /usr/lib/oracle/11.2/client64
Can't find sqlplus. Pity, it would have helped.
I'm having trouble finding your Oracle version number... trying harder

WARNING: I could not determine Oracle client version so I'll just
default to version 8.0.0.0. Some features of DBD::Oracle may not work.
Oracle version based logic in Makefile.PL may produce erroneous results.
You can use "perl Makefile.PL -V X.Y.Z" to specify a your client version.

Oracle version 8.0.0.0 (8.0)
DBD::Oracle no longer supports Oracle client versions before 9.2
 Try a version before 1.25 for 9 and 1.18 for 8! at Makefile.PL line 271.
Warning: No success on command[/usr/bin/perl Makefile.PL INSTALLDIRS=site]
  PYTHIAN/DBD-Oracle-1.58.tar.gz
  /usr/bin/perl Makefile.PL INSTALLDIRS=site -- NOT OK
Running make test
  Make had some problems, won't test
Running make install
  Make had some problems, won't install
Please advise

Re: Oracle Check Errors

Posted: Thu Mar 14, 2013 11:01 am
by slansing
What Oracle Database version are you attempting to monitor?
ORACLE_HOME=/usr/lib/oracle/11.2/client
LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib
Is only an example, it must be changed if you are running under a different version or pathing.

We need to look to this error first as a good indicator:

Code: Select all

Using Oracle in /usr/lib/oracle/11.2/client64
Can't find sqlplus. Pity, it would have helped.
I'm having trouble finding your Oracle version number... trying harder

Re: Oracle Check Errors

Posted: Thu Mar 14, 2013 11:08 am
by asmgiadmin
Looking to monitor v 11.2.0.3

What is sqlplus error about?

Re: Oracle Check Errors

Posted: Thu Mar 14, 2013 11:24 am
by sreinhardt
sqlplus looks to be an oracle client provided here

Re: Oracle Check Errors

Posted: Thu Mar 14, 2013 11:43 am
by asmgiadmin
I was following documentation, did I miss something?

Re: Oracle Check Errors

Posted: Thu Mar 14, 2013 11:49 am
by slansing
It may be a dependency normally found on the Database server, it looks like it will be required to install this Perl module however.