Oracle® R Enterprise Installation and Administration Guide Release 1.3.1 for Windows, Linux, Solaris, and AIX E36763-17 |
|
|
PDF · Mobi · ePub |
This chapter explains how to install R for Oracle R Enterprise. This chapter contains these topics:
Oracle R Enterprise requires an installation of R on the computer that hosts Oracle R Enterprise Server and on each computer that hosts an Oracle R Enterprise client. If you intend to use Oracle R Enterprise directly on the server, then only one installation of R is necessary.
See Also:
Table 1-2, "Oracle R Enterprise Server Support Matrix" for the versions of R that are supported with Oracle R EnterpriseOracle recommends that you use Oracle R Distribution with Oracle R Enterprise Server. Oracle R Distribution is configured to simplify installation, resolve dependencies, and easily integrate with the Intel Math Kernel Library (MKL).
Benefits of Oracle R Distribution:
Oracle R Distribution is compiled with the flags that are required by Oracle R Enterprise server components.
Oracle R Distribution uses MKL to provide high performance mathematical computations on x86 hardware. If you have a licensed installation of MKL, you can configure Oracle R Distribution to use it by simply adding it to LD_LIBRARY_PATH
path and setting one environment variable. See Section 3.6 for details.
You can use open source R with Oracle R Enterprise. Use the following R configuration parameters to build it from source:
./configure --with-lapack --with-ICU=no --enable-R-shlib
See Also:
The R Installation and Administration manual for information about building R from source: http://www.r-project.org/
Section 3.7 for information about installing open source R on Windows
Oracle recommends that you use the Oracle Public Yum server for installing R on Linux. Oracle Public Yum is located at the following URL:
http://public-yum.oracle.com/
These topics explain how to install Oracle R Distribution on Linux systems:
Before installing Oracle R Distribution, verify that your version of Oracle Linux is supported by Oracle R Enterprise. Refer to Table 1-1, "Oracle R Enterprise Platform Requirements".
To install Oracle R Distribution on Oracle Linux Using Yum:
Log in to the Linux server as root and change to the /etc/yum.repos.d
directory:
# cd /etc/yum.repos.d
Execute the following command to download the yum configuration file from Oracle Public Yum:
# wget http://public-yum.oracle.com/public-yum-xxx.repo
The name of the configuration file is public-yum-
xxx
.repo
, where xxx
is either el5
, for Oracle Linux 5, or 0l6
., for Oracle Linux 6
Note: If the yum configuration file is already present in /etc/yum.d
, then you can skip this step.
Open the configuration file in a text editor and specify enabled=1
for xxx
_latest
and xxx
_addons
, where xxx
indicates the version of Linux, either el5
or ol6
:
[xxx_latest] enabled=1 [xxx_addons] enabled=1
Execute the yum install
command to install R.
To install R-2.15.3:
# yum install R-2.15.3
To install the most recent version of R that is available on Oracle Public Yum:
# yum install R.x86_64
Important:
Do not assume that the most recent version of R on Oracle Public Yum is supported by your version of Oracle R Enterprise. Consult Table 1-2, "Oracle R Enterprise Server Support Matrix" to determine which version of R you should use.Oracle recommends that you use yum to install Oracle R Distribution. However, if yum is not available, you can install Oracle R Distribution using RPMs.
Before installing Oracle R Distribution, verify that your version of Oracle Linux is supported by Oracle R Enterprise. Refer to Table 1-1, "Oracle R Enterprise Platform Requirements".
To download and install the RPMs for Oracle Linux 5, execute the commands shown in Example 3-1. To download and install the RPMs for Oracle Linux 6, execute these same commands but replace el5
with ol6
. Note that these RPMs may have dependencies that need resolving.
# rpm -Uvh libXdmcp-devel-1.0.1-2.1.x86_64.rpm # rpm -Uvh libXau-devel-1.0.1-3.1.x86_64.rpm # rpm -Uvh R-2.15.3-1.el5.x86_64.rpm # rpm -Uvh chkfontpath-1.10.1-1.1.x86_64.rpm # rpm -Uvh libfontenc-1.0.2-2.2.el5.x86_64.rpm # rpm -Uvh libRmath-devel-2.15.3-1.el5.x86_64.rpm # rpm -Uvh avahi-compat-libdns_sd-0.6.16-10.el5_6.x86_64.rpm # rpm -Uvh hicolor-icon-theme-0.9-2.1.noarch.rpm # rpm -Uvh libFS-1.0.0-3.1.x86_64.rpm # rpm -Uvh paps-0.6.6-20.el5.x86_64.rpm # rpm -Uvh bzip2-devel-1.0.3-6.el5_5.x86_64.rpm # rpm -Uvh ttmkfdir-3.0.9-23.el5.x86_64.rpm # rpm -Uvh ed-0.2-39.el5_2.x86_64.rpm # rpm -Uvh zlib-1.2.3-7.el5.i386.rpm # rpm -Uvh zlib-1.2.3-7.el5.x86_64.rpm # rpm -Uvh desktop-file-utils-0.10-7.x86_64.rpm # rpm -Uvh xorg-x11-xfs-1.0.2-5.el5_6.1.x86_64.rpm # rpm -Uvh poppler-utils-0.5.4-19.el5.x86_64.rpm # rpm -Uvh xorg-x11-font-utils-7.1-3.x86_64.rpm # rpm -Uvh R-devel-2.15.3-1.el5.x86_64.rpm # rpm -Uvh libgcc-4.1.2-54.el5.i386.rpm # rpm -Uvh libgcc-4.1.2-54.el5.x86_64.rpm # rpm -Uvh zlib-devel-1.2.3-7.el5.x86_64.rpm # rpm -Uvh libRmath-2.15.3-1.el5.x86_64.rpm # rpm -Uvh dialog-1.0.20051107-1.2.2.x86_64.rpm # rpm -Uvh pcre-devel-6.6-6.el5_6.1.x86_64.rpm # rpm -Uvh dbus-python-0.70-9.el5_4.x86_64.rpm # rpm -Uvh cups-libs-1.3.7-30.el5_9.3.x86_64.rpm # rpm -Uvh gmp-4.1.4-10.el5.x86_64.rpm # rpm -Uvh atk-1.12.2-1.fc6.x86_64.rpm # rpm -Uvh libgfortran-4.1.2-52.el5_8.1.i386.rpm # rpm -Uvh libgfortran-4.1.2-54.el5.x86_64.rpm # rpm -Uvh libXfont-1.2.2-1.0.4.el5_7.x86_64.rpm # rpm -Uvh xorg-x11-proto-devel-7.1-13.el5.x86_64.rpm # rpm -Uvh avahi-0.6.16-10.el5_6.x86_64.rpm # rpm -Uvh libtiff-3.8.2-18.el5_8.x86_64.rpm # rpm -Uvh pango-1.14.9-8.0.1.el5_7.3.x86_64.rpm # rpm -Uvh bitstream-vera-fonts-1.10-7.noarch.rpm # rpm -Uvh libstdc++-4.1.2-54.el5.x86_64.rpm # rpm -Uvh libstdc++-4.1.2-54.el5.i386.rpm # rpm -Uvh cairo-1.2.4-5.el5.x86_64.rpm # rpm -Uvh mesa-libGL-devel-6.5.1-7.11.el5_9.x86_64.rpm # rpm -Uvh tetex-dvips-3.0-33.15.el5_8.1.x86_64.rpm # rpm -Uvh libX11-devel-1.0.3-11.el5_7.1.x86_64.rpm # rpm -Uvh ghostscript-fonts-5.50-13.1.1.noarch.rpm # rpm -Uvh tk-devel-8.4.13-5.el5_1.1.x86_64.rpm # rpm -Uvh netpbm-10.35.58-10.el5.x86_64.rpm # rpm -Uvh tcl-devel-8.4.13-6.el5.x86_64.rpm # rpm -Uvh tcl-8.4.13-6.el5.x86_64.rpm # rpm -Uvh netpbm-progs-10.35.58-10.el5.x86_64.rpm # rpm -Uvh libstdc++-devel-4.1.2-54.el5.x86_64.rpm # rpm -Uvh libstdc++-devel-4.1.2-54.el5.i386.rpm # rpm -Uvh cpp-4.1.2-54.el5.x86_64.rpm # rpm -Uvh poppler-0.5.4-19.el5.x86_64.rpm # rpm -Uvh cups-1.3.7-30.el5_9.3.x86_64.rpm # rpm -Uvh gcc-gfortran-4.1.2-54.el5.x86_64.rpm # rpm -Uvh gcc-c++-4.1.2-54.el5.x86_64.rpm # rpm -Uvh tetex-latex-3.0-33.15.el5_8.1.x86_64.rpm # rpm -Uvh urw-fonts-2.3-6.1.1.noarch.rpm # rpm -Uvh gcc-4.1.2-54.el5.x86_64.rpm # rpm -Uvh gtk2-2.10.4-29.el5.x86_64.rpm # rpm -Uvh mesa-libGL-6.5.1-7.11.el5_9.x86_64.rpm # rpm -Uvh tetex-3.0-33.15.el5_8.1.x86_64.rpm # rpm -Uvh ghostscript-8.70-14.el5_8.1.x86_64.rpm # rpm -Uvh tetex-fonts-3.0-33.15.el5_8.1.x86_64.rpm # rpm -Uvh R-core-2.15.3-1.el5.x86_64.rpm # rpm -Uvh libRmath-2.15.3-1.el5.x86_64.rpm
Before installing Oracle R Distribution, verify that your version of Red Hat Enterprise Linux is supported by Oracle R Enterprise. Refer to Table 1-1, "Oracle R Enterprise Platform Requirements".
Note:
The following installation instructions are specific to Red Hat Enterprise Linux 6. For Red Hat Enterprise Linux 5, changeol6
to el5
.To install Oracle R Distribution on Red Hat Enterprise Linux 6:
Create an RPM build directory structure:
% mkdir -p ~/rpmbuild/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
Set up RPM tools to use your own build tree (to avoid root
login):
% echo '%_topdir %(echo $HOME)/rpmbuild' > ~/.rpmmacros
Download the source RPMs (*.src.rpm
) from Oracle Public Yum. For Red Hat Enterprise Linux 6:
http://public-yum.oracle.com/repo/OracleLinux/OL6/
Save the source RPMs to the rpmbuild/SRPMS
directory.
Rebuild Red Hat Enterprise Linux using rpmbuild
.
% rpmbuild --rebuild ~/rpmbuild/SRPMS/R-2.15.3-1.el6.src.rpm
Note:
If any dependencies are missing, install them as root.The binary RPMs are built and saved under ~/rpmbuild/RPMS.
Log in as root and execute this command to install R:
# rpm -i path/rpmbuild/RPMS/R-core_RPM
For example, this command installs R 2.15.3 on Red Hat Enterprise Linux x86-64 version 6, where the path to rpmbuild
is /refresh/home/
.
# rpm -i /refresh/home/rpmbuild/RPMS/x86_64/R-core-2.15.3-1.el6.x86_64.rpm
Oracle R Distribution is supported on Oracle Solaris x86-64 and SPARC. Before installing Oracle R Distribution, verify that your version of Oracle Solaris is supported by Oracle R Enterprise. Refer to Table 1-1, "Oracle R Enterprise Platform Requirements".
To install Oracle R Distribution on Oracle Solaris:
Go to the Oracle Open Source Software Download page for Oracle R Distribution:
Download the files for your installation. The following are the files for R-2.15.3:
For x86 64-bit systems:
ord-2.15.3-sol10-x86-64-sunstudio12u3.tar.gz ord-2.15.3-supporting-sol10-x86-64-sunstudio12u3.tar.gz
For SPARC 64-bit systems:
ord-2.15.3-sol10-sparc-64-sunstudio12u3.tar.gz ord-2.15.3-supporting-sol10-sparc-64-sunstudio12u3.tar.gz
Uncompress the first file, either sol110-x86-64
or sol10-sparc
.
Run install.sh
as root to install the Solaris PKG file for Oracle R Distribution.
# install.sh
Uncompress the second file, either supporting-sol10-x86-64
or supporting-sol10-sparc
, to a local directory such as $ORACLE_HOME/lib
. Add that directory to $LD_LIBRARY_PATH
.
These tar files contain the shared libraries for libR.so
:
libiconv.so.2
libncurses.so.5
libreadline.so.6
libsunperf.so
(This library and its dependent shared libraries usually ship with Oracle Solaris Studio).
Run the following command to verify that libR.so
is picking up its shared library dependencies correctly from the local directory.
# ldd -r /usr/lib/64/R/lib/libR.so
Start R by typing R
at the command prompt:
% R
Oracle R Distribution is supported on IBM AIX. Before installing Oracle R Distribution, verify that your version of IBM AIX is supported by Oracle R Enterprise. Refer to Table 1-1, "Oracle R Enterprise Platform Requirements".
To install Oracle R Distribution on IBM AIX:
Go to the Oracle Open Source Software Download page for Oracle R Distribution:
Download the files for your installation. The following are the files for R-2.15.3:
ORD.2.15.3.0.bff.gz ord-supporting-aix.tar.gz
Uncompress and untar ord-supporting-aix.tar.gz
:
$ gunzip ord-supporting-aix.tar.gz # get ord-supporting-aix.tar $ tar -xvf ord-supporting-aix.tar # extract contents of .tar file $ ls ord-supporting-aix # list of rpms bash-4.2-5.aix5.1.ppc.rpm expat-2.0.1-3.aix5.1.ppc.rpm gettext-0.17-1.aix5.1.ppc.rpm glib2-2.28.6-1.aix5.1.ppc.rpm info-4.13a-2.aix5.1.ppc.rpm libiconv-1.14-1.aix5.1.ppc.rpm libpng-1.5.9-1.aix5.1.ppc.rpm libpng-devel-1.5.9-1.aix5.1.ppc.rpm pkg-config-0.25-2.aix5.1.ppc.rpm readline-6.2-3.aix5.1.ppc.rpm readline-devel-6.2-3.aix5.1.ppc.rpm texinfo-4.13a-2.aix5.1.ppc.rpm zlib-1.2.6-1.aix5.1.ppc.rpm zlib-devel-1.2.6-1.aix5.1.ppc.rpm
You can also download these RPMs from http://www.perzl.org/aix/
.
Install the RPMs as root using an rpm
command:
$ cd /download_directory
$ su
# rpm -i *.rpm
To upgrade existing dependencies, use:
# rpm -UF *.rpm
If you experience conflicts with dependencies, use:
# rpm -UF --nodeps *.rpm
Add /opt/freeware/lib
to the LIBPATH
environment variable:
For ksh:
$ export LIBPATH=/opt/freeware/lib:$LIBPATH
For csh:
$ setenv LIBPATH /opt/freeware/lib:$LIBPATH
Ensure that /opt/freeware/lib
is before /usr/lib
.
Uncompress ORD-2.15.1-aix.bff.gz
to get ORD-2.15.1-aix.bff:
$ gunzip ORD.2.15.1.0.bff.gz
To install all of the filesets in Oracle R Distribution, execute the installp
command (with the apply option) as root:
$ cd /download_directory
$ su
# installp -a -d . ORD # install all the filesets in ORD
You can also install independent filesets:
# installp -a -d . ORD.core # installs only ORE.core # installp -a -d . ORD.devel # installs only ORE.devel
Run ldd
to ensure that shared library dependencies were picked up correctly:
$ ldd /usr/lib/R/bin/exec/R $ ldd /usr/lib/R/lib/libR.so (libiconv, libreadline) $ ldd /usr/lib/R/lib/libRlapack.so $ ldd /usr/lib/R/lib/libRblas.so
Add /usr/lib/R/lib
to the LIBPATH
environment variable:
For ksh:
$ export LIBPATH=/usr/lib/R/lib:$LIBPATH
For csh:
$ setenv LIBPATH /usr/lib/R/lib:$LIBPATH
Oracle recommends that you use Oracle R Distribution for Oracle R Enterprise on Exadata. You must install R on each Exadata node.
For Linux systems, Oracle recommends that you install Oracle R Distribution from Oracle Public Yum:
Refer to the instructions in Section 3.2, "Installing Oracle R Distribution on Linux".
For Oracle Solaris systems, Oracle recommends that you install Oracle R Distribution from the Open Source Software Downloads page on the Oracle Technology Network:
Refer to the instructions in Section 3.3, "Installing Oracle R Distribution on Oracle Solaris".
The Intel Math Kernel Library (MKL) includes highly vectorized and threaded Linear Algebra, Fast Fourier Transforms (FFT), Vector Math and Statistics functions. Oracle R Distribution includes support that dynamically picks up MKL if it is installed on your system.
Follow these steps to use MKL with Oracle R Distribution on Linux:
Add libmkl_rt.so
, $RHOME/lib
, and $ORACLE_HOME/lib
to the LD_LIBRARY_PATH system environment variable.
Start R and execute this Oracle R Distribution function Sys.BlasLapack
:
R> Sys.BlasLapack() $vendor [1] "Intel Math Kernel Library (Intel MKL)" $nthreads [1] -1
The vendor value returned indicates the presence of MKL instead of R's internal BLAS.
In order to get the speedup provided by MKL, you must set the MKL_THREADING_LAYER
environment variable to GNU before you start Oracle R Distribution on your system. In the Bash shell, set the variable as follows:
% export MKL_THREADING_LAYER=GNU
Oracle R Distribution is not supported on Windows, however the binaries distributed by the Comprehensive R Archive Network (CRAN) for Windows work with Oracle R Enterprise.
Before installing R, verify that your version of Microsoft Windows is supported by Oracle R Enterprise. Refer to Table 1-1, "Oracle R Enterprise Platform Requirements".
Follow these steps to install R on Windows:
Go to the R home page:
Under Download, Packages, choose CRAN.
Select a CRAN Mirror.
Choose Download R for Windows.
Under Subdirectories, choose base.
Under Other builds, choose Previous releases.
Download the most recent version of R specified in Section 1.7.
When the download completes, double-click the executable file to start the Windows installer for R. For example:
R-2.15.3-win.exe
Follow the instructions to complete the installation.