...
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
...
Info |
---|
The setup will be from Single Instance Primary Databases to Single Instance Standby Databases with Datafiles stored on standard filesystems. However the options for configuring Dbvisit Standby in the Oracle Cloud are in no way limited to this, is it has simply been chosen for demonstration purposes. |
...
Info |
---|
We opted for "Oracle Database Cloud Service" for Service level and have a pre-created database on the host. It was deemed faster to drop the database on the host host rather than choose the "Oracle Database Cloud Service - Virtual Image" as this does not come with binaries installed as indicated. |
...
I generated a private and public set of key files using ssh-keygen from my local linux Linux machine.
Code Block |
---|
oracle@dbvlab01[/home/oracle]: ssh-keygen -b 2048 -t rsa -f oraclecloud Generating public/private rsa key pair. Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has been saved in oraclecloud. Your public key has been saved in oraclecloud.pub. The key fingerprint is: 35:6b:e6:39:cd:06:c0:04:d9:7e:73:4d:85:80:33:ab oracle@dbvlab01.dbvisit.co.nz oracle@dbvlab01[/home/oracle]: |
...
I generated a private and public set of key files using ssh-keygen from my local linux Linux machine.
Code Block |
---|
oracle@dbvlab01[/home/oracle]: ssh-keygen -b 2048 -t rsa -f oraclecloud Generating public/private rsa key pair. Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has been saved in oraclecloud. Your public key has been saved in oraclecloud.pub. The key fingerprint is: 35:6b:e6:39:cd:06:c0:04:d9:7e:73:4d:85:80:33:ab oracle@dbvlab01.dbvisit.co.nz oracle@dbvlab01[/home/oracle]: |
...
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 a port range named dbvisit_ports. It is also possible to create 1 rule per port and name them accordingly.
...
Note | ||||||
---|---|---|---|---|---|---|
Configure the VirtualBox VM to be 'available' externally. To do this, update the relevant network controller enabling it to gain it's IP address from the Router and then shutdown shut down the machine.
Update the VM network settings to have a "Bridged Adapter" rather than "NAT Network" and then restart the machine Once the machine is available, check that it can access external IP addresses and add the IP of dbvcloud03 to the /etc/hosts file.
The IP to enter into the Hosts file on dbvcloud03 is that of our office router. The actual entry is not displayed here for obvious reasons.
|
At this stage, these servers are ready for the next stage of installing the software.
...
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.
...
Code Block |
---|
[oracle@dbvlab01 installer]$ cd /usr/dbvisit/dbvnet [oracle@dbvlab01 dbvnet]$ ./dbvnet -d start [oracle@dbvlab01 dbvnet]$ cd ../dbvagent/ [oracle@dbvlab01 dbvagent]$ ./dbvagent -d start [oracle@dbvlab01 dbvagent]$ ps -ef|grep -i dbv oracle 9372 1 0 20:34 ? 00:00:00 ./dbvnet -d start oracle 9379 1 0 20:34 ? 00:00:00 ./dbvagent -d start |
Additionally, on the standby node, start the dbvserver process
...
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.
...
Select your configuration, New Database, edit the spfile SPFILE parameters if required and then check there is enough space in the Source and Dest temp locations.
...
To Create the Standby database with the command line is shown below
...
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
...
Start the Daemons for automatic send/apply from the GUI Database Actions Tab.
The lightening "lightning bolt" icon manages the daemon processes as shown below.
...
Select the Standby Host, review the current status and Select Start READ ONLY.
...
3.5.1 Check the Status of the Daemons
From the lightening "lightning bolt" icon stop the running Daemons for each site.
...
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.
...
Code Block |
---|
oracle@dbvlab01[/usr/dbvisit/standby/trace]: sqlplus / as sysdba SQL*Plus: Release 11.2.0.4.0 Production on Wed Jun 21 12:34:53 2017 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> select name, database_role from v$database; NAME DATABASE_ROLE --------- ---------------- SAM PHYSICAL STANDBY oracle@dbvcloud03 standby]$ sqlplus / as sysdba SQL*Plus: Release 11.2.0.4.0 Production on Wed Jun 21 00:42:30 2017 Copyright (c) 1982, 2013, Oracle. All rights reserved. Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production With the Partitioning and Real Application Testing options SQL> select name, database_role from v$database; NAME DATABASE_ROLE --------- ---------------- SAM PRIMARY SQL> |
Also, note that the primary and standby hosts are reversed in the Configuration Tab:
...
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.
...