VDB operations allow you to interact with and manipulate virtualized instances of databases through DCT. These operations are pivotal in ensuring the effective utilization, maintenance, and synchronization of virtual databases across all connected CD engines.
Provision a VDB
Virtual databases are a significant part of the Delphix Continuous Data solution. In order to create or provision a virtual database, you will need a linked dSource from a source host and a compatible target environment, as described in the overview for Managing environments and hosts. Since provisioning VDBs vary significantly across connectors, details on this process can be found within the documentation for the specific connector.
At the core, virtual databases are fully functional copies of data sources that can be created and managed at a fraction of the storage and time that are typically required. To end-users, VDBs act and perform just like a standard database.
For more information, read SQL Server VDBs and RESTORE DATABASE limitation.
Disable and enable a VDB
The act of disabling a VDB serves as a necessary prerequisite for procedures like VDB migration or upgrade. When a VDB is disabled, it consists of the complete removal of all its traces, including configuration files from the target environment in which it was originally provisioned. It's important to note that while the VDB itself, along with its associated metadata, remains intact on the connected CD engine, the configuration files are temporarily eliminated from the target environment.
Subsequently, when you decide to re-enable the VDB, these previously removed configuration files are reinstated within the target environment, facilitating the VDB's return to operational status with its settings and parameters restored.
If these parameters are used, Delphix recommends a Post Start Hook to set them as desired. For more information, read the Inheritance of Database Properties During SQL Server VDB Operations KB article.
Procedure
Disable a VDB:
-
In DCT, navigate to Data > Data Management > VDBs.
-
Select the VDB you want to disable.
-
From the Actions menu, select Disable.
-
Click Disable to acknowledge the warning.
When you are ready to re-enable the VDB again, select Enable from the Actions menu, and the VDB will continue to function as it did previously.
Start and stop a VDB
topping your virtual databases is essential when executing actions on the database that requires it to be in an offline state. Beyond simply ensuring the database's proper shutdown, the stop and start actions managed through DCT encompass additional functions on the connected CD engine, including unmounting and mounting the filesystems supplied by the CD engine.
Procedure
Start/stop a VDB:
-
In DCT, navigate to Data > Data Management > VDBs.
-
Select the VDB you want to manage.
-
To stop an active VDB, click Actions > Stop at the top right-hand corner. Conversely, to start an inactive VDB, click Actions > Start at the top right-hand corner.
-
In cases where stopping or starting the VDB requires credentials distinct from the default environment user, then do the following:
-
Check Provide Privileged Credentials.
-
Enter the username and password.
-
Click Validate Credentials.
-
-
Click Stop/Start to stop or start the VDB.
-
To view the status of the stopping or starting of the VDB, you can:
-
Navigate to the Operation tabs
-
Monitor the snackbar at the bottom
-
Refresh a VDB
Refreshing a VDB will re-provision it from the dSource. As with the normal provisioning process, you can choose to refresh the VDB from a snapshot or a specific point in time. However, you should be aware that refreshing a VDB will delete any changes that have been made to it over time. When you refresh a VDB, it will revert to its previous state in the specified snapshot or point in time.
When performing a VDB refresh, there is an option to choose between either the faster or more accurate point in time for that database.
Prerequisites
To refresh a VDB, you must have the following permissions:
-
Provisioner permissions on the dSource associated with the VDB
-
Provisioner permissions on the group that contains the VDB
-
Owner permissions on the VDB itself
-
Data is a role that allows DB_ROLLBACK, DB_REFRESH, READ_ACTION, DB_SYNC, JOB_CANCEL.
-
Read is a role that allows the user to inspect objects via the READ_ACTION permission
A user with admin credentials can perform a VDB Refresh on any VDB in the system.
Procedure
Refresh a VDB:
-
In DCT, navigate to Data > Data Management > VDBs.
-
Select the VDB that you want to refresh.
-
Click the Refresh VDB button. The Refresh VDB screen appears.
-
Select one of the refresh options and click Next.
-
Faster - This option will utilize the most recent snapshot in the timeflow.
-
More accurate - This option allows you to select a snapshot, a point in time, or a specific log ID.
-
-
Click Submit to confirm.
-
Click the Actions button to watch the progress of the refresh job.
-
If you want to know when the VDB was last refreshed/provisioned, check the Time Point on the Status page.
Rewind a VDB
Rewinding a VDB rolls it back to a previous point in its timeline and re-provisions the VDB. The VDB will no longer contain changes after the rewind point.
-
Although the VDB no longer contains changes after the rewind point, the rolled-over snapshots and timeline still remain on the connected CD engine and are accessible through the DCT API or CLI toolkit. For instructions on how to use these snapshots to refresh a VDB to one of its later states after it has been rewound, refer to the topic CLI Cookbook: Rolling forward a VDB.
-
Delphix clones a new timeline from the closest snapshot older than or equal to the rewind point. This creates a dependency between the new timeline and the parent snapshot and timeline. The parent snapshot and timeline cannot be deleted because of this dependency. The VDB must first be refreshed before the parent snapshot and timeline can be removed.
Prerequisites
To rewind a VDB, you must have the following permissions:
-
Auditor permissions on the dSource associated with the VDB
-
Owner permissions on the VDB itself
You do not need owner permissions for the group that contains the VDB. A user with admin credentials can perform a VDB Rewind on any VDB in the system.
Procedure
Rewind a virtual database:
-
In DCT, navigate to Data > Data Management > VDBs.
-
Select the VDB you want to rewind.
-
Select the Timeflow tab.
-
Select the rewind point as a snapshot or a point in time.
-
Click Rewind.
-
If you want to use login credentials on the target environment other than those associated with the environment user, click Provide Privileged Credentials.
-
Click Rewind to confirm.
-
Mark where to rewind to - before starting a batch job on a VDB for example.
-
Provide a semantic point to revert back to in case the chosen rewind point turns out to be incorrect.
Undo refresh operation
An accidental refresh of one or more virtual databases (VDBs) from a source database can remove the important data. To restore the data back, you can undo VDB refresh actions.
Procedure
Undo a refresh operation:
-
In DCT, navigate to Data > Data Management > VDBs.
-
Select the VDB you want to undo your refresh for.
-
From the Actions menu, select Undo Refresh.
-
Confirm that you want to undo the last refresh for the selected VDB, by selecting Undo.
-
To view the status of the undo refresh operation, you can use one of the following ways:
-
Navigate to the Operation tab.
-
Monitor the snackbar at the bottom.
-
Migrate a VDB
In certain scenarios, you might find it necessary to migrate a virtual database to a different target environment. This need can arise, for instance, when upgrading the host where the VDB is hosted or as part of a broader data center migration effort. Leveraging the VDB migration functionality enables you to relocate the VDB from its current location to a new target environment. This is easily accomplished by first disabling the database, then using the migrate VDB feature to select a new target environment.
Prerequisites
-
Set up a new target environment that is compatible with the VDB that you want to migrate.
-
Ensure that the VDB has first been disabled.
Procedure
Migrate a virtual database:
-
In DCT, navigate to Data > Data Management > VDBs.
-
Select the VDB you want to migrate.
-
From the Actions menu, select Migrate.
-
Select the new target environment for the VDB, the user for that environment, and the database installation where the VDB will reside.
-
Select Migrate.
-
From the Actions menu, select Enable.
-
Click Enable to confirm.
Within a few minutes, your VDB will re-start in the new environment, and you can continue to work with it as you would any other VDB.
Upgrade a VDB
Much like the process of upgrading a dSource, upgrading a VDB entails modifying the installation path linked to the corresponding data platform. It's important to note that this feature doesn't upgrade the VDB itself; instead, it ensures that the connected CD engine correctly associates the VDB with the correct database version to ensure proper functionality.
By performing this upgrade, you have the capability to update the database version used for running the VDB.
Procedure
Upgrade a virtual database:
-
Remove any VDB refresh policy assigned to the VDB.
-
Upgrade the target database instance.
-
Refresh the target environment.
Delete a VDB
Deleting a VDB will remove it and its timeline and snapshots from the connected CD engine entirely. This operation is non-reversible.
Prerequisites
You cannot delete a VDB that has dependent VDBs. Before deleting a VDBs, make sure that you have deleted all dependent VDBs. Otherwise, the delete option will be grayed out.
Procedure
Delete a virtual database:
-
In DCT, navigate to Data > Data Management > VDBs.
-
Select the VDB you want to delete.
-
From the Actions menu, select Delete.
-
Click Delete to confirm.
Force Delete
Deleting a VDB may fail if it cannot be unmounted successfully from all target environments. You can use the force delete option to ignore all failures during unmount.
When to use
Deleting unused or outdated objects should be a regular part of CD engine administration through DCT. This is especially important to prevent low space errors, which can cause the connected CD engine to stop. The connected CD engine holds a maximum of 750 objects.
Force Delete can be used when:
-
The staging host/container is not accessible via the connected CD engine anymore.
-
The Delphix Connector service is not running (applicable to SQL Server only).
-
The normal delete is throwing an error and not working.
-
When the target or staging host is decommissioned.
Procedure
Forcefully delete a virtual database:
-
In DCT, navigate to Data > Data Management > VDBs.
-
Select the object you want to delete and open its storage capacity details. Get storage capacity information for objects managed by navigating to the CD engine in DCT and selecting the Storage tab.
-
Select the Trash can next to the object you want to delete.
-
In the Delete dialog, select Force Delete. Oracle users will have the option to provide additional credentials.
-
Click Delete.
Dependencies
If there are dependencies on the snapshot, you will not be able to delete the snapshot free space; the dependencies rely on the data associated with the snapshot. These items are displayed with a lock icon next to the name.
Export a VDB (V2P)
V2P (Virtual to Physical) refers to the process of exporting a virtual database to a physical one. Once you have created a dSource or a VDB, you have the option to export its contents and log files to a physical database. This process creates a set of directories on the target environment and populates them with the database data, log files, and scripts that are used to recover the physical database.
You can automatically start the physical database recovery process as part of V2P, or you can use the scripts for manual recovery. When the export process completes, the target environment will contain a copy of the database in its unvirtualized size. Therefore, before you begin the process, ensure that the target directories specified during V2P operation have enough capacity to accommodate the database. For more information, refer to the connector specific documentation.
Provision with replication
The process for provisioning from replicated objects closely mirrors the standard VDB provisioning procedure, with one key distinction. Before initiating the provisioning process, you must first select the replica namespace containing the replicated object.
Prerequisites
-
You must have a dSource or VDB that has been replicated from one CD engine to another, as described in Replication overview.
-
The CD engine containing the replicated dSource or VDB must have a compatible target environment that it can use to provision a VDB from the replicated dSource or VDB.
-
In DCT, navigate to Data > Data Management > VDBs and locate the replicated dSource or VDB on the appropriate connected CD engine.
Procedure
The provisioning process is identical to the process for provisioning standard objects.
-
Navigate to the Data > Data Management > VDBs tab and select Provision VDB.
-
Select the replicated VDB or dSource.
-
Follow the rest of the wizard to provision your new VDB.