/RMAN_Workshop

Workshop for to create an on-premise oracle database environment and configure RMAN into OCI object storage

Lab 50: Prerequistes

Works as of 2/6/2020

Creating an Oracle on-premise environment

This directory contains Vagrant build files to provision an Oracle Database automatically, using Vagrant, an Oracle Linux 7 box and a shell script.(space, space)

  1. Install Oracle VM VirtualBox
  2. Install Vagrant
  3. Clone the vagrant-boxes repository git clone https://github.com/oracle/vagrant-boxes
  4. Change into the desired version folder
  5. Download the installation zip files from OTN into this folder - first time only: http://www.oracle.com/technetwork/database/enterprise-edition/downloads/index.html
    [IMAGE TO SHOW THE NECESSARY FILES AND SHOW THE PRE-DOWNLOADED VAGRANT FILE]
  6. Run vagrant up
  7. Connect to the database via vagrant ssh
  8. You can shut down the box via the usual vagrant halt and the start it up again via vagrant up.

Retrieving and loading the necessary packages to the Database instance

  1. Install JDK-8

    • note: any JDK version 7 or higher will work, but some packages are archived on higher JDK versions such as 11 or 13
    • make sure that you install the linux x64 rpm file
      [IMAGE TO SHOW THE JDK-8 FILE NEEDED]
  2. Install the Oracle Database Backup Module

  3. Install the vagrant-scp plugin vagrant plugin install vagrant-scp

  4. Move the opc_installer.zip and jdk-8u241-linux-x64.rpm file to your Oracle database directory

    mv ~/downloads/opc_installer.zip ~/downloads/jdk-8u241-linux-x64.rpm ~/vagrant-boxes/OracleDatabase/12.1.0.2
    [IMAGE TO SHOW THE MOVED FILES]

  5. then you want to scp the two files into the database instance:
    vagrant scp opc_installer.zip jdk-8u241-linux-x64.rpm :~

  6. Connect to the database with vagrant ssh

  7. Check to see if the two files are there

Lab 100: Configuring and using RMAN

Install the packages inside the Database instance

  1. run su to login to the root user
  2. install the JDK with $ rpm -ivh jdk-8u241-linux-x64.rpm
  3. Check to see if java was installed properly with $ java -v
  4. Unzip the opc_installer.zip file via $ unzip opc_installer.zip
  5. Get to the opc installer directory via $ cd opc_installer
  6. there are two folders inside
    [IMAGE TO SHOW THE CONTENTS OF opc_installer]
  7. We will use the oci_installer this time so run $ cd oci_installer
  8. There should be a jar file called oci_install.jar $ ls
  9. Move that to the root directory, for example $ mv oci_install.jar /opt
  10. Then get to that directory with $cd /opt
  11. Check whether the file is there $ ls
    [IMAGE TO SHOW THE JAR FILE]

Getting the prerequisites to run the JAR file

There are several prereqs to run this jar file

  1. hostname

  2. private key

  3. public key fingerprint

  4. tenancy OCID

  5. compartment OCID

  6. user OCID

  7. bucketname (optional)

  8. wallet directory location (optional)

  9. library directory location (optional)

  10. configfile directory location (optional)

  11. Also to make this work you need tenancy-level access to Object Storage, can easily be done with admin access or you can create a policy that limits access to just the required resources
    Allow group <group_name> to manage objects in compartment <compartment_name> where target.bucket.name = '<bucket_name>'

    Allow group <group_name> to read buckets in compartment <compartment_name>