[Nagiosplug-help] "check_nrpe -H 10.x.x.x -c check_ora_tns" ----> "ERROR: CANNOT DETERMINE ORACLE_HOME FOR SID xxxxx"
Justin Amburn
justinjoseph24 at hotmail.com
Fri Mar 28 05:47:10 CET 2008
when running
Does anyone have any experience with this problem? If so please reply!
This is an elusive problem, as the script works fine from the remote server:
sudo su - nagios
[nagios at remoteserver1 libexec]$ ./check_oracle --tns $ORACLE_SID
OK - reply time 0 msec from xxxxx
as well it should work, since my env contains:
[nagios at remoteserver1 libexec]$ env
HOSTNAME=blah.domain.com
SHELL=/bin/bash
TERM=xterm
HISTSIZE=1000
OLDPWD=/u1/apps/oracle/product/10.2.0/bin
USER=nagios
LS_COLORS=no=00:fi=00:di=00;34:ln=00;36:pi=40;33:so=00;35:bd=40;33;01:cd=40;33;01:or=01;05;37;41:mi=01;05;37;41:ex=00;32:*.cmd=00;32:*.exe=00;32:*.com=00;32:*.btm=00;32:*.bat=00;32:*.sh=00;32:*.csh=00;32:*.tar=00;31:*.tgz=00;31:*.arj=00;31:*.taz=00;31:*.lzh=00;31:*.zip=00;31:*.z=00;31:*.Z=00;31:*.gz=00;31:*.bz2=00;31:*.bz=00;31:*.tz=00;31:*.rpm=00;31:*.cpio=00;31:*.jpg=00;35:*.gif=00;35:*.bmp=00;35:*.xbm=00;35:*.xpm=00;35:*.png=00;35:*.tif=00;35:
ORACLE_SID=DBPRD
MAIL=/var/spool/mail/nagios
PATH=/usr/kerberos/bin:/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/u1/apps/oracle/product/10.2.0/bin:/home/nagios/bin
INPUTRC=/etc/inputrc
PWD=/usr/local/nagios/libexec
LANG=en_US.UTF-8
SSH_ASKPASS=/usr/libexec/openssh/gnome-ssh-askpass
SHLVL=1
HOME=/home/nagios
LOGNAME=nagios
LESSOPEN=|/usr/bin/lesspipe.sh %s
ORACLE_HOME=/u1/apps/oracle/product/10.2.0
G_BROKEN_FILENAMES=1
_=/bin/env
The command is predefined in the nrpe.cfg file on the remote server as follows:
command[check_ora_tns]=/usr/local/nagios/libexec/check_oracle --tns DBPRD
On the nagios server I run this command:
/usr/local/nagios/libexec/check_nrpe -H 10.207.9.71 -c check_ora_tns
ERROR: Cannot Determine ORACLE_HOME for sid DBPRD
In the beginning of the check_oracle script I added:
export PATH=$PATH:/u1/apps/oracle/product/10.2.0/bin;export PATH
export ORACLE_HOME=/u1/apps/oracle/product/10.2.0;export ORACLE_HOME
export ORACLE_SID=BABYCPRD;export ORACLE_SID
ORACLE_BASE=/u1/apps/oracle
What am I doing wrong???
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-plugins.org/archive/help/attachments/20080327/7c21887b/attachment.html>
More information about the Help
mailing list