Forum Stats

  • 3,750,237 Users
  • 2,250,137 Discussions
  • 7,866,847 Comments

Discussions

ROracle fails to install

4046822
4046822 Member Posts: 10
edited Aug 13, 2019 5:23PM in R Technologies

I can not get ROracle to install on Windows 10 on either 64- or 32-bit versions (I use 64-bit, but after failure with that I tried to at least get 32-bit working and also failed). This current failure occurs with R 3.6.1 and both ROracle 1.3-1 and 1.3-2; I'm up to R 3.6.1 because it also failed on 3.5.x and 3.6.0.

I've set everything up as instructed on http://cran.cnr.berkeley.edu/web/packages/ROracle/INSTALL for a Windows installation. I have Instant Client Basic and SDK extracted to C:\oreclient\instantclient_18_5. I have that path in both the OCI_LIB64 and PATH environment variables. I've exhausted all possible troubleshooting solutions I can find from searching online, and I'm stuck. How do I get ROracle installed and working correctly? Reverting to previous versions of R is not a viable solution.

Best Answer

  • 4046822
    4046822 Member Posts: 10
    edited Aug 8, 2019 10:36AM Accepted Answer

    I had tried installing the Microsoft redistributables when I came across that .dll error earlier in the process, and it didn't change anything. I also just tried installing ROracle a few different ways with anti-virus shut down but also with no luck.

    I was able, however, to follow a slightly different path from that linked page and achieve success! It looks like, despite installing the redistributables, it really was an issue with 'msvcr120.dll' not actually existing where it should be. So, here's what I did between the most recent install failure and success:

    1. From the page you linked to (https://answers.microsoft.com/en-us/windows/forum/windows_7-windows_install/issue-with-programs-that-wont-installstart-b… ), I followed the second link in the accepted answer (https://www.dll-download-system.com/msvcr120_dll.html) and downloaded "64bit,12.0.21005.1". The .dll file is in that .zip file.
    2. I copied msvcr120.dll to two places: C:\oreclient\instantclient_18_5 and C:\Windows\System32 (because that was in PATH and C:\Windows\System64 doesn't exist on my system).
    3. With anti-virus still shut down, I ran install.packages("ROracle"), and it succeeded.

    Now, what I don't know for certain is if all three things needed to happen (the .dll copy to two different folders and the anti-virus shut down) or if, say, only copying to the system folder was all that was needed. I suppose we'll leave that to future readers with a similar issue to test and report back on.

«1

Answers

  • Sherry Lamonica-Oracle
    Sherry Lamonica-Oracle Posts: 437 Employee
    edited Jul 18, 2019 3:23PM

    Are you seeing an error message during the installation, or when you attempt to execute commands from the ROracle package?  Please report them here so we can help diagnose the issue.


    Thanks,

    Sherry

  • 4046822
    4046822 Member Posts: 10
    edited Jul 18, 2019 4:12PM

    I'm seeing it during installation. Here's what the console looks like from a fresh session and a straight-forward install.packages call (in case it matters, this is being executed in RStudio 1.2.1335 and <User directory> includes syncing with OneDrive):

    R version 3.6.1 (2019-07-05) -- "Action of the Toes"

    Copyright (C) 2019 The R Foundation for Statistical Computing

    Platform: x86_64-w64-mingw32/x64 (64-bit)

    R is free software and comes with ABSOLUTELY NO WARRANTY.

    You are welcome to redistribute it under certain conditions.

    Type 'license()' or 'licence()' for distribution details.

    R is a collaborative project with many contributors.

    Type 'contributors()' for more information and

    'citation()' on how to cite R or R packages in publications.

    Type 'demo()' for some demos, 'help()' for on-line help, or

    'help.start()' for an HTML browser interface to help.

    Type 'q()' to quit R.

    > install.packages("ROracle")

    Installing package into ‘C:/<User directory>/R/win-library/3.6’

    (as ‘lib’ is unspecified)

    Package which is only available in source form, and may need compilation

      of C/C++/Fortran: ‘ROracle’

    installing the source package ‘ROracle’

    trying URL 'https://cran.rstudio.com/src/contrib/ROracle_1.3-1.tar.gz'

    Content type 'application/x-gzip' length 308252 bytes (301 KB)

    downloaded 301 KB

    * installing *source* package 'ROracle' ...

    ** package 'ROracle' successfully unpacked and MD5 sums checked

    ** using staged installation

    C:/oreclient/instantclient_18_5/genezi.exe: error while loading shared libraries: ?: cannot open shared object file: No such file or directory

    C:/oreclient/instantclient_18_5/genezi.exe: error while loading shared libraries: ?: cannot open shared object file: No such file or directory

    ./configure.win: line 55: [: too many arguments

    ./configure.win: line 63: [: too many arguments

    Oracle

    found Instant Client C:\oreclient\instantclient_18_5

    found Instant Client SDK C:\oreclient\instantclient_18_5/sdk/include

    copying from C:\oreclient\instantclient_18_5/sdk/include

    ** libs

    Warning: this package has a non-empty 'configure.win' file,

    so building only the main architecture

    C:/Rtools/mingw_64/bin/gcc  -I"C:/PROGRA~1/R/R-36~1.1/include" -DNDEBUG -I./oci         -O2 -Wall  -std=gnu99 -mtune=generic -c rodbi.c -o rodbi.o

    C:/Rtools/mingw_64/bin/gcc  -I"C:/PROGRA~1/R/R-36~1.1/include" -DNDEBUG -I./oci         -O2 -Wall  -std=gnu99 -mtune=generic -c rooci.c -o rooci.o

    C:/Rtools/mingw_64/bin/gcc -shared -s -static-libgcc -o ROracle.dll tmp.def rodbi.o rooci.o C:\oreclient\instantclient_18_5/oci.dll -LC:/PROGRA~1/R/R-36~1.1/bin/x64 -lR

    installing to C:/<User directory>/R/win-library/3.6/00LOCK-ROracle/00new/ROracle/libs/x64

    ** R

    ** inst

    ** byte-compile and prepare package for lazy loading

    ** help

    *** installing help indices

      converting help for package 'ROracle'

        finding HTML links ... done

        ExtDriver-class                         html 

        OraConnection-class                     html 

        OraDriver-class                         html 

        OraResult-class                         html 

        Oracle                                  html 

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/Oracle.Rd:85: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/Oracle.Rd:85: file link 'dbRollback' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/Oracle.Rd:106: file link 'dbUnloadDriver' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/Oracle.Rd:128: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/Oracle.Rd:129: file link 'dbRollback' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/Oracle.Rd:133: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

        dbCommit-methods                        html 

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbCommit-methods.Rd:54: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbCommit-methods.Rd:55: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbConnect-methods                       html 

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbConnect-methods.Rd:165: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbConnect-methods.Rd:166: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbDriver-methods                        html 

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbDriver-methods.Rd:88: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbDriver-methods.Rd:89: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbGetInfo-methods                       html 

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbGetInfo-methods.Rd:279: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbGetInfo-methods.Rd:280: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbListConnections-methods               html 

        dbReadTable-methods                     html 

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbReadTable-methods.Rd:382: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbReadTable-methods.Rd:383: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbSendQuery-methods                     html 

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbSendQuery-methods.Rd:88: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbSendQuery-methods.Rd:139: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/dbSendQuery-methods.Rd:140: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        fetch-methods                           html 

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/fetch-methods.Rd:42: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        summary-methods                         html 

    Rd warning: C:/<User Temp directory>/RtmpOI7UwA/R.INSTALL2a4050cc7c2d/ROracle/man/summary-methods.Rd:43: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

    ** building package indices

    ** testing if installed package can be loaded from temporary location

    Error: package or namespace load failed for 'ROracle' in inDL(x, as.logical(local), as.logical(now), ...):

    unable to load shared object 'C:/<User directory>/R/win-library/3.6/00LOCK-ROracle/00new/ROracle/libs/x64/ROracle.dll':

      LoadLibrary failure:  The specified module could not be found.

    Error: loading failed

    Execution halted

    ERROR: loading failed

    * removing 'C:/<User directory>/R/win-library/3.6/ROracle'

    Warning in install.packages :

      installation of package ‘ROracle’ had non-zero exit status

    The downloaded source packages are in

    ‘C:\<User Temp directory>\RtmpSiYraU\downloaded_packages’

  • Sherry Lamonica-Oracle
    Sherry Lamonica-Oracle Posts: 437 Employee
    edited Aug 1, 2019 4:20PM

    Go ahead and remove the lock file C:/<User directory>/R/win-library/3.6/00LOCK that was generated by the previously failed installation and try again.

    I'm able to get ROracle 1.3-1 installed from source using R-3.6.1 (64-bit) on Windows 10 using the Oracle Instant Client 18.5 version you are using.  Here are the steps I followed:

    Add $R_HOME/bin/x64 to the PATH environment variable

    Add the path to the Oracle instant client to the PATH environment variable

    Add the path to the Oracle instant client to a new environment variable: OCI_LIB64

    Install Rtools and add the path to Rtools/bin to PATH:

    C:\Users\slamonic>echo %PATH%

    C:\Rtools\bin;C:\windows\system32;C:\windows;C:\windows\System32\Wbem;C:\windows\System32\WindowsPowerShell\v1.0\;C:\windows\System32\OpenSSH\;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\Users\slamonic\AppData\Local\Microsoft\WindowsApps;C:\Users\slamonic\AppData\Local\GitHubDesktop\bin;C:\Users\slamonic\Downloads\instantclient_18_5;C:\Program Files\R\R-3.6.1\bin\x64;

    C:\Users\slamonic>echo %OCI_LIB64%

    C:\Users\slamonic\Downloads\instantclient_18_5

    Next, I executed the following command to install the source package from CRAN from the R console (alternatively download the ROracle source and use the "R CMD INSTALL ROracle_1.3-1.tar.gz ")

    R>  install.packages("https://cran.r-project.org/src/contrib/ROracle_1.3-1.tar.gz", type="source", repos=NULL)

    In most cases these steps are all that is required.  In my case, my Windows virus scanner was blocking a file being copied during the compilation process.  The error I received is:

    <span class="pln" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">.</span><span class="pun" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">/</span><span class="pln" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">oci</span><span class="pun" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">/</span><span class="pln" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">oci.h</span><span class="pun" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">:</span><span class="lit" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #7d2727;">716</span><span class="pun" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">:</span><span class="lit" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #7d2727;">20</span><span class="pun" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">:</span><span class="pln" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;"> fatal error</span><span class="pun" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">:</span><span class="pln" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;"> ociver.h</span><span class="pun" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">:</span><span class="pln" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;"> No such file or directory<br/> </span><span class="com" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #858c93;">#include <ociver.h></span><span class="pln" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;"><br/>   </span><span class="pun" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;">^</span><span class="pln" style="font-style: inherit; font-weight: inherit; font-family: inherit; color: #303336;"><br/>compilation terminated.</span>

    Manually copying ociver.h from C:\Program Files\R\R-3.6.1\include  to $R_HOME/include and then re-running the ROracle installation command resolved the problem:

    > install.packages("https://cran.r-project.org/src/contrib/ROracle_1.3-1.tar.gz", type="source", repos=NULL)

    Installing package into ‘C:/Users/slamonic/Downloads/Documents/R/win-library/3.6’

    (as ‘lib’ is unspecified)

    trying URL 'https://cran.r-project.org/src/contrib/ROracle_1.3-1.tar.gz'

    Content type 'application/x-gzip' length 308252 bytes (301 KB)

    downloaded 301 KB

    * installing *source* package 'ROracle' ...

    ** package 'ROracle' successfully unpacked and MD5 sums checked

    ** using staged installation

    Oracle Client Shared Library 64-bit - 18.5.0.0.0 Operating in Instant Client mode.

    found Instant Client C:\Users\slamonic\Downloads\instantclient_18_5

    found Instant Client SDK C:\Users\slamonic\Downloads\instantclient_18_5/sdk/include

    copying from C:\Users\slamonic\Downloads\instantclient_18_5/sdk/include

    ** libs

    Warning: this package has a non-empty 'configure.win' file,

    so building only the main architecture

    c:/Rtools/mingw_64/bin/gcc  -I"C:/PROGRA~1/R/R-36~1.1/include" -DNDEBUG -I./oci         -O2 -Wall  -std=gnu99 -mtune=generic -c rodbi.c -o rodbi.o

    c:/Rtools/mingw_64/bin/gcc  -I"C:/PROGRA~1/R/R-36~1.1/include" -DNDEBUG -I./oci         -O2 -Wall  -std=gnu99 -mtune=generic -c rooci.c -o rooci.o

    c:/Rtools/mingw_64/bin/gcc -shared -s -static-libgcc -o ROracle.dll tmp.def rodbi.o rooci.o C:\Users\slamonic\Downloads\instantclient_18_5/oci.dll -LC:/PROGRA~1/R/R-36~1.1/bin/x64 -lR

    installing to C:/Users/slamonic/Downloads/Documents/R/win-library/3.6/00LOCK-ROracle/00new/ROracle/libs/x64

    ** R

    ** inst

    ** byte-compile and prepare package for lazy loading

    ** help

    *** installing help indices

      converting help for package 'ROracle'

        finding HTML links ... done

        ExtDriver-class                         html

        OraConnection-class                     html

        OraDriver-class                         html

        OraResult-class                         html

        Oracle                                  html

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/Oracle.Rd:85: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/Oracle.Rd:85: file link 'dbRollback' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/Oracle.Rd:106: file link 'dbUnloadDriver' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/Oracle.Rd:128: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/Oracle.Rd:129: file link 'dbRollback' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/Oracle.Rd:133: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

        dbCommit-methods                        html

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbCommit-methods.Rd:54: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbCommit-methods.Rd:55: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbConnect-methods                       html

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbConnect-methods.Rd:165: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbConnect-methods.Rd:166: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbDriver-methods                        html

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbDriver-methods.Rd:88: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbDriver-methods.Rd:89: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbGetInfo-methods                       html

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbGetInfo-methods.Rd:279: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbGetInfo-methods.Rd:280: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbListConnections-methods               html

        dbReadTable-methods                     html

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbReadTable-methods.Rd:382: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbReadTable-methods.Rd:383: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbSendQuery-methods                     html

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbSendQuery-methods.Rd:88: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbSendQuery-methods.Rd:139: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/dbSendQuery-methods.Rd:140: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        fetch-methods                           html

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/fetch-methods.Rd:42: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        summary-methods                         html

    Rd warning: C:/Users/slamonic/AppData/Local/Temp/Rtmp4MMfBf/R.INSTALL4926c359233dc/ROracle/man/summary-methods.Rd:43: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

    ** building package indices

    ** testing if installed package can be loaded from temporary location

    ** testing if installed package can be loaded from final location

    ** testing if installed package keeps a record of temporary installation path

    * DONE (ROracle)

    > library(ROracle)

    > packageVersion("ROracle")

    [1] ‘1.3.1’

    --Sherry

  • 4046822
    4046822 Member Posts: 10
    edited Jul 23, 2019 2:02PM

    That lock file doesn't exist, so I can't delete it. I made sure all of the environment variables are set, and I have ociver.h in the include folder. The install, however, is still failing for me:

    R version 3.6.1 (2019-07-05) -- "Action of the Toes"

    Copyright (C) 2019 The R Foundation for Statistical Computing

    Platform: x86_64-w64-mingw32/x64 (64-bit)

    R is free software and comes with ABSOLUTELY NO WARRANTY.

    You are welcome to redistribute it under certain conditions.

    Type 'license()' or 'licence()' for distribution details.

    R is a collaborative project with many contributors.

    Type 'contributors()' for more information and

    'citation()' on how to cite R or R packages in publications.

    Type 'demo()' for some demos, 'help()' for on-line help, or

    'help.start()' for an HTML browser interface to help.

    Type 'q()' to quit R.

    > install.packages("https://cran.r-project.org/src/contrib/ROracle_1.3-1.tar.gz", type="source", repos=NULL)

    Installing package into ‘C:/<User directory>/R/win-library/3.6’

    (as ‘lib’ is unspecified)

    trying URL 'https://cran.r-project.org/src/contrib/ROracle_1.3-1.tar.gz'

    Content type 'application/x-gzip' length 308252 bytes (301 KB)

    downloaded 301 KB

    * installing *source* package 'ROracle' ...

    ** package 'ROracle' successfully unpacked and MD5 sums checked

    ** using staged installation

    C:/oreclient/instantclient_18_5/genezi.exe: error while loading shared libraries: ?: cannot open shared object file: No such file or directory

    C:/oreclient/instantclient_18_5/genezi.exe: error while loading shared libraries: ?: cannot open shared object file: No such file or directory

    ./configure.win: line 55: [: too many arguments

    ./configure.win: line 63: [: too many arguments

    Oracle

    found Instant Client C:\oreclient\instantclient_18_5

    found Instant Client SDK C:\oreclient\instantclient_18_5/sdk/include

    copying from C:\oreclient\instantclient_18_5/sdk/include

    ** libs

    Warning: this package has a non-empty 'configure.win' file,

    so building only the main architecture

    C:/Rtools/mingw_64/bin/gcc  -I"C:/PROGRA~1/R/R-36~1.1/include" -DNDEBUG -I./oci         -O2 -Wall  -std=gnu99 -mtune=generic -c rodbi.c -o rodbi.o

    C:/Rtools/mingw_64/bin/gcc  -I"C:/PROGRA~1/R/R-36~1.1/include" -DNDEBUG -I./oci         -O2 -Wall  -std=gnu99 -mtune=generic -c rooci.c -o rooci.o

    C:/Rtools/mingw_64/bin/gcc -shared -s -static-libgcc -o ROracle.dll tmp.def rodbi.o rooci.o C:\oreclient\instantclient_18_5/oci.dll -LC:/PROGRA~1/R/R-36~1.1/bin/x64 -lR

    installing to C:/<User directory>/R/win-library/3.6/00LOCK-ROracle/00new/ROracle/libs/x64

    ** R

    ** inst

    ** byte-compile and prepare package for lazy loading

    ** help

    *** installing help indices

      converting help for package 'ROracle'

        finding HTML links ... done

        ExtDriver-class                         html 

        OraConnection-class                     html 

        OraDriver-class                         html 

        OraResult-class                         html 

        Oracle                                  html 

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/Oracle.Rd:85: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/Oracle.Rd:85: file link 'dbRollback' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/Oracle.Rd:106: file link 'dbUnloadDriver' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/Oracle.Rd:128: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/Oracle.Rd:129: file link 'dbRollback' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/Oracle.Rd:133: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

        dbCommit-methods                        html 

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbCommit-methods.Rd:54: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbCommit-methods.Rd:55: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbConnect-methods                       html 

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbConnect-methods.Rd:165: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbConnect-methods.Rd:166: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbDriver-methods                        html 

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbDriver-methods.Rd:88: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbDriver-methods.Rd:89: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbGetInfo-methods                       html 

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbGetInfo-methods.Rd:279: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbGetInfo-methods.Rd:280: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbListConnections-methods               html 

        dbReadTable-methods                     html 

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbReadTable-methods.Rd:382: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbReadTable-methods.Rd:383: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        dbSendQuery-methods                     html 

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbSendQuery-methods.Rd:88: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbSendQuery-methods.Rd:139: file link 'fetch' in package 'DBI' does not exist and so has been treated as a topic

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/dbSendQuery-methods.Rd:140: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        fetch-methods                           html 

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/fetch-methods.Rd:42: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

        summary-methods                         html 

    Rd warning: C:/<User Temp directory>/RtmpwJdHig/R.INSTALL21146286fc6/ROracle/man/summary-methods.Rd:43: file link 'dbCommit' in package 'DBI' does not exist and so has been treated as a topic

    ** building package indices

    ** testing if installed package can be loaded from temporary location

    Error: package or namespace load failed for 'ROracle' in inDL(x, as.logical(local), as.logical(now), ...):

    unable to load shared object 'C:/<User directory>/R/win-library/3.6/00LOCK-ROracle/00new/ROracle/libs/x64/ROracle.dll':

      LoadLibrary failure:  The specified module could not be found.

    Error: loading failed

    Execution halted

    ERROR: loading failed

    * removing 'C:/<User directory>/R/win-library/3.6/ROracle'

    Warning in install.packages :

      installation of package ‘C:/<User Temp directory>/RtmpIdMUek/downloaded_packages/ROracle_1.3-1.tar.gz’ had non-zero exit status

  • Sherry Lamonica-Oracle
    Sherry Lamonica-Oracle Posts: 437 Employee
    edited Jul 23, 2019 2:08PM

    It seems the lock file is actually a directory:

    C:/<User directory>/R/win-library/3.6/00LOCK-ROracle

    You may need to remove it as Administrator:

    Can you please try installing using the command "R CMD INSTALL ROracle_1.3-1.tar.gz --no-clean-on-exit" and then if you receive an error, check to see if  ROracle.dll in 'C:/<User directory>/R/win-library/3.6/ROracle/libs/x64/ROracle.dll' exists?

    --Sherry

  • 4046822
    4046822 Member Posts: 10
    edited Jul 23, 2019 2:31PM

    That lock file/folder doesn't exist, even after trying to find it by making sure hidden items are shown in File Explorer and by getting to that directory via Command Prompt as an admin.

    I did try that command, but "--no-clean-on-exit" is an unknown option. I did find "--no-clean-on-error", though, so I ran "R CMD INSTALL --no-clean-on-error ROracle_1.3-1.tar.gz" from my Downloads directory after downloading that .gz file. After doing so, "'C:/<User directory>/R/win-library/3.6/ROracle" exists but is an empty folder.

  • Sherry Lamonica-Oracle
    Sherry Lamonica-Oracle Posts: 437 Employee
    edited Jul 23, 2019 4:18PM

    You are correct, the correct flag is indeed "--no-clean-on-error".  Does it make a difference if you first untar/unzip ROracle_1.3-1.tar.gz and then install the uncompressed file directly?

    R CMD INSTALL ROracle_1.3-1  ?

    Thanks,Sherry

  • 4046822
    4046822 Member Posts: 10
    edited Jul 23, 2019 4:28PM

    Untar/unzip gives me a folder called ROracle, instead of ROracle_1.3-1, but no, doing that does not make a difference.

  • 4046822
    4046822 Member Posts: 10
    edited Jul 30, 2019 9:26AM

    Do we have any other things to try? It's been a week since the last idea for resolution was offered.

  • Sherry Lamonica-Oracle
    Sherry Lamonica-Oracle Posts: 437 Employee
    edited Jul 30, 2019 4:23PM

    It seems that R is identifying a lock file or directory in your R library path: 'C:/<User directory>/R/win-library/3.6/00LOCK-ROracle, even though you cannot see it with hidden files/folders enabled.  I don't know the reason this is happening, but here are a few things you can try:

    From R, execute unlink to remove it, if it even exists:

    R> unlink("C:/<User directory>/R/win-library/3.6/00LOCK-ROracle")

    Restart R, and try the ROracle installation again.

    If that doesn't work install ROracle to a different location by setting your R library path to another location, e.g.:

    R> .libPaths("<another path where your user has write acess">)

    --Sherry