Have you run
    genclntsh
and/or
    genclntst
In ORACLE_HOME/bin
?

I don’t recall very well where I learned about this, or how it is documented...
But it does something to some files in $ORACLE_HOME/lib that is needed in order 
for Roracle to build.

lib[598]% nm libclntsh.so | grep sqlprc
0000000000d6d8ba T sqlprc
                 U sqlprc_
0000000000d6d864 T sqlprct

Note the “clntsh” at the end of genclntsh and libclntsh. There’s an analgous 
set for “clntst”

(I think maybe the lib files have size 0 before, and the commands generate 
those files, but my memory is hazy. So you might want to run the nm command 
before and after.)
(I think a web search on those lib names will turn something up, not 
specifically for R, but in the context of building custom C code to connect to 
Oracle)

-Don

On 1/6/11 1:11 AM, "thomas.car...@bnpparibas.com" 
<thomas.car...@bnpparibas.com> wrote:

Hello,

I have applied all tips (except moving to different DB lib) :

move to R-2.12.1
try R CMD INSTALL instead of install.packages('ROracle');
run as root
checked that I have full 32 bit env

It still fails with same error at installation when trying to load ROracle
lib

---------------------
** testing if installed package can be loaded
Error in dyn.load(file, DLLpath = DLLpath, ...) :
  unable to load shared object
'/opt/R-2.12.1/lib/R/library/ROracle/libs/ROracle.so':
  /opt/R-2.12.1/lib/R/library/ROracle/libs/ROracle.so: undefined symbol:
sqlprc
---------------------

I know have additional warnings because of my upgrade to R-2.12.1 :

Rd warning: ./man/DBIPreparedStatement-class.Rd:17: missing file link
'dbPrepareStatement'

I know have 2 problems to solve :-)

what are the required Oracle tarballs for ROacle to install and run ?
how do I get read of these warnings ?

Note that I try to use ROracle with Oracle 11.

Thanks for tips




Internet
marc_schwa...@me.com
05/01/2011 14:31

To
Thomas Carrie
cc
r-help@r-project.org
Subject
Re: [R] What are the necessary Oracle software to install and run ROracle
?









On Jan 5, 2011, at 2:55 AM, thomas.car...@bnpparibas.com wrote:

> Hello,
>
> I am running Linux, I have downloaded
>
> instantclient-basiclite-linux32-11.2.0.2.0.zip
> instantclient-sqlplus-linux32-11.2.0.2.0.zip
> instantclient-sdk-linux32-11.2.0.2.0.zip
> instantclient-precomp-linux32-11.2.0.2.0.zip
>
> All these tarballs are unzipped in /usr/local/lib/instantclient, I have
> added this path in the library path of the host.
>
> I can run sqlplus and proc, they do not complain about missing symbol.
>
> Then I install ROracle : install.packages("ROracle")
>
> Compilation step is OK
> But when the test step tries to load the ROracle.so library, it fails :
>
> ** testing if installed package can be loaded
> Error in dyn.load(file, DLLpath = DLLpath, ...) :
>  unable to load shared library
> '/opt/R-2.11.1/lib/R/library/ROracle/libs/ROracle.so':
>  /opt/R-2.11.1/lib/R/library/ROracle/libs/ROracle.so: undefined symbol:
> sqlprc
>
> Here is my list of lib in instantclient directory :
> $ find -name "*.*o" -o -name "*.a"
> ./libsqlplusic.so
> ./sdk/demo/procobdemo.pco
> ./cobsqlintf.o
> ./libociicus.so
> ./libnnz11.so
> ./libocijdbc11.so
> ./libsqlplus.so
>
> Do I need so more lib ? From which Oracle tarball ?
>
> Thanks for help


If you have not, read through the INSTALL file for the package:

  http://cran.r-project.org/web/packages/ROracle/INSTALL

Past postings with similar issues regarding the inability to load shared
libs would suggest that compiling and installing the package outside of R
from the CLI using 'R CMD INSTALL ...' rather than from within R using
install.packages("ROracle"), may resolve the issue.  Also, be sure you are
running all of this as root, since installation to default locations will
require root privileges.

Two more things to consider:

1. R 2.12.1 is the current version of R. If you can, I would recommend
updating from 2.11.1.

2. Be sure that you don't have a conflict between 32 and 64 bit versions
of R and the Oracle tool chain. All components need to be one or the
other. You seem to be using 32 bit versions of the Oracle components
above. Check:

  .Machine$sizeof.pointer

in R to see if you are running 32 or 64 bit R. If the former, the above
will return 4, if the latter, 8.


Another alternative would be to consider using Prof. Ripley's RODBC
package and connecting to Oracle via ODBC.


If you need further assistance, I would suggest subscribing and posting to
r-sig-db or contacting the package author directly. More info on the list
is here:

  https://stat.ethz.ch/mailman/listinfo/r-sig-db

HTH,

Marc Schwartz






This message and any attachments (the "message") is\ int...{{dropped:17}}

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to