Restore From TSM

When using TSM as your backup solution, the GUI is not the fastest way to do your restore. IBM even recommends using the command line when restoring a large amount of data. So, let’s do that.

The syntax for dsmc is not the easiest to remember, for example, to restore all under D:\Data this would be the command for the latest version.

C:\Program Files\Tivoli\TSM\baclient\dsmc.exe restore -inactive -subdir=yes D:\Data\* E:\Restore\

or, to restore from last week it would look like this

C:\Program Files\Tivoli\TSM\baclient\dsmc.exe restore -inactive -subdir=yes -pitd=04/07/17  D:\Data\* E:\Restore\

Let’s simplify this with a PowerShell wrapper.


I’m using Start-Process to run dsmc, this allows me to redirect the output. I’ve chosen to put it in a text file in the Temp folder.
When the restore is completed, read the file and show the summary.

Output from script


The script is available on GitHub


Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.