This chapter explains how to install Oracle R Enterprise Client. This chapter includes these topics:
Oracle R Enterprise includes several components that must be installed separately on each client computer.
Components of Oracle R Enterprise Client
Oracle Database Client Software
Oracle R Enterprise packages
Oracle R Enterprise supporting packages
The Oracle R Enterprise client components can be installed in any order:
See Also:
Figure 1-2 for an illustration of the client and server components of Oracle R Enterprise.ROracle, one of the supporting packages used by Oracle R Enterprise, requires an installation of Oracle Database client software to enable communication between an R client and an Oracle database. The Database client can be either Oracle Database Client or Oracle Database Instant Client:
Oracle Database Client is distributed with Oracle Database and is based in the Oracle home of the database.
Oracle Database Instant Client is a free, standalone implementation of Oracle Database Client. Oracle Instant Client is not based in an Oracle home directory and requires less disk space than Oracle Database Client.
The Oracle R Enterprise packages, shown in Table 6-1, are a set of Oracle proprietary packages that support Oracle R Enterprise. These packages are required on each client computer and on the server computer that hosts Oracle R Enterprise Server. On the server, the Oracle R Enterprise packages are installed automatically by the Oracle R Enterprise Server installation script.
Table 6-1 Oracle R Enterprise Packages
Package Name | Description |
---|---|
The top-level package for Oracle R Enterprise. |
|
|
Corresponds to the open source R |
|
Contains common low-level functionality for Oracle R Enterprise |
|
Exposes Oracle Data Mining algorithms through R. |
|
Contains functions for exploratory data analysis. |
|
Supports embedded R |
|
Corresponds to the open source R |
|
Contains functions for advanced analytical modeling. |
|
Enables scoring data in Oracle Database using R models. |
|
Corresponds to the open source R |
|
Supports XML translation between R and Oracle Database. |
The supporting packages, shown in Table 6-2, are a set of open source packages that support the Oracle R Enterprise packages.
Table 6-2 Oracle R Enterprise Supporting Packages
Package Name | Description |
---|---|
|
Provides the infrastructure for representing, manipulating and analyzing transactional data and patterns (frequent itemsets and association rules) |
|
Supports graphic rendering on Oracle R Enterprise server. |
|
A database interface definition for communication between R and Oracle Database. |
|
Supports the reading and writing of PNG images for Oracle R Enterprise objects. |
Oracle Database interface for R-based OCI. |
|
|
Provides statistical modeling functions, including growth curve comparisons, limiting dilution analysis, mixed linear models, heteroscedastic regression, Tweedie family generalized linear models, the inverse-Gaussian distribution and Gauss quadrature |
As described in Section 6.1.1, Oracle R Enterprise requires Oracle Database client software. Oracle Instant Client is suitable for most configurations of Oracle R Enterprise.
This topic includes these sections:
Section 6.2.1, "Installing Oracle Database Instant Client on Windows"
Section 6.2.2, "Installing Oracle Database Instant Client on Linux or UNIX"
To Install Oracle Instant Client on Windows:
Create an installation directory for the Oracle R Enterprise client components. For example:
c:\oreclient_install_dir
Go to the Oracle Database Instant Client page on the Oracle Technology Network:
http://www.oracle.com/technetwork/database/features/instant-client/
Select See Instant Client downloads for all platforms.
On the Instant Client Downloads page, select Instant Client for Microsoft Windows (x64).
On the Instant Client Downloads for Microsoft Windows (x64) page, accept the license agreement.
Choose Instant Client Package - Basic for your version of Oracle Database.
Save the file in the installation directory that you created in Step 1. For example:
c:\oreclient_install_dir\instantclient-basic-windows.x64-12.1.0.1.0.zip
Unzip the file.The files are extracted into a subdirectory called instantclient_
version
, where version
is your version of Oracle Database. For example:
c:\oreclient_install_dir\instantclient_12_1
Return to the Instant Client Downloads for Microsoft Windows (x64) page:
http://www.oracle.com/technetwork/topics/winx64soft-089540.html
Accept the license agreement and select Instant Client Package - SDK for your version of Oracle Database.
Save the file in the installation directory that you created in Step 1.
c:\oreclient_install_dir\instantclient-sdk-windows.x64-12.1.0.1.0.zip
Unzip the file. The files are extracted into the instantclient_
version
subdirectory. An Instant Client installation directory for Oracle Database 12.1 is shown in Figure 6-1
Figure 6-1 An Instant Client Installation Directory for Oracle Database 12.1
Add the full path of the Instant Client to the environment variables OCI_LIB64
and PATH
. The following steps set the variables to the path used in this example, c:\myoreclient\instantclient_12_1
:
In Windows Control Panel, choose System, then click Advanced system settings.
On the Advanced tab, click Environment Variables.
Under System variables, create OCI_LIB64
if it does not already exist. Set the value of OCI_LIB64
to c:\oreclient\instantclient_12_1
.
Under System variables, edit PATH
to include c:\oreclient\instantclient_12_1
.
You can install Oracle Database Instant Client from a zip file on Linux or UNIX systems. On Linux, you can also install from RPMs.
This topic includes these sections:
Section 6.2.2.1, "Installing Oracle Instant Client from a Zip File"
Section 6.2.2.2, "Installing Oracle Instant Client on Linux from RPMs"
Create an installation directory for the Oracle R Enterprise client components. For example:
mkdir oreclient_install_dir
Go to the Oracle Database Instant Client page on the Oracle Technology Network:
http://www.oracle.com/technetwork/database/features/instant-client/
Select See Instant Client downloads for all platforms. On the Instant Client Downloads page, select the Instant Client for your platform.
Accept the license agreement and select the Instant Client Package - Basic RPM for your version of Oracle Database.
Save the file in the installation directory that you created in Step 1. For example:
\oreclient_install_dir\instantclient-basic-linux.x64-12.1.0.1.0.zip
Unzip the file. The files are extracted into a subdirectory called instantclient_
version
, where version
is your version of Oracle Database. For example:
unzip instantclient-basic-linux.x64-12.1.0.1.0.zip ls instantclient_12_1/ instantclient-basic-linux.x64-12.1.0.1.0.zip
Return to the Instant Client Downloads page:
http://www.oracle.com/technetwork/database/features/instant-client/index-097480.html
Select the Instant Client for your platform.
On the Instant Client Downloads page for your platform, accept the license agreement and select Instant Client Package - SDK for your version of Oracle Database.
Save the file in the installation directory that you created in Step 1. For example:
\oreclient_install_dir\instantclient-sdk-linux.x64-12.1.0.1.0.zip
Unzip the file. The contents are extracted into the instantclient_
version
subdirectory.
unzip instantclient-sdk-linux.x64-12.1.0.1.0.zip ls /instantclient_12_1 instantclient-basic-linux.x64-12.1.0.1.0.zip instantclient-sdk-linux.x64-12.1.0.1.0.zip cd instantclinet_12_1 ls /help /sdk /vc10 /vc11
Create an installation directory for the Oracle R Enterprise client components. For example:
mkdir oreclient_install_dir
Go to the Oracle Database Instant Client page on the Oracle Technology Network:
http://www.oracle.com/technetwork/database/features/instant-client/
Choose See Instant Client downloads for all platforms.
On the Instant Client Downloads page, choose Instant Client for Linux x86-64.
On the Instant Client Downloads page for Linux, accept the license agreement and select the RPM for Instant Client Package - Basic.
As the root user, install the RPM:
rpm -i oracle-instantclient12.1-basic-12.1.0.1.0-1.x86_64.rpm
Return to the Instant Client Downloads page for Linux x86-64:
http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html
Accept the license agreement and download the RPM for Instant Client Package - SDK for your version of Oracle Database. As root, install the RPM:
rpm -i oracle-instantclient12.1-sdk-12.1.0.1.0-1.x86_64.rpm
The RPMs place the files in standard locations that the ROracle configuration script can find. For example, Oracle Instant Client 12.1 is installed in/usr/lib/oracle/12.1/client64/lib
.
After installing Oracle Instant Client, add the path of the Oracle Instant Client libraries to LD_LIBRARY_PATH
. For example:
export LD_LIBRARY_PATH=/usr/lib/oracle/12.1/client64/lib:$LD_LIBRARY_PATH
Install the Oracle R Enterprise packages on each client computer. The Oracle R Enterprise packages are automatically included in the installation on the server.
This topic includes these sections:
Section 6.3.1, "Installing the Oracle R Enterprise Packages on Windows"
Section 6.3.2, "Installing the Oracle R Enterprise Packages on Linux or UNIX"
Download the Oracle R Enterprise packages from the Oracle R Enterprise Downloads page on the Oracle Technology Network:
http://www.oracle.com/technetwork/database/options/advanced-analytics/r-enterprise/ore-downloads-1502823.html
Accept the license agreement and select the Oracle R Enterprise packages for your platform. Download the zip file to the installation directory that you created for Oracle Instant Client. For example:
c:\oreclient_install_dir\ore-client-win-x86_64-1.4.1.1.zip
NOTE: Choose the same installation directory for all Oracle R Enterprise client components.
Unzip the file. The contents are extracted into the client
subdirectory:
The resulting installation directory, shown in Example 6-1, contains Oracle Instant Client and the Oracle R Enterprise packages.
Example 6-1 Client Installation Directory Containing Client Packages and Instant Client
c:\oreclient_install_dir \client \ORE_1.4.1.zip \OREbase_1.4.1.zip \OREcommon_1.4.1.zip \OREdm_1.4.1.zip \OREeda_1.4.1.zip \OREembed_1.4.1.zip \OREgraphics_1.4.1.zip \OREmodels_1.4.1.zip \OREpredict_1.4.1.zip \OREstats_1.4.1.zip \ORExml_1.4.1.zip \instantclient_12_1 instantclient-basic-linux.x64-12.1.0.1.0.zip instantclient-sdk-linux.x64-12.1.0.1.0.zip ore-client-win-x86_64-1.4.1.zip
Choose one of the following methods to install the Oracle R Enterprise packages on Windows:
Install from the R Console
Start R x64 from the Windows Start menu.
Execute this R command for each zip file in the client
directory:
install.packages("oreclient_install_dir/client/client_package_name.zip', repos=NULL)
Each successful package installation produces this message in the R console:
package 'package_name' successfully unpacked and MD5 sums checked
Install from the R GUI
Start R x64 from the Windows Start menu.
Select Packages from the RGui (64-bit) menu bar.
From the Packages menu, select Install package(s) from local zip files.
Change to the client
directory.
Select all the files in the directory.
Click Open.
Each package installation produces this message in the R console:
package 'package_name' successfully unpacked and MD5 sums checked
Install from the Windows command prompt
Start R x64 from the Windows Start menu.
Open a Windows command window.
Change directory to the client
directory and type these commands:
R CMD INSTALL OREbase_1.4.1.zip R CMD INSTALL OREcommon_1.4.1.zip R CMD INSTALL OREstats_1.4.1.zip R CMD INSTALL OREgraphcs_1.4.1.zip R CMD INSTALL OREeda_1.4.1.zip R CMD INSTALL OREembed_1.4.1.zip R CMD INSTALL ORExml_1.4.1.zip R CMD INSTALL OREdm_1.4.1.zip R CMD INSTALL OREmodels_1.4.1.zip R CMD INSTALL OREpredict_1.4.1.zip R CMD INSTALL ORE_1.4.1.zip
Each package installation generates this message:
package 'package_name' successfully unpacked and MD5 sums checked
Download the Oracle R Enterprise packages from the Oracle R Enterprise Downloads page on the Oracle Technology Network:
http://www.oracle.com/technetwork/database/options/advanced-analytics/r-enterprise/ore-downloads-1502823.html
Accept the license agreement and select the Oracle R Enterprise packages for your platform. Download the zip file to the installation directory that you created for Oracle Instant Client. For example:
/oreclient_install_dir/ore-client-platform-arch-1.4.1.1.zip
NOTE: Choose the same installation directory for all Oracle R Enterprise client components.
Unzip the file:
% unzip ore-client-platform-arch-1.4.1.zip
When you unzip the file, the /client
directory is created and these files are extracted.
/client/ORE_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/OREbase_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/OREcommon_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/OREdm_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/OREeda_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/OREembed_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/OREgraphics_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/OREmodels_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/OREpredict_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/OREstats_1.4.1_R_arch-unknown-platform-gnu.tar.gz /client/ORExml_1.4.1_R_arch-unknown-platform-gnu.tar.gz
Change to /
oreclient_install_dir
/client
.
Execute the following commands:
R CMD INSTALL ORE_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL OREbase_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL OREcommon_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL OREdm_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL OREeda_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL OREembed_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL OREgraphics_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL OREmodels_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL OREpredict_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL OREstats_1.4.1_R_arch-unknown-platform-gnu.tar.gz R CMD INSTALL ORExml_1.4.1_R_arch-unknown-platform-gnu.tar.gz
Install the Oracle R Enterprise supporting packages on each client computer and on the server that hosts Oracle R Enterprise Server.
This topic includes these sections:
Section 6.4.1, "Installing the Supporting Packages on Windows"
Section 6.4.2, "Installing the Supporting Packages on Linux or UNIX"
Download the supporting packages from the Oracle R Enterprise Downloads page on the Oracle Technology Network:
http://www.oracle.com/technetwork/database/options/advanced-analytics/r-enterprise/ore-downloads-1502823.html
Accept the license agreement and select the Supporting packages for your platform. Download the zip file to the installation directory that you created for Oracle Instant Client. For example:
c:\oreclient_install_dir\ore-supporting-win-x86_64-1.4.1.1.zip
NOTE: Choose the same installation directory for all Oracle R Enterprise client components.
Unzip the file. The contents are extracted into the supporting
subdirectory:
The resulting installation directory, shown in Example 6-2, contains all the client components: Oracle Instant Client, Oracle R Enterprise packages, and Oracle R Enterprise supporting packages.
Example 6-2 Client Installation Directory Containing All Client Components
c:\oreclient_install_dir \client \instantclient_12_1 \supporting \arules_1.1-3.zip \Cairo_1.5-5.zip \DBI_0.2-7.zip \png_0.1-7.zip \ROracle_1.1-12.zip \statmod_1.4.20.zip instantclient-basic-linux.x64-12.1.0.1.0.zip instantclient-sdk-linux.x64-12.1.0.1.0.zip ore-client-win-x86_64-1.4.1.zip ore-supporting-win-x86_64-1.4.1.zip
Choose one of the following methods to install the supporting packages on Windows:
Install from the R Console
Start R x64 from the Windows Start menu.
Execute this R command for each zip file in the client
directory:
install.packages("oreclient_install_dir/support/support_package_name.zip', repos=NULL)
Each successful package installation produces this message in the R console:
package 'package_name' successfully unpacked and MD5 sums checked
Install from the R GUI
Start R x64 from the Windows Start menu.
Select Packages from the RGui (64-bit) menu bar.
From the Packages menu, select Install package(s) from local zip files.
Change to the support
directory.
Select all the files in the directory.
Click Open.
Each package installation produces this message in the R console:
package 'package_name' successfully unpacked and MD5 sums checked
Install from the Windows command prompt
Start R x64 from the Windows Start menu.
Open a Windows command window.
Change directory to the client
directory and type these commands:
R CMD INSTALL ROracle_1.1-12.zip R CMD INSTALL DBI_0.2-7.zip R CMD INSTALL png_0.1-7.zip R CMD INSTALL Cairo_1.5-5.zip R CMD INSTALL arules_1.1-3.zip R CMD INSTALL statmod_1.4.20.zip
Each package installation generates this message:
package 'package_name' successfully unpacked and MD5 sums checked
Download the Oracle R Enterprise packages from the Oracle R Enterprise Downloads page on the Oracle Technology Network:
http://www.oracle.com/technetwork/database/options/advanced-analytics/r-enterprise/ore-downloads-1502823.html
Accept the license agreement and select the Supporting packages for your platform. Download the zip file to the installation directory that you created for Oracle Instant Client. For example:
/oreclient_install_dir/ore-supporting-platform-arch-1.4.1.1.zip
NOTE: Choose the same installation directory for all Oracle R Enterprise client components.
Unzip the file:
% unzip ore-supporting-platform-arch-1.4.1.zip
When you unzip the file, the /supporting
directory is created and these files are extracted.
/supporting/arules_1.1-3_R_arch-unknown-platform.tar.gz /supporting/Cairo_1.5-5_R_arch-unknown-platform.tar.gz /supporting/DBI_0.2-7_R_arch-unknown-platform.tar.gz /supporting/png_0.1-7_R_arch-unknown-platform.tar.gz /supporting/ROracle_1.1-12_R_arch-unknown-platform.tar.gz /supporting/statmod_1.4.20_R_arch-unknown-platform.tar.gz
Change to /
oreclient_install_dir
/supporting
Execute the following commands:
R CMD INSTALL ROracle_1.1-12_R_arch-unknown-platform.tar.gz R CMD INSTALL DBI_0.2-7_R_arch-unknown-platform.tar.gz R CMD INSTALL png_0.1-7_R_arch-unknown-platform.tar.gz R CMD INSTALL Cairo_1.5-5_R_arch-unknown-platform.tar.gz R CMD INSTALL arules_1.1-3_R_arch-unknown-platform.tar.gz R CMD INSTALL statmod_1.4.20_R_arch-unknown-platform.tar.gz
To connect Oracle R Enterprise Client to Oracle R Enterprise Server, start R using the ORE script:
% ORE R> library(ORE)
The following examples connect as user RQUSER
with password RQUSERpsw
:
For a remote database, specify the Oracle Database service identifier (SID), the host name, and the port for the connection.
ore.connect(user="RQUSER", sid="orcl", host="SVR3", password="RQUSERpsw", port=1521, all=TRUE)
Note:
To avoid specifying the password and other connection details in embedded R scripts, you can use Oracle Wallet. See Section 7.7, "Creating an Oracle Wallet for an Oracle R Enterprise Connection".For a local database, specify the connection as follows:
ore.connect("RQUSER", password="RQUSERpsw", conn_string="", all=TRUE)
See Also:
Oracle R Enterprise User's Guide for details about connecting to Oracle R Enterprise Server.