Migrating Oracle Database Backup Cloud Service Backups Oracle Cloud Infrastructure
Migrating Oracle Database Backup Cloud Service Backups Oracle Cloud Infrastructure
F22999-02
June 2020
Oracle Cloud Migrating Oracle Database Backup Cloud Service Backups to Oracle Cloud Infrastructure,
F22999-02
This software and related documentation are provided under a license agreement containing restrictions on
use and disclosure and are protected by intellectual property laws. Except as expressly permitted in your
license agreement or allowed by law, you may not use, copy, reproduce, translate, broadcast, modify,
license, transmit, distribute, exhibit, perform, publish, or display any part, in any form, or by any means.
Reverse engineering, disassembly, or decompilation of this software, unless required by law for
interoperability, is prohibited.
The information contained herein is subject to change without notice and is not warranted to be error-free. If
you find any errors, please report them to us in writing.
If this is software or related documentation that is delivered to the U.S. Government or anyone licensing it on
behalf of the U.S. Government, then the following notice is applicable:
U.S. GOVERNMENT END USERS: Oracle programs (including any operating system, integrated software,
any programs embedded, installed or activated on delivered hardware, and modifications of such programs)
and Oracle computer documentation or other Oracle data delivered to or accessed by U.S. Government end
users are "commercial computer software" or “commercial computer software documentation” pursuant to the
applicable Federal Acquisition Regulation and agency-specific supplemental regulations. As such, the use,
reproduction, duplication, release, display, disclosure, modification, preparation of derivative works, and/or
adaptation of i) Oracle programs (including any operating system, integrated software, any programs
embedded, installed or activated on delivered hardware, and modifications of such programs), ii) Oracle
computer documentation and/or iii) other Oracle data, is subject to the rights and limitations specified in the
license contained in the applicable contract. The terms governing the U.S. Government’s use of Oracle cloud
services are defined by the applicable contract for such services. No other rights are granted to the U.S.
Government.
This software or hardware is developed for general use in a variety of information management applications.
It is not developed or intended for use in any inherently dangerous applications, including applications that
may create a risk of personal injury. If you use this software or hardware in dangerous applications, then you
shall be responsible to take all appropriate fail-safe, backup, redundancy, and other measures to ensure its
safe use. Oracle Corporation and its affiliates disclaim any liability for any damages caused by use of this
software or hardware in dangerous applications.
Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of
their respective owners.
Intel and Intel Inside are trademarks or registered trademarks of Intel Corporation. All SPARC trademarks are
used under license and are trademarks or registered trademarks of SPARC International, Inc. AMD, Epyc,
and the AMD logo are trademarks or registered trademarks of Advanced Micro Devices. UNIX is a registered
trademark of The Open Group.
This software or hardware and documentation may provide access to or information about content, products,
and services from third parties. Oracle Corporation and its affiliates are not responsible for and expressly
disclaim all warranties of any kind with respect to third-party content, products, and services unless otherwise
set forth in an applicable agreement between you and Oracle. Oracle Corporation and its affiliates will not be
responsible for any loss, costs, or damages incurred due to your access to or use of third-party content,
products, or services, except as set forth in an applicable agreement between you and Oracle.
Contents
Preface
Audience v
Documentation Accessibility v
Related Resources v
Conventions vi
iii
Migrate Backups to Oracle Cloud Infrastructure Object Storage 3-3
iv
Preface
Topics:
• Audience
• Documentation Accessibility
• Related Resources
• Conventions
Audience
This document is intended for users who are considering migrating their database
backups, created using Oracle Database Backup Cloud Service, from Oracle Cloud
Infrastructure Object Storage Classic to Oracle Cloud Infrastructure Object Storage.
Documentation Accessibility
For information about Oracle's commitment to accessibility, visit the Oracle
Accessibility Program website at http://www.oracle.com/pls/topic/lookup?
ctx=acc&id=docacc.
Related Resources
For more information, see these Oracle resources:
• Oracle Database Backup Cloud Service documentation
https://docs.oracle.com/en/cloud/paas/db-backup-cloud/index.html
• Oracle Cloud Infrastructure documentation
https://docs.cloud.oracle.com/iaas/Content/home.htm
• Oracle Cloud Infrastructure Getting Started
https://docs.cloud.oracle.com/iaas/Content/GSG/Concepts/baremetalintro.htm
• Oracle Cloud Infrastructure Object Storage Classic documentation
https://docs.oracle.com/en/cloud/iaas/storage-cloud/index.html
v
Preface
Conventions
The following text conventions are used in this document:
Convention Meaning
boldface Boldface type indicates graphical user interface elements associated
with an action, or terms defined in text or the glossary.
italic Italic type indicates book titles, emphasis, or placeholder variables for
which you supply particular values.
monospace Monospace type indicates commands within a paragraph, URLs, code
in examples, text that appears on the screen, or text that you enter.
vi
1
Introduction to Migrating to Oracle Cloud
Infrastructure
Learn how to migrate backups of your on-premise database from Oracle Cloud
Infrastructure Object Storage Classic to Oracle Cloud Infrastructure Object Storage.
Topics:
• Why Migrate to Oracle Cloud Infrastructure
• About Oracle Cloud Infrastructure
• About the Migration Scope
• About the Migration Task Flow
1-1
Chapter 1
About the Migration Scope
A virtual cloud network (VCN) is comprised of one or more subnets, and an instance is
assigned to a specific subnet. Oracle Cloud Infrastructure does not allow you to
reserve specific IP addresses for platform services.
A subnet's security lists permit and block traffic to and from specific IP addresses and
ports.
Instances can communicate with resources outside of Oracle Cloud by using Oracle
Cloud Infrastructure FastConnect, which provides a fast, dedicated connection to your
on-premises network. Alternatively, use an IPSec VPN.
A bucket in Oracle Cloud Infrastructure Object Storage can be used to store files and
share them with multiple instances. A user's generated authentication token (auth
token) is required to access the bucket.
To learn more, see Key Concepts and Terminology in the Oracle Cloud Infrastructure
documentation.
1-2
2
Prepare to Migrate Database Backups
Before you migrate Oracle Database Backup Cloud Service to Oracle Cloud
Infrastructure, plan and prepare for migration.
Topics:
• Get Details of the Source Environment
• Restore Backups from Archive Storage in Oracle Cloud Infrastructure Object
Storage Classic
• Set Up Your Target Environment
• Considerations for Migrating Data Using Rclone
2-1
Chapter 2
Set Up Your Target Environment
2. Open the navigation menu on the left, select Classic Infrastructure Services,
and then Storage Classic.
3. Select the container that stores the archived database backups.
4. Identify the archived object that you want to restore.
5. Select Check Status.
The Checking current status of archive object dialog box appears with the
following message:
7. Click OK.
The following message appears:
Restore job for objectName initiated successfully. You can check the
Restore Status by clicking the
Check Status button.
By default, the object remains restored for one day, after which you must restore it
again to be able to download it.
8. Click OK.
Topics:
• Install the Oracle Database Cloud Backup Module for OCI
• Configure the Oracle Database Cloud Backup Module for OCI
2-2
Chapter 2
Set Up Your Target Environment
Topics:
• Before You Begin Installing Oracle Database Cloud Backup Module for OCI
• Parameters to Run the Oracle Database Cloud Backup Module for OCI
• Downloading and Installing the Oracle Database Cloud Backup Module for OCI
• Files Created when Oracle Database Cloud Backup Module for OCI is Installed
Before You Begin Installing Oracle Database Cloud Backup Module for OCI
Before you install the Oracle Database Cloud Backup Module for OCI, make sure you
have what you need:
• A supported Oracle Database version and operating system
See Supported Databases and Operating Systems.
• An Oracle Technology Network (OTN) account or Oracle.com account
If you don’t have an OTN account, create one by registering at http://
www.oracle.com/technetwork/index.html.
• An Oracle Cloud account with access to Oracle Cloud Infrastructure Object
Storage
See Object Storage in the Oracle Cloud Infrastructure Documentation.
• Oracle Cloud Infrastructure API signing keys, tenant OCID, and user OCID
You may specify a compartment ID. However, if the compartment ID is not
specified, the tenant ID is used as the compartment ID.
See Required Keys and OCIDs.
• JDK 1.7 or later
You must have JDK 1.7 or later on the system on which you plan to install the
Oracle Database Cloud Backup Module for OCI. Use the following command to
check your JDK version:
java -version
• The required patch if you’re using the Standard Edition of Oracle Database
See My Oracle Support Doc ID 1640149.1 at http://support.oracle.com.
• Values for the parameters required to run the installer for Oracle Database Cloud
Backup Module for OCI
It’s best to compile this information before you run the installer. See Parameters to
Run the Oracle Database Cloud Backup Module for OCI.
2-3
Chapter 2
Set Up Your Target Environment
Note:
If your database server has multiple Oracle homes, the Oracle Database
Cloud Backup Module for OCI must be installed into each ORACLE_HOME.
Alternatively, you can copy the library file (libopc.so or oraopc.dll,
depending on your operating system) to other Oracle home library locations,
along with the opcSID.ora configuration file (assuming you're using the same
cloud credentials for backing up all databases in the database server).
Copy and rename the opcSID.ora file for each database instance you are
backing up to the cloud, where SID matches the SID for the database
instance.
Parameters to Run the Oracle Database Cloud Backup Module for OCI
You must specify parameters and their values when you run the Oracle Database
Cloud Backup Module for OCI installer. Parameters include the host name for the
Oracle Cloud Infrastructure account and the private key used to sign Oracle Cloud
Infrastructure API requests. It’s best to compile this information before you run the
installer.
The following example shows what you’ll need to provide:
java -jar oci_install.jar
-host https://objectstorage.us-phoenix-1.oraclecloud.com
-pvtKeyFile oci_private_key -pubFingerPrint oci_public_fingerprint
-uOCID user_ocid -tOCID tenancy_ocid
-walletDir /wallet_directory -libDir /library_directory
The following table lists required parameters. Optional parameters are also listed.
Parameters can also be displayed by running the following command from the
directory that contains the oci_install.jar installer file:
2-4
Chapter 2
Set Up Your Target Environment
2-5
Chapter 2
Set Up Your Target Environment
2-6
Chapter 2
Set Up Your Target Environment
2-7
Chapter 2
Set Up Your Target Environment
-opcID
'myAccount@myCompany.co
m'
-opcPass 'abc123$'
-host https://
objectstorage.us-
phoenix-1.oraclecloud.c
om
-libDir /home/
oracle/OPC/lib
-walletDir /home/
oracle/OPC/wallet
For this example, the following
command installs the Oracle
Database Cloud Backup
Module for OCI using the
parameters specified in the
file:
java -jar
opc2_install.jar -
argFile arguments.txt
2-8
Chapter 2
Set Up Your Target Environment
Downloading and Installing the Oracle Database Cloud Backup Module for OCI
Download and install the Oracle Database Cloud Backup Module for OCI on your
database server.
First, make sure you’re ready. See Before You Begin Installing Oracle Database Cloud
Backup Module for OCI.
To download and install the Oracle Database Cloud Backup Module for OCI:
1. Download the Oracle Database Cloud Backup Module for OCI from Oracle
Technology Network (OTN):
http://www.oracle.com/technetwork/database/availability/oracle-cloud-
backup-2162729.html
Accept the license agreement, click All Supported Platforms, and provide your
OTN user name and password when prompted. Then download the ZIP file that
contains the installer (opc_installer.zip) to your system.
2. Extract the contents of the zip file.
The file contains two directories, oci_installer and opc_installer, and a
README file.
3. Run the installer, oci_install.jar, from the oci_installer directory. Provide the
required parameters in one line, with each parameter preceded by a hyphen and
followed by its value. For information about required parameters, see Parameters
to Run the Oracle Database Cloud Backup Module for OCI.
The following is an example run of the installer. This example shows how the installer
automatically downloads the Oracle Database Cloud Backup Module for OCI for your
operating system, creates a wallet that contains Oracle Database Backup Cloud
Service identifiers and credentials, creates the backup module configuration file, and
downloads the library necessary for backups and restores to Oracle Cloud
Infrastructure.
% java -jar oci_install.jar -host https://objectstorage.us-phoenix-1.oraclecloud.com
-pvtKeyFile /oracle/dbs/oci_wallet/oci_pvt
-pubFingerPrint e5:10:06:b1:fb:24:ef:db:46:21:16:20:46:jk:th:35
-uOCID
ocid1.user.oc1..aaaaaaaasd754pijuwheaq67t7tninefkn7z7aibtusj7jqac5lpm7wm37va
-tOCID
ocid1.tenancy.oc1..aaaaaaaavjhvwf4c7q2ozzyduh7njrft58i6ts3ryjk7v83w7q4wdr2ka
-walletDir /oracle/dbs/oci_wallet
-libDir /oracle/lib
-bucket db_backups
Oracle Database Cloud Backup Module Install Tool, build 2018-12-11
Oracle Database Cloud Backup Module credentials are valid.
Backups would be sent to bucket db_backups.
Oracle Database Cloud Backup Module wallet created in directory /oracle/dbs/
oci_wallet.
Oracle Database Cloud Backup Module initialization file /oracle/dbs/opcb18test.ora
created.
Downloading Oracle Database Cloud Backup Module Software Library from file
opc_linux64.zip.
Download complete.
2-9
Chapter 2
Set Up Your Target Environment
Files Created when Oracle Database Cloud Backup Module for OCI is Installed
After you run the installer for the Oracle Database Cloud Backup Module for OCI,
make sure the required files are on your system.
The following files are created when you install the backup module and they are used
to perform cloud backups and restores. For information about the parameters
mentioned, see Parameters to Run the Oracle Database Cloud Backup Module for
OCI.
2-10
Chapter 2
Considerations for Migrating Data Using Rclone
% rman target /
The following example connects to your target database, with DBID prod, by using
password file authentication. Enter the password for the bkup_admin user (with the
SYSBACKUP privileges) when prompted.
For example:
RMAN> CONFIGURE CHANNEL DEVICE TYPE sbt
PARMS='SBT_LIBRARY=/orclhome/lib/libopc.so,
SBT_PARMS=(OPC_PFILE=/orclhome/dbs/opcora12.ora)';
On Windows systems, you’ll need to specify the ENV parameter. For example:
RMAN> CONFIGURE CHANNEL DEVICE TYPE sbt
PARMS='SBT_LIBRARY=C:\tmp\oraopc.dll,
ENV=(OPC_PFILE=C:\tmp\opcora12.ora)';
Note:
If you have existing backups on Oracle Cloud Infrastructure, ensure that the
backup piece names are not the same as the ones in Oracle Cloud
Infrastructure Object Storage Classic. This is to avoid the risk of overwriting
objects in the target bucket. It is recommended that you use the format ''%d_
%U' when creating the backups to avoid such conflicts.
2-11
Chapter 2
Considerations for Migrating Data Using Rclone
• You can't copy multiple containers at a time. You can copy only one container at a
time. However, you can copy one or more objects at a time.
• Metadata and policies aren't copied. This includes:
– Custom metadata on objects and containers
– Cross-Origin Resource Sharing (CORS) settings
– Object immutability
– ACLs on containers
– Container quotas
• If you have large objects in your Oracle Cloud Infrastructure Object Storage
Classic account, then you should check if the object as well as its segments are
stored in the same container. When the same container has the object as well as
its segments, Rclone detects this and copies the object correctly without
duplicating data.
Consider using the following rclone options in the following scenarios:
• dry-run: Use this option to validate a migration before start to copy data.
Amongst other benefits, this option allows you to check that the specified bucket
name is valid.
• includes, excludes, or filtering: Use these options to include or exclude files
to be copied, based on patterns or size.
• s3-upload-cutoff: Use this option to copy large objects.
• progress: Use this option to generate a real-time overview of the transfer.
• transfers: Use this option to utilize your network bandwidth better and increase
throughput. You will need to tune this value based on the available bandwidth for
your compute shape.
2-12
3
Migrate Database Backups to Oracle Cloud
Infrastructure Object Storage
Use rclone to migrate your database backups from Oracle Cloud Infrastructure Object
Storage Classic to Oracle Cloud Infrastructure Object Storage.
Topics:
• Download and Install Rclone
• Configure Your Environment
• Migrate Backups to Oracle Cloud Infrastructure Object Storage
To install rclone:
[classic-source]
type = swift
env_auth = false
user = Storage-acme:myuserName
key = pas$word
3-1
Chapter 3
Configure Your Environment
storage_url = https://acme.storage.oraclecloud.com/v1/Storage-acme
auth = https://acme.storage.oraclecloud.com/auth/v1.0
[oci-dest]
type = s3
env_auth = false
access_key_id = YOUR_ACCESS_KEY
secret_access_key = YOUR_ACCESS_SECRET_KEY
region = YOUR_REGION_IDENTIFIER
endpoint = https://
YOUR_NAMESPACE.compat.objectstorage.YOUR_REGION_IDENTIFIER.oraclecloud.c
om
3-2
Chapter 3
Migrate Backups to Oracle Cloud Infrastructure Object Storage
The following command uses the remote device configuration for the target to
display the existing buckets in Oracle Cloud Infrastructure Object Storage:
To migrate backups:
1. Copy backups to Oracle Cloud Infrastructure Object Storage.
The following command copies backups from the src_cont container in Oracle
Cloud Infrastructure Object Storage Classic to the dest_bkt bucket in Oracle
Cloud Infrastructure Object Storage. Backups that have already been copied are
skipped.
To monitor the progress, you can add a debug option. For example:
2. Optional. The following command modifies the destination to make it identical with
source.
3-3
4
Complete the Post-Migration Steps
After you migrate your database backups to Oracle Cloud Infrastructure Object
Storage, verify that the backups are valid and accessible.
Topics:
• Validate the Migrated Backups
4-1
Chapter 4
Validate the Migrated Backups
4-2