Restore Backupset
The restore backupset command restores a backup set from the Tivoli® Storage Manager server, a local file, or a local tape device. You can restore the entire backup set, or, in some cases, specific files within the backup set.
![AIX operating systems](./../common/images/ngaix.gif)
![HP-UX operating systems](./../common/images/nghpux.gif)
![Linux operating systems](./../common/images/nglinux.gif)
![Mac OS X operating systems](./../common/images/ngmacosx.gif)
![Oracle Solaris operating systems](./../common/images/ngsolaris.gif)
![Windows operating systems](./../common/images/ngwin.gif)
Supported Clients
This command is valid for all clients.
Syntax
>>-REStore Backupset--+-------------------------------------+---> +-+-----------------+--sourcefilespec-+ | '-{filespacename}-' | '-SYSTEMSTATE-------------------------' >--+---------------------+--+---------+-- -BACKUPSETName= ------> '-destinationfilespec-' '-options-' >--+-backupsetname-+--+--------------------------+------------->< +-localfilename-+ '- -LOCation= --+-server-+-' '-tapedevice----' +-file---+ '-tape---'
Parameters
- {filespacename}
- Specifies the file space (enclosed in braces) on the server that
contains the files you want to restore. This is the name on the workstation
drive from which the files were backed up, or the virtual file space
name for a group.
Specify a file space name when you restore a backup set containing a group.
Specify a file space name when the sourcefilespec does not exist on the target computer. This can occur if the drive label name has changed or if you are restoring files that were backed up from another node that had drive labels that are different from yours.
Note: You must specify a mixed or lowercase NTFS or ReFS file space name that is enclosed in quotation marks and braces. For example, {"NTFSDrive"}. Single quotation marks are valid in loop mode. For example: {"NTFSDrive"} and {'NTFSDrive'} are both valid. In batch mode, only single quotation marks are valid. The single quotation marks requirement is a restriction of the operating system.
- sourcefilespec
- Specifies the source path of a portion of the backup set. The default is to restore the entire backup set.
- SYSTEMSTATE
- Specifies that you want to restore the entire backup of the system state from the backup set. You cannot restore individual system state components from the backup set. This parameter is valid only for systems that support system state. To restore individual system state components from a backup set, use the restore systemstate command.
- destinationfilespec
- Specifies the destination path for the restored files. If you do not specify a sourcefilespec, you cannot specify a destinationfilespec. If you do not specify a destination, the backup-archive client restores the files to the original source path. If you are restoring more than one file, you must end the file specification with a directory delimiter (/), otherwise, the client assumes that the last name is a file name and reports an error. If you are restoring a single file, you can optionally end the destination file specification with a file name if you want to give the restored file a new name. When the sourcefilespec does not exist on the target workstation, you must specify destinationfilespec.
- -BACKUPSETName=
- Specifies the name of the backup set from which to perform a restore
operation. You cannot use wildcard characters to specify the backup
set name. The value of backupsetname depends on
the location of the backup set, and corresponds to one of the following
three choices:
- backupsetname
- Specifies the name of the backup set on the server from which to perform a restore operation. If location option is specified, you must set -location=server.
- localfilename
- Specifies the file name of the first backup set volume. You must set -location=file.
- tapedevice
- Specifies the name of the tape device containing the backup set volume. You must use a Windows-provided device driver, not the device driver that is provided by Tivoli. You must set -location=tape.
- -LOCation=
- Specifies the location of the backup set. If you do not specify the location parameter, the
client searches for backup sets on the Tivoli Storage Manager server. If you specify the location parameter, the value must be one of the following three choices:
- server
- Specifies that the backup set is on the Tivoli Storage Manager server. Server is the default location.
- file
- Specifies that the backup set is on an available file system.
- tape
- Specifies that the backup set is on an available tape device.
Option | Where to use |
---|---|
dirsonly | Command line only. |
filesonly | Command line only. |
ifnewer | Command line only. |
preservepath | Command line only. |
![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
![]() |
![]() |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() ![]() ![]() ![]() ![]() |
Examples
- Task
- Restore the entire backup set called monthly_financial_data.87654321 from
the server.
dsmc restore backupset
-backupsetname=monthly_financial_data.87654321
-loc=server Task
Restore the entire backup set contained in the file: /home/budget/weekly_budget_data.ost.
dsmc restore backupset
-backupsetname="/home/budget/weekly_budget_data.ost"
-loc=fileTask
Restore the entire backup set from the /dev/rmt0 device.
dsmc restore backupset
"-backupsetname=/dev/rmt0" -loc=tapeTask
Restore a single file named /home/jones/budget.dev from the /dev/rmt0 tape device, to the original source path.
dsmc restore backupset
-backupsetname=/dev/rmt0 "/home/jones/budget.dev"
-loc=tapeTask
Restore all files in the budget directory that contain a file extension of .txt from the tapes on the /dev/rmt0 device, to the original source path.
dsmc restore backupset "/home/budget/*.txt"
-backupsetname=/dev/rmt0 -loc=tapeTask
Restore the entire backup set contained in local file named "/home/jones/bset01.file"
dsmc restore backupset
-backupsetname="/home/jones/bset01.file"
-loc=fileTask
Restore groups from the backup set mybackupset.12345678 on the Tivoli Storage Manager server to the /home/devel/projectb directory. The groups' virtual file space is accounting.
dsmc restore backupset {/accounting}/*
/home/devel/projectb/
-backupsetname=mybackupset.12345678 -loc=server
-subdir=yesTask
Restore groups from the local backup set mybackupset.ost to the /home/devel/projectb/ directory. The groups' virtual file space is accounting.
dsmc restore backupset {/accounting}/*
/home/devel/projectb/
-backupsetname=mybackupset.ost
-loc=server -subdir=yesTask
Restore the entire backup set from the \\.\tape0 device.
dsmc restore backupset
-backupsetname=\\.\tape0 -loc=tapeTask
Restore groups from the backup set mybackupset.12345678 on the Tivoli Storage Manager server to the c:\newdevel\projectn directory. The groups' virtual file space is accounting.
dsmc restore backupset {accounting}\*
c:\newdevel\projectn\
-backupsetname=mybackupset.12345678
-loc=server -subdir=yesTask
Restore the entire backup set contained in the file: c:\budget\weekly_budget_data.ost.
dsmc restore backupset
-backupsetname=c:\budget\weekly_budget_data.ost
-loc=fileTask
Restore the \budget\ directory and subdirectories from the backup set contained in the file: c:\budget\weekly_budget_data.ost.
dsmc restore backupset m:\budget\*
-backupsetname=c:\budget\weekly_budget_data.ost
-loc=file -subdir=yesTask
Restore the file \budget\salary.xls from the backup set contained in the file: c:\budget\weekly_budget_data.ost.
dsmc restore backupset m:\budget\salary.xls
-backupsetname=c:\budget\weekly_budget_data.ost
-loc=file -subdir=yesTask
Restore the system state that is contained in the backup set file: \recovery\backupsetfile.name. Replace all components; do not prompt for each component.
dsmc restore backupset systemstate
-BACKUPSetname=c:\recovery\backupsetfile.name
-loc=file -replace=all