Setting up Oracle database Monitoring - facing issue
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Setting up Oracle database Monitoring - facing issue
I see.. Can you verify you have the correct information about your Oracle server in the tnsnames.ora file...
-
maxwellmiranda
- Posts: 113
- Joined: Thu Mar 22, 2012 3:24 pm
Re: Setting up Oracle database Monitoring - facing issue
yes i have....the tns entries are correct
i tried the instructions on the "http://usestrict.net/2009/07/perl-insta ... nt-client/" link
now i am getting a different error when i execute on the command line.....
CRITICAL - cannot connect to dbatools:1527. ORA-12504: TNS:listener was not given the SERVICE_NAME in CONNECT_DATA (DBD ERROR: OCIServerAttach)
when i use the oracle tablespace plugin i get the below error
CRITICAL - cannot connect to dbatools.bose.com:1521. ORA-12541: TNS:no listener (DBD ERROR: OCIServerAttach)
my database and listener on the dbatools.bose.com are running fine....
i tried the instructions on the "http://usestrict.net/2009/07/perl-insta ... nt-client/" link
now i am getting a different error when i execute on the command line.....
CRITICAL - cannot connect to dbatools:1527. ORA-12504: TNS:listener was not given the SERVICE_NAME in CONNECT_DATA (DBD ERROR: OCIServerAttach)
when i use the oracle tablespace plugin i get the below error
CRITICAL - cannot connect to dbatools.bose.com:1521. ORA-12541: TNS:no listener (DBD ERROR: OCIServerAttach)
my database and listener on the dbatools.bose.com are running fine....
-
maxwellmiranda
- Posts: 113
- Joined: Thu Mar 22, 2012 3:24 pm
Re: Setting up Oracle database Monitoring - facing issue
i have one more update
i tried the following from the command line and it worked....
nagmon:/usr/lib/oracle/11.2/client/bin> /usr/bin/env TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib ORACLE_HOME=/usr/lib/oracle/11.2/client /usr/local/nagios/libexec/check_oracle_health --connect "(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = dbatools.bose.com)(PORT = 1527)))(CONNECT_DATA =(SID = pwdb)))" --username system --password "****" --mode connection-time --warning 1 --critical 5
OK - 0.28 seconds to connect as SYSTEM | connection_time=0.2812;1;5
how do i get the error fixed from the web browser
i tried the following from the command line and it worked....
nagmon:/usr/lib/oracle/11.2/client/bin> /usr/bin/env TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib ORACLE_HOME=/usr/lib/oracle/11.2/client /usr/local/nagios/libexec/check_oracle_health --connect "(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = dbatools.bose.com)(PORT = 1527)))(CONNECT_DATA =(SID = pwdb)))" --username system --password "****" --mode connection-time --warning 1 --critical 5
OK - 0.28 seconds to connect as SYSTEM | connection_time=0.2812;1;5
how do i get the error fixed from the web browser
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Setting up Oracle database Monitoring - facing issue
this is great news
You can edit the commands in
Configure -> Core Config Manager -> Commands -> Modify ( *oracle*)
You can add the TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin as used when it worked
You can edit the commands in
Configure -> Core Config Manager -> Commands -> Modify ( *oracle*)
You can add the TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin as used when it worked
-
maxwellmiranda
- Posts: 113
- Joined: Thu Mar 22, 2012 3:24 pm
Re: Setting up Oracle database Monitoring - facing issue
the command that worked was tnsping..
i am trying to run the tablespace info check on the command line
i am getting this error
nagmon:/usr/local/nagios/libexec> /usr/bin/env TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib ORACLE_HOME=/usr/lib/oracle/11.2/client /usr/local/nagios/libexec/check_oracle_health --connect "(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = dbatools.bose.com)(PORT = 1527)))(CONNECT_DATA =(SID = pwdb)))" --username system --password "****" --name pwdb --mode tablespace-usage --warning 90 --critical 98
CRITICAL - unable to aquire tablespace info
i am trying to run the tablespace info check on the command line
i am getting this error
nagmon:/usr/local/nagios/libexec> /usr/bin/env TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib ORACLE_HOME=/usr/lib/oracle/11.2/client /usr/local/nagios/libexec/check_oracle_health --connect "(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = dbatools.bose.com)(PORT = 1527)))(CONNECT_DATA =(SID = pwdb)))" --username system --password "****" --name pwdb --mode tablespace-usage --warning 90 --critical 98
CRITICAL - unable to aquire tablespace info
Re: Setting up Oracle database Monitoring - facing issue
With the tablespace options you'll nned to specify the tablespace with the --tablespace option. Can you try adding that option to the command?
Nicholas Scott
Former Nagios employee
Former Nagios employee
-
maxwellmiranda
- Posts: 113
- Joined: Thu Mar 22, 2012 3:24 pm
Re: Setting up Oracle database Monitoring - facing issue
if i need to find the tablespace usage of all the tablespaces do i have to give this options in the command
i tried with one tablespace...still the same issue
nagmon:/usr/local/nagios/libexec> /usr/bin/env TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib ORACLE_HOME=/usr/lib/oracle/11.2/client /usr/local/nagios/libexec/check_oracle_health --connect "(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = dbatools.bose.com)(PORT = 1527)))(CONNECT_DATA =(SID = pwdb)))" --username system --password "****" --name pwdb --mode tablespace-usage --tablespace "system" --warning 90 --critical 98
CRITICAL - unable to aquire tablespace info
i tried with one tablespace...still the same issue
nagmon:/usr/local/nagios/libexec> /usr/bin/env TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib ORACLE_HOME=/usr/lib/oracle/11.2/client /usr/local/nagios/libexec/check_oracle_health --connect "(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = dbatools.bose.com)(PORT = 1527)))(CONNECT_DATA =(SID = pwdb)))" --username system --password "****" --name pwdb --mode tablespace-usage --tablespace "system" --warning 90 --critical 98
CRITICAL - unable to aquire tablespace info
Re: Setting up Oracle database Monitoring - facing issue
Generally the tablespace is capitalized and case sensitive if I'm not mistaken. Try it with SYSTEM
Nicholas Scott
Former Nagios employee
Former Nagios employee
-
maxwellmiranda
- Posts: 113
- Joined: Thu Mar 22, 2012 3:24 pm
Re: Setting up Oracle database Monitoring - facing issue
same error even if i enter the tablespace name in UPPER CASE
nagmon:/usr/local/nagios/libexec> /usr/bin/env TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib ORACLE_HOME=/usr/lib/oracle/11.2/client /usr/local/nagios/libexec/check_oracle_health --connect "(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = dbatools.bose.com)(PORT = 1527)))(CONNECT_DATA =(SID = pwdb)))" --username system --password "*****" --name pwdb --mode tablespace-usage --tablespace "SYSTEM" --warning 90 --critical 98
CRITICAL - unable to aquire tablespace info
nagmon:/usr/local/nagios/libexec>
nagmon:/usr/local/nagios/libexec> /usr/bin/env TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib ORACLE_HOME=/usr/lib/oracle/11.2/client /usr/local/nagios/libexec/check_oracle_health --connect "(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = dbatools.bose.com)(PORT = 1527)))(CONNECT_DATA =(SID = pwdb)))" --username system --password "*****" --name pwdb --mode tablespace-usage --tablespace "SYSTEM" --warning 90 --critical 98
CRITICAL - unable to aquire tablespace info
nagmon:/usr/local/nagios/libexec>
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Setting up Oracle database Monitoring - facing issue
Lets try the command as follows
Code: Select all
/usr/bin/env TNS_ADMIN=/usr/lib/oracle/11.2/client/network/admin LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client/lib ORACLE_HOME=/usr/lib/oracle/11.2/client /usr/local/nagios/libexec/check_oracle_health --connect "(DESCRIPTION =(ADDRESS_LIST =(ADDRESS = (PROTOCOL = TCP)(HOST = dbatools.bose.com)(PORT = 1527)))(CONNECT_DATA =(SID = pwdb)))" --username system --password "*****" --name SYSTEM --mode tablespace-usage --warning 90 --critical 98