<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman,new york,times,serif;font-size:12pt"><div>Michael,<br><br>Thanks for the reply.<br><br>[root@spacewalk ~]# ldd `rpm -ql cx_Oracle | grep cx_Oracle.so`<br>    linux-gate.so.1 =>  (0x009dd000)<br>    libclntsh.so.10.1 => /usr/lib/oracle/10.2.0.4/client/lib/libclntsh.so.10.1 (0x00c11000)<br>    libpthread.so.0 => /lib/libpthread.so.0 (0x00110000)<br>    libc.so.6 => /lib/libc.so.6 (0x00127000)<br>    libnnz10.so => /usr/lib/oracle/10.2.0.4/client/lib/libnnz10.so (0x00360000)<br>    libdl.so.2 => /lib/libdl.so.2 (0x0026b000)<br>    libm.so.6 => /lib/libm.so.6 (0x00856000)<br>    libnsl.so.1 => /lib/libnsl.so.1 (0x0026f000)<br>    /lib/ld-linux.so.2
 (0x00720000)<br>[root@spacewalk ~]# lsof -p `ps ax | awk '/[o]sa-dispatcher/ {print $1}' ` | grep oracle<br>osa-dispa 3183 root  mem    REG  253,7 17764670 1942698 /u01/app/oracle/product/10.2.0/db_1/lib/libclntsh.so.10.1<br>osa-dispa 3183 root  mem    REG  253,7  5480533 1943219 /u01/app/oracle/product/10.2.0/db_1/lib/libnnz10.so<br>[root@spacewalk ~]# <br><br>I did install the oracle-xe client libraries to satisfy the RPM deps when doing the yum install spacewalk:<br><span class="searchword0">[root@spacewalk ~]# rpm -qa oracle-instant\*<br>oracle-instantclient-sqlplus-10.2.0.4-1<br>oracle-instantclient-basic-10.2.0.4-1<br>oracle-instantclient-sqlplus-selinux-10.2-15.el5<br>oracle-instantclient-selinux-10.2-15.el5<br></span><br>So my client libraries are in /usr/lib/oracle and the database is running out of /u01/app/oracle. I did try to add the environment variables to the entire system by doing
 the following:<br>[root@spacewalk ~]# cat /etc/profile.d/oracle.sh <br># Oracle Settings<br>TMP=/tmp; export TMP<br>TMPDIR=$TMP; export TMPDIR<br><br>ORACLE_BASE=/u01/app/oracle; export ORACLE_BASE<br>ORACLE_HOME=$ORACLE_BASE/product/10.2.0/db_1; export ORACLE_HOME<br>ORACLE_SID=TSH1; export ORACLE_SID<br>ORACLE_TERM=xterm; export ORACLE_TERM<br>PATH=/usr/sbin:$PATH; export PATH<br>PATH=$ORACLE_HOME/bin:$PATH; export PATH<br><br>LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib; export LD_LIBRARY_PATH<br>CLASSPATH=$ORACLE_HOME/JRE:$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib; export CLASSPATH<br><br>if [ $USER = "oracle" ]; then<br>  if [ $SHELL = "/bin/ksh" ]; then<br>    ulimit -p 16384<br>    ulimit -n 65536<br>  else<br>    ulimit -u 16384 -n 65536<br>  fi<br>fi<br><br>What system calls or environment variables does the python stack use in order to get the Oracle instance information for the
 client libraries to connect with?<br><br>--Matt<br></div><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;"><br><div style="font-family: arial,helvetica,sans-serif; font-size: 13px;"><font face="Tahoma" size="2"><hr size="1"><b><span style="font-weight: bold;">From:</span></b> Michael Mraka <michael.mraka@redhat.com><br><b><span style="font-weight: bold;">To:</span></b> spacewalk-list@redhat.com<br><b><span style="font-weight: bold;">Sent:</span></b> Mon, October 19, 2009 4:38:15 AM<br><b><span style="font-weight: bold;">Subject:</span></b> Re: [Spacewalk-list] Spacewalk with oracle standard edition errors<br></font><br>
Matt Carey wrote:<br>% I'm trying to get my Spacewalk instance to work with Oracle standard edition. The install went off without a hitch and populating the channels with spacewalk-repo-sync worked properly.  I created the kickstart distributions and the profiles for the CentOS channels.  Cobbler looks like it picked up the configurations properly:<br>...<br>% I'm starting to think this is a wider issue with python scripts not being able to connect because of the following entries:<br>% [root@spacewalk ~]# tail -2 /var/log/rhn/osa-dispatcher.log<br>% 2009/10/18 22:38:44 -04:00 3172 0.0.0.0: osad/jabber_lib.main('ERROR', 'Error caught:')<br>% 2009/10/18 22:38:44 -04:00 3172 0.0.0.0: osad/jabber_lib.main('ERROR', 'Traceback (most recent call last):\n  File "/usr/share/rhn/osad/jabber_lib.py", line 119, in main\n    self.setup_config(config)\n  File "/usr/share/rhn/osad/osa_dispatcher.py", line 81, in setup_config\n 
   rhnSQL.initDB()\n  File "/usr/share/rhn/server/rhnSQL/__init__.py", line 98, in initDB\n    __init__DB(backend, host, port, username, password, database)\n  File "/usr/share/rhn/server/rhnSQL/__init__.py", line 59, in __init__DB\n    __DB.check_connection()\n  File "/usr/share/rhn/server/rhnSQL/driver_cx_Oracle.py", line 490, in check_connection\n    self.connect() # only allow one try\n  File "/usr/share/rhn/server/rhnSQL/driver_cx_Oracle.py", line 370, in connect\n    self.dbh = self._connect()\n  File "/usr/share/rhn/server/rhnSQL/driver_cx_Oracle.py", line 396, in _connect\n    dbh = cx_Oracle.Connection(self.dsn)\nInterfaceError: Unable to acquire Oracle environment<br>%  handle\n')<br>% <br>% Does anyone have any ideas as to what the potential issue could be? Any help would be greatly appreciated.<br><br>Typically it means osa-dispatcher (maybe whole python
 stack) is unable to find<br>oracle libraries.<br><br>Check<br># ldd `rpm -ql cx_Oracle | grep <a target="_blank" href="http://cx_Oracle.so">cx_Oracle.so</a>`<br>and<br># lsof -p `ps ax | awk '/[o]sa-dispatcher/ {print $1}' ` | grep oracle<br><br><br>% Regards,<br>% Matt<br><br>Regards,<br><br>--<br>Michael Mráka<br>Satellite Engineering, Red Hat<br><br>_______________________________________________<br>Spacewalk-list mailing list<br><a ymailto="mailto:Spacewalk-list@redhat.com" href="mailto:Spacewalk-list@redhat.com">Spacewalk-list@redhat.com</a><br><a href="https://www.redhat.com/mailman/listinfo/spacewalk-list" target="_blank">https://www.redhat.com/mailman/listinfo/spacewalk-list</a><br></div></div></div><br>

      </body></html>