Issues installing Oracle plugin in NagiosXI
Issues installing Oracle plugin in NagiosXI
Hi Team,
I'm trying to install the oracle client and plugin on to our nagios server
Below is the document which i'm following
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
If you see the last part in the above mentioned document, it says
=====================================
Nagios gives this error:
CRITICAL - cannot connect to 192.168.5.55:1521. install_driver(Oracle) failed: Can't locate DBD/Oracle.pm in @INC (@INC
contains: /usr/local/nagios/libexec /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl
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
=====================================
But when i try to install the perl module via cpan, i'm getting the attached error.
I have already refered older topics, but it did not helped me
https://support.nagios.com/forum/viewto ... f=6&t=5462
Need your assistance on this on high priority.
Below are some additional details
# uname -a
Linux nagmonusdev1 2.6.32-431.20.3.el6.x86_64 #1 SMP Fri Jun 6 18:30:54 EDT 2014 x86_64 x86_64 x86_64 GNU/Linux
I'm trying to install the oracle client and plugin on to our nagios server
Below is the document which i'm following
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
If you see the last part in the above mentioned document, it says
=====================================
Nagios gives this error:
CRITICAL - cannot connect to 192.168.5.55:1521. install_driver(Oracle) failed: Can't locate DBD/Oracle.pm in @INC (@INC
contains: /usr/local/nagios/libexec /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl
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
=====================================
But when i try to install the perl module via cpan, i'm getting the attached error.
I have already refered older topics, but it did not helped me
https://support.nagios.com/forum/viewto ... f=6&t=5462
Need your assistance on this on high priority.
Below are some additional details
# uname -a
Linux nagmonusdev1 2.6.32-431.20.3.el6.x86_64 #1 SMP Fri Jun 6 18:30:54 EDT 2014 x86_64 x86_64 x86_64 GNU/Linux
You do not have the required permissions to view the files attached to this post.
Re: Issues installing Oracle plugin in NagiosXI
Can you please provide your Nagios XI version, your OS + version, and your perl -v version? It appears you have perl 5.8.8 according to the output, but I want to confirm this is the case, and see if you might have multiple versions.
Former Nagios employee
Re: Issues installing Oracle plugin in NagiosXI
Please run these commads:
- Note: you will need to change the paths for each to it's proper location if you installed a different version of instantclient.
- Note: you will need to change the paths for each to it's proper location if you installed a different version of instantclient.
Code: Select all
export ORACLE_HOME=/usr/lib/oracle/12.1/client64/lib
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/lib/oracle/12.1/client64/lib/
export PATH=$PATH:/usr/lib/oracle/12.1/client64/bin
cpan -i DBD::OracleRe: Issues installing Oracle plugin in NagiosXI
Looks like the perl module got installed.
but i'm not able to to a tnsping with check_oracle_health
# ./check_oracle_health --connect xxx.bose.com --mode tnsping
CRITICAL - cannot connect to xxx.bose.com. timeout alarm
the server xxx.bose.com is reachable from the Nagios server.
but i'm not able to to a tnsping with check_oracle_health
# ./check_oracle_health --connect xxx.bose.com --mode tnsping
CRITICAL - cannot connect to xxx.bose.com. timeout alarm
the server xxx.bose.com is reachable from the Nagios server.
Re: Issues installing Oracle plugin in NagiosXI
Can you please run nmap 192.168.5.55 (I assume this is the same as xxx.bose.com?), and post the result?
Former Nagios Employee
Re: Issues installing Oracle plugin in NagiosXI
I'm able to run tnsping
# ./check_oracle_health --connect xxx.bose.com --mode tnsping
OK - connection established to xxx.bose.com.
But when i try to run a query it fails with below error message
# ./check_oracle_health -connect xxx.bose.com:1526 --username nagios --password "nagios" --mode sql --name 'select count(*) from S_ESCL_REQ' --warning 1500 --critical 2000
CRITICAL - cannot connect to xxx.bose.com:1526. ORA-12154: TNS:could not resolve the connect identifier specified (DBD ERROR: OCIServerAttach)
Let me know what can done here
# ./check_oracle_health --connect xxx.bose.com --mode tnsping
OK - connection established to xxx.bose.com.
But when i try to run a query it fails with below error message
# ./check_oracle_health -connect xxx.bose.com:1526 --username nagios --password "nagios" --mode sql --name 'select count(*) from S_ESCL_REQ' --warning 1500 --critical 2000
CRITICAL - cannot connect to xxx.bose.com:1526. ORA-12154: TNS:could not resolve the connect identifier specified (DBD ERROR: OCIServerAttach)
Let me know what can done here
Re: Issues installing Oracle plugin in NagiosXI
You are missing the SID in the connect option. Here is an example is what it should look like.
Code: Select all
192.168.1.1:1521/orclBe sure to check out our Knowledgebase for helpful articles and solutions!
Re: Issues installing Oracle plugin in NagiosXI
I tried it, bit still same error
# ./check_oracle_health -connect xxx.bose.com:1526/SBLQA1 --username nagios --password "xxx" --mode sql --name="select count(*) from S_ESCL_REQ" --warning 1500 --critical 2000
CRITICAL - cannot connect to xxx.bose.com:1526/SBLQA1. ORA-12154: TNS:could not resolve the connect identifier specified (DBD ERROR: OCIServerAttach)
# ./check_oracle_health -connect xxx.bose.com:1526/SBLQA1 --username nagios --password "xxx" --mode sql --name="select count(*) from S_ESCL_REQ" --warning 1500 --critical 2000
CRITICAL - cannot connect to xxx.bose.com:1526/SBLQA1. ORA-12154: TNS:could not resolve the connect identifier specified (DBD ERROR: OCIServerAttach)
Re: Issues installing Oracle plugin in NagiosXI
Can someone please look into this
Re: Issues installing Oracle plugin in NagiosXI
Your first post you were using port 1521 and then later on you were using port 1526, can you verify which port it is?
Can you run the following and post the output. Replace xxx.xxx.xxx.xxx with the IP address of the server.
Can you run the following and post the output. Replace xxx.xxx.xxx.xxx with the IP address of the server.
Code: Select all
nmap xxx.xxx.xxx.xxx -p 1521
nmap xxx.xxx.xxx.xxx -p 1526Be sure to check out our Knowledgebase for helpful articles and solutions!