DSMSERV RESTORE DB (Restore a database to a point-in-time by using cloud object storage)
IBM Spectrum® Protect uses the cloud credentials that are provided by the DSMSERV RESTORE DB utility to obtain a device configuration file, a volume history file, and an encrypted master key file from cloud storage. These files are then used to restore the database to a point-in-time that is either the same as or prior to the point-in-time of the information that was obtained from cloud object storage.
Syntax
- 1 This parameter applies only to AIX® and Linux® servers.
- 2 This parameter applies only to Windows servers.
- 3 The BUCKETNAME parameter is valid only if you specify CLOUDTYPE=S3 or CLOUDTYPE=GOOGLE.
- 4 The IDENTITY parameter is valid only if you specify CLOUDTYPE=S3.
- 5 The CLOUDPASSWORD parameter does not apply if you specify CLOUDTYPE=GOOGLE.
- 6 The KEYLOCATION parameter is valid only if you specify CLOUDTYPE=GOOGLE.
Parameters

-u
user_name
Specifies a user name to switch to after the database is restored and the server is initialized.

-i
instance_dir
Specifies an instance directory to use. This instance directory becomes the current working
directory of the server.
-k
key_name
Specifies the name of the Windows registry key from which to retrieve information about the server.
The default is SERVER1.- -o options_file
- Specifies an options file to use.

-quiet
Specifies that messages to the console are suppressed.- TODate (Required)
- Specifies the date to which to restore the database. The following values are possible:
- MM/DD/YYYY
- Specifies that you want to restore a database by using the last backup series that was created before this specified date.
- TODAY
- Specifies that you want to restore a database by using the most recent backup series that was created before today.
- TODAY-numdays or -numdays
- Specifies that you want to restore a database by using the most recent backup series that was created the specified number of days before the current date.
- TOTime
- Specifies the time of day to which to restore the database. This parameter is optional. The
default is the end of the day (23:59:59). Possible values are:
- HH:MM:SS
- Specifies that you want to restore the database by using the last backup series that is created on or before the specified time on the date that is specified on the TODATE parameter.
- NOW
- Specifies that you want to restore the database by using a backup series that is created on or
before the current time on the date that is specified on the TODATE parameter.
For example, if you issue the DSMSERV RESTORE DB utility at 9:00 with TOTIME=NOW, the database is restored by using the last backup series that is created on or before 9:00 on the date that is specified on the TODATE parameter.
- NOW-numhours:numminutes or -numhours:numminutes
- Specifies that you want to restore the database by using a backup series that is created on or
before the current time minus a specified number of hours and, optionally, minutes on the date that
is specified on the TODATE parameter.
For example, if you issue the DSMSERV RESTORE DB utility at 9:00 with TOTIME=NOW-3:30 or TOTIME+-3:30, the database is restored by using the last backup series that is created on or before 5:30 on the date that is specified on the TODATE parameter.
- PReview
- If PREVIEW=YES, specifies that the volume history file and database backup volumes are analyzed. The system identifies the database backup volumes that best meet the criteria for restore processing. If the volume history information is consistent with the self-describing data, a message will be issued to indicate that the database backup can be used for restore processing. If the volume history information is inconsistent with the self-describing data or the backup cannot be found, error messages are issued.
- RESTOREKeys
- Specifies whether to restore the database when the server master encryption key is restored.
This parameter is optional. The default is YES. You can specify one of the
following values:
- Yes
- Specifies that the server master key that is used to encrypt storage pool data is restored when the database is restored.
- Only
- Specifies that only the server master key is restored. The database is not restored.
- PASSword
- Specifies the password that is used to protect the database backup. This password was set by
using the SET DBRECOVERY or the BACKUP DB command. Attention: If you use this parameter to specify a password, the password is displayed on the command line and is not secure. If you specify a value for the PASSWORD parameter, you must also specify PROMPT=NO; otherwise, the command fails. To help protect the password, use the PROMPT=YES parameter value instead of the PASSWORD parameter to ensure that users are prompted for the password. When you use the PROMPT=YES parameter value, the password is not displayed on the command line.
- PROMPT
- Specifies whether to prompt the user for the password that is used to protect the database
backup. This password to protect the master encryption key was set by using the SET
DBRECOVERY or the BACKUP DB command.
- Yes
- Specifies that the server prompts the user for the password that is used to protect the database backup. This setting helps to protect the password and is the default when a password is required.
- No
- Specifies that the server does not prompt the user for the password. Instead, the server uses the password that is specified by using the PASSWORD parameter. If you use the PASSWORD parameter along with the PROMPT=NO parameter value, the password is displayed on the command line, and unauthorized users might access the password. If you choose to specify the PASSWORD parameter, you must also specify the PROMPT=NO parameter value.
- CLOUDType
- Specifies the type of cloud environment in which to look for the required configuration files.
This parameter is optional.
- AZure
- Specifies that the connection uses a Microsoft Azure cloud computing system.
- S3
- Specifies that the connection uses a cloud computing system with the Simple Storage Service (S3) protocol, such as IBM® Cloud Object Storage or Amazon Web Services (AWS) S3.
- Specifies that the connection uses a Google Cloud Storage cloud computing system.
- BUCKETName
- Specifies the name for an AWS S3 or Google Cloud Storage bucket or an IBM Cloud Object Storage vault in which to look for the required configuration files. This parameter is required and is valid only if you specify CLOUDTYPE=S3 or CLOUDTYPE=GOOGLE. If you specified CLOUDTYPE=Azure, do not specify the BUCKETNAME parameter.
- CLOUDUrl
- Specifies the URL of the object storage environment in which to look for the required
configuration files. If you specified CLOUDTYPE=GOOGLE, do
not specify the CLOUDURL parameter. Based on your cloud provider, you can
use a blob service endpoint, region endpoint URL, an Accesser® IP address, a public authentication endpoint,
or a similar value for this parameter. Ensure that you include the protocol, such as
https:// or http://, at the beginning of the URL. The maximum
length of the web address is 870 characters. This parameter is required to retrieve configuration
files from object storage. For IBM Cloud Object Storage users: To optimize performance, use multiple Accessers. To use more than one IBM Cloud Object Storage Accesser, list the Accesser IP addresses separated by a vertical bar (|), with no spaces, surrounded by quotation marks, as in the following example:
cloudurl="accesser_url1|accesser_url2|accesser_url3" - IDentity
- Specifies the user ID for the cloud that is specified in the CLOUDURL
parameter. This parameter is required and valid only if you specify
CLOUDTYPE=S3. If you specified CLOUDTYPE=Azure or
CLOUDTYPE=GOOGLE, do not specify the IDENTITY parameter.
Based on your cloud provider, you can use an access key ID, a user name, a tenant name and user
name, or a similar value. The maximum length of the user ID is 255 characters.Tip: To specify a tenant name and user name, use the following format:
tenant_name.user_name - CLOUDPAssword
- Specifies the password for the cloud that is specified in the CLOUDURL
parameter. If you specified
CLOUDTYPE=GOOGLE, do not specify the CLOUDPASSWORD
parameter.Based on your cloud provider, you can use a shared access signature (SAS) token,
secret access key, an API key, a password, or a similar value for this parameter. This parameter is
required to retrieve configuration files from cloud object storage. The maximum length of the
password is 255 characters. If the password contains any special characters, enclose it in double
quotation marks (").Attention: If you choose to use this parameter to specify a password, the password is displayed on the command line and is not secure. If you specify a value for the CLOUDPASSWORD parameter, you must also specify PROMPT=NO; otherwise, the command fails. To help protect the password, use the PROMPT=YES parameter value instead of the CLOUDPASSWORD parameter to ensure that users are prompted for the password. When you use the PROMPT=YES parameter value, the password is not displayed on the command line.
- SERVERName
- Specifies the server name for the server that you are restoring. This parameter applies only to
retrieving configuration files from cloud object storage. The server name and globally unique
identifier (GUID) might be needed to determine the specific location of the required configuration
files in object storage. The parameter is only required if there are database backup volumes from
more than one server in the same bucket in object storage. If there are database backups from
multiple servers in the same bucket and this parameter is not specified, you are prompted to select
the correct location for your database backup.
This value can be either the server name or the server name plus the server GUID separated by a hyphen. For example, if your server is named server1 and your server GUID is fcbid280a8bd11e8g77b54e1adee4e87, this value can be server1 or server1-fcbid280a8bd11e8g77b54e1adee4e87. The maximum length of the name is 85 characters.
- KEYLocation
- Specifies the name of the file that contains the Google Cloud Storage service account key in JavaScript Object Notation (JSON) format. This parameter is required and is valid only if you specify CLOUDTYPE=GOOGLE. If you specified CLOUDTYPE=AZURE or CLOUDTYPE=S3, do not specify the KEYLOCATION parameter.
Example: Restore the database to a specific point in time
Restore the database to its state on December 12, 2019 at 2:25 PM. dsmserv restore db todate=12/12/2019 totime=14:45Example: Restore the server master key without restoring the database
Restore the server master key without restoring the database by issuing the following command:dsmserv restore db restorekeys=only