On Premise -> Oracle Cloud (DBaaS)

1. Introduction

The purpose of this Deployment guide is to demonstrate the way in which Dbvisit Standby 8.0 software can be used within the Oracle Database As A Service (DBaaS) space. In this guide, we focus on the Primary being 'on-premise' and the Standby database hosted on DBaaS.  In another document, we focus on both Primary and Standby Databases hosted on 'DBaaS'.  This document can be found here

2. Initial Setup and Configuration

2.1 Provisioning the Servers 

Connect to Oracle Cloud Dashboard and provision an Database Service.

I generated a private and public set of key files using ssh-keygen from my local Linux machine.

I could then import this file into the cloud setup.

I generated a private and public set of key files using ssh-keygen from my local Linux machine.

I could then import this file into the cloud setup in both cases. Confirm your setup and click "create" and after around 20mins the Service is available.

In order for Dbvisit Standby to communicate between the 2 hosts, and to enable access to the GUI frontend, 3 ports need to be made available.  These are 7890 (Dbvnet), 7891 (Dbvagent) and 4433 (dbvserver: GUI). To do this, navigate to the summary page and choose Access Rules from the menu. From here, click the "create rule" button and fill in the details.  The example below shows 1 rule per port range named dbvisit_ports.  It is also possible to create 1 rule per port and name them accordingly.

The Primary Host will be an Oracle VirtualBox, Virtual Machine running Oracle Linux v6

Here is a brief overview of the 2 servers involved.  

Primary Server (On-Premise) DetailsStandby Server (Cloud) Details

Name: dbvlab01

OCPUs: 1


Memory: 3G

Storage: 20G


Edition: Enterprise Edition

Database: SAM

Dbvisit Base: /usr/dbvisit

Standby Version:

Name: dbvcloud03

OCPUs: 1


Memory: 7.5G

Storage: 144G


Edition: Enterprise Edition

Database: SAM

Dbvisit Base: /usr/dbvisit

Standby Version:

2.2 Preparing the Servers 

Copy the Dbvisit Standby v8 software to dbvcloud03 and the local machine

Prepare the $DBVISIT_BASE directory and ownership.

Setup the VM to be available from the cloud host.

At this stage, these servers are ready for the next stage of installing the software.

3. Install, Configure and Run the Standby software

3.1 Installing and Configuring the Software

Unzip, Untar and the run the dbvisit installer following the instructions in the dbvisit installation guide as the user oracle. 


On the cloud node  dbvcloud03, the dbvserver (option 5) was also installed.  Alternatively, a 3rd host could be configured for hosting the dbvserver.   Careful to ensure during the dbvnet configuration on each node that the correct hosts are specified for source and destination. The output from the installation on the cloud host is shown below for reference.

Once the software has been installed on both nodes.  Start the processes.

Additionally, on the standby node, start the dbvserver process

3.2 Start the GUI and Create the DDC

Start a web browser and navigate to the https://<dbvserver_host>:4433. In this case, the standby node.

Add an exception and proceed.

Enter the default username/password of admin/admin and proceed to the first screen, manage hosts.

Enter each of the hosts in turn, specifying the passphrase used at creation time.

Return to the Main Menu and then proceed on to creating the DDC

The creation of the DDC file is shown in the following steps.  

Firstly Create a directory for ARCHSOURCE and ARCHDEST parameters.  The former is only required in the event of a Graceful switchover when the Primary becomes a Standby database.  In this example, the same location is created on each server.

To create a DDC from the GUI. Choose the Manage Configurations Tab

Create a New Configuration.  Fill out the relevant entries (as shown in the example below) the click 'Submit'

3.3 Create the Standby Database

3.3.1 Creating the Standby with the GUI

Choose the Create Standby Database Tab from the Home Screen.

Select your configuration, New Database, edit the SPFILE parameters if required and then check there is enough space in the Source and Dest temp locations.

Be careful to check that the File Mappings are consistent with the directories on the Cloud host. By default Oracle uses /u01,  /u02, /u03 and /u04 filesystems

Check there is enough space in your chosen temp location before clicking submit.

Click Submit.  The progress can be monitored from the resulting icon in the status bar.

3.3.2 Creating the Standby with the CLI

To Create the Standby database with the command line is shown below

The /etc/oratab has also been updated to reflect the new standby database

3.4 Performing Basic Tasks

Some examples of basic tasks are outlined below.  Please refer to the online documentation for more details on each command.  

3.4.1 Log Gap Report

Run a log gap report from the Primary Site

Also from the GUI

3.4.2 Log Transfer

For the purposes of the Documentation, we will use the CLI to Send logs to the Standby Site and then Apply them on the Standby site using the GUI

Applying Logs with the GUI

3.4.3 Daemon Status

Start the Daemons for automatic send/apply from the GUI Database Actions Tab. 

The "lightning bolt" icon manages the daemon processes as shown below.

When started on both sites they Log gap managed automatically and if no natural log switches have occurred, the daemon will also signal a log switch to keep the standby LAG to the desired amount. More information regarding the daemon settings can be found here in Section 4


3.4.4 Starting Standby Database in Readonly Mode

From the Database Actions Tab choose the Database Icon.  This allows the user to perform database actions on each node.

Before the Standby Database can be opened in readonly mode, there must be a log gap of 0 between the 2 systems.

Select the Standby Host, review the current status and Select Start READ ONLY.

Now, the status is Read Only for the standby database.

To switch back again.  Choose Restart

Now the Standby is back in recovery mode and the logs can be applied as normal.

3.5 Performing Graceful Switchover

The following screenshots show a Graceful Switchover from one Cloud Standby to the other using the GUI.  

A first pre-requisite is to ensure that the daemons started earlier are not running whilst the switchover is in progress.

3.5.1 Check the Status of the Daemons

From the "lightning bolt" icon stop the running Daemons for each site.

3.5.2 Graceful Switchover Icon

Performing a graceful switchover reverses the roles of the Primary and Standby databases and in this instance, the cloud server will host the primary database. This can be a temporary test or for a long as required by your business needs.

This task can be performed from either the GUI or the command line, here we demonstrate a Graceful Switchover from the GUI.

3.5.3 Check Log Gap is Zero and Click Submit

3.5.4 Locate the Task on the Task Bar and Monitor the Activity

3.5.5 Verify the New Roles within each of the Databases

Verify the new database roles within the database

Also, note that the primary and standby hosts are reversed in the Configuration Tab:

Using the CLI we can reverse the operation as follows.

3.6 Activate the Standby Database

It is possible to activate the Standby Database and make it become the new Primary.  This is also called failover to the standby database.

The assumption is that the original Primary site has been lost and needs to be rebuilt.  

3.6.1 Activate Standby Database from the Central Console/GUI

Select the Configuration and then click submit.  

Locate the Task and monitor it from the Task Bar.

3.6.2 Activate From the Command Line

3.6.3 Verify the Status within the Database

3.6.4 Manage Configurations Tab Implications

Now the Manage Configurations Tab has the option to choose the hosts. This allows you to either accept the current configuration with the new Primary (old Standby site) or start again with the original Primary site and depends on the circumstances of the Activation.