5.2.2 Install OML4R Server Across Exadata Compute Nodes Using DCLI for 12c and Earlier

How to use DCLI to install OML4R Server across multiple Exadata Linux compute nodes for Oracle Database 12c and Earlier.

The DCLI commands are summarized in DCLI Commands Summary for Oracle Machine Learning for R Server.

Note:

Before beginning the installation, review the instructions for installing OML4R Server in Install Oracle Machine Learning for R Server.

To install OML4R Server on Exadata using DCLI for Oracle Database 12c and earlier, follow these steps:

  1. Ensure that the ORACLE_HOME, ORACLE_SID, R_HOME, PATH, and LD_LIBRARY_PATH environment variables are properly set on each node, and are defined in the same shell where the DCLI script will run. For example, you could specify values like the following in a bashrc file:

    export ORACLE_HOME=/hostname/app/oracle/product/release_number/dbhome_1
    export ORACLE_SID=ORCL
    export R_HOME=/usr/lib64/R
    export PATH=$PATH:$R_HOME/bin:$ORACLE_HOME/bin
    export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ORACLE_HOME/lib:$RHOME_lib:$R_HOME/port/Linux-X64/lib
    
  2. Go to the Oracle Machine Learning for R Downloads website.

    On the Downloads page, in the Linux 64-bit row, select Server, accept the license agreement, and download the file. To download the supporting packages, select Supporting, accept the license agreement, and download the file. The following files are downloaded for OML4R, where version is the OML4R, release number.

    ore-server-linux-x86-64-version.zip
    ore-supporting-linux-x86-64-version.zip
    
  3. Log in as root, and copy the installers for OML4R Server and the supporting packages across nodes. For example:

    $ dcli -g nodes -l oracle mkdir -p /home/oracle/OML4R
    $ dcli -g nodes -l oracle -f ore-server-linux-x86-64-version.zip -d 
         /home/oracle/OML4R/ore-server-linux-x86-64-version.zip
    $ dcli -g nodes -l oracle -f ore-supporting-linux-x86-64-version.zip -d 
         /home/oracle/OML4R/ore-supporting-linux-x86-64-version.zip
    
  4. Unzip the OML4R Server bundle on each node:

    $ dcli -t -g nodes -l oracle unzip
         /home/oracle/OML4R/ore-server-linux-x86-64-version.zip -d
         /my_destination_directory/
  5. Unzip the supporting packages on each node:

    $ dcli -t -g nodes -l oracle unzip   
         /home/oracle/OML4R/ore-supporting-linux-x86-64-version.zip -d 
         /my_destination_directory/
    
  6. Install OML4R Server components:

    $ dcli -t -g nodes -l oracle "cd /my_destination_directory; ./server.sh -y
          --perm permtablespace --temp temptablespace 
          --user-perm usertablespace --user-temp usertemptablespace
          --user OML_USER"

    Note:

    The server script creates a user for OML4R. By default, the script does not grant the RQADMIN role to the user.

    Any OML4R user can execute embedded R, but only those with the RQADMIN role can create and drop the R scripts in the database. Use caution when granting the RQADMIN role.

    For more information about the role, see About the RQADMIN Role.

  7. Verify OML4R loads.

    > library(ORE)
    Loading required package: OREbase
    Attaching package: OREbase
    The following objects are masked from âpackage:baseâ:
        cbind, data.frame, eval, interaction, order, paste, pmax, pmin,
        rbind, table
    Loading required package: OREembed
    Loading required package: OREstats
    Loading required package: MASS
    Loading required package: OREgraphics
    Loading required package: OREeda
    Loading required package: OREmodels
    Loading required package: OREdm
    Loading required package: lattice
    Loading required package: OREpredict
    Loading required package: ORExml