3. Disaster Recovery Actions - Using the Central Console
In case of disaster strikes, you will want to activate (failover) to the standby database. During this process, a resetlogs is performed and the standby database is opened read/write.
The standby database is then converted to a primary database and cannot be used as a standby database anymore.
In version 9 of Dbvisit Standby, a number of new options have been introduced in this section. First select "Disaster Recovery Actions" from the main menu 
Once you select a DDC on which the operation is to be performed, there are 3 options are now provided as listed below:
- Activate Now
- Select this option if you want to activate the standby database now - this is usually in the case when the disaster happened and you need to activate (failover) to the standby database.
- Perform DR Test
- It is always recommended that sites perform DR testing, activating a standby database and making use if a disaster did happen everything work as expected. This option will allow you to perform a backup of the standby database prior to activating it.
- Two options will be available:
- Create a backup to a local disk using RMAN Backupsets
- Create a backup to a local disk using RMAN Image Copies
This option can be useful to quickly switch back to your image copy instead of running a restore process.
- Standby Read Only Test
- This option allows you to quickly test if your standby database can be opened read-only. This is an excellent test to see if the standby database is in a consistent state. If a standby database is not consistent, you will not be able to open it read-only or activate it. In this case, you will have to send and apply more logs before you will be able to activate or open the standby read-only.
The screen capture below shows what the Perform DR Test screen looks like:
- Select "Perform DR Test"
- If you are running this the first time you will need to select "RUN DR TEST" - if you already performed this task, you will be given the option to "REINSTATE" if you have backups (backupset or image copies) available
- Confirm if you want to create a backup of the standby database prior to the test - NOTE: if you select NO, you will not have backups unless you create them manually
- Select the backup method type - Image Copy or Backupset
- Specify the format - this is making use of the RMAN format options - for more detail please see the Oracle RMAN documentation
- Specify the location for the backup - this location must have at least enough space to hold a full copy of the standby database.
- You can specify the process to stop between the backup and activation stages
- Submit to continue
If you have selected the option to create an Image copy backup, once done with the first step of the image copy creation you will get a completed task indicating the image backup was created and validated.
You will then be presented with the option to resume and continue with the activation. Once that is complete you will get the task that indicates the completion of the activation/failover process.
Once the above is complete, you will be able to perform you tests on the newly activate standby.
When you are ready to re-instantiate the standby again you can navigate to the Disaster Recovery Actions page and select the DDC.
You will then select the Perform DR Test and you will get the option REINSTATE, which will allow you to get to the next screen that allows you to continue restoring from the backup taken in the previous step.
- You will get two options if using Image Copy
- Switch to the image copy
- This will be fast as we will switch to the image copy instead of restoring. You will need to be aware that in this scenario the database will be switched to the copy.
- Restore from the image copy
- This method will perform a full restore from the image copy - this process is not as fast but will restore the database into the original location.
- Once this is selected, click on Submit to start the operation. As mentioned the switching to the image copy is faster.
Once the re-instate is complete, for example, if you have picked to switch to copy the following task details, will be displayed.
4. Disaster Recovery Actions - Using CLI
The DR test and the Read-Only test can also be performed using the command line. The below example will show how it is done. dbvctl -o -h will display the help on the commands which can be used .
4.1 Perform a Read-Only test
This option will help in determining if the database is standby is in a consistent state. This would open the database in read-only mode and the restart the database to mount mode so that the archivelogs can be applied.
4.2 Perform a DR Test and Re-instate
Status of the database
Now the next step is to reinstate the database back to the standby database
Status of the database
Below is another example where the DR test is performed by using image copy as backup and we switch to copy when reinstating the DR to standby.
Reinstate using the switch to copy function
5. Video - How to Perform a DR Test in Dbvisit Standby v9