HFS Storage Protect command line interface (2024)

The basic syntax for restoring your data is restore <source-file> <destination-filespec>For example:

Protect> restore "C:\My Documents\Word docs\*" "C:\My Documents\restore\"

If the destination-filespec is omitted then the files will be restoredto their original location. As with backup, you cannot use wildcards in directory/folder names.

By default, the software will restore the most current active version of a file.

If you plan to skip many files during the restoration process because they already exist in the chosen location, make sure to run the restore command with the -disablenqr=yes option. Failing to do so may lead to performance problems with the Storage Protect server.

Restoring multiple files and directories

In order to restore a full directory and the contents of all its sub-directories,you need to use the -subdir=yes option. It is always good practice to terminate the destination-filespec with a trailing \ (backslash) if the element in the destination-filespec is a directory.

Protect> restore "C:\My Documents\Word docs\*" "C:\My Documents\restore\" -subdir=yes

As this restore is wild-carded, it can be restarted if interrupted due to user input (Ctrl-C), server error or communications error. Restartable restores can be queried withquery restore and will restart at the point of interruption.

Restoring entire partitions

Essentially, the syntax is the same as in 'Restoring multiple files and directories' above. However, the obvious caveats are to ensure enough space in the destination partition and to allow enough time.

Protect> restore C:\* D:\restore\ -subdir=yes

As above, since this restore is wild-carded itcan be restarted if interrupted.

Restoring selected files

In order to specify a directory as a destination, you need a trailing \at the end of the destination-filespec, otherwise the software may overwrite a file of the same name:

Protect> restore "C:\My Documents\Word docs\mydoc.doc" "C:\My Documents\restore\"

Or to specify a filename as the destination-filespec:

Protect> restore "C:\My Documents\Word docs\mydoc.doc" "C:\My Documents\restore\myolddoc.doc"

Restores of single files cannot be restarted if interrupted, and you will need to restore the file afresh.

Restoring old and/or deleted files

As with the graphical user interface, by default the command line interface does not list or restore old and deleted inactive versions of files and directories. If you need to restore such a file, you need to use the -inactive option.

The -pick option, while not strictly necessary, causes the software to display a list of files from which to pick, allowing you toselect individual files to restore usinganumber to the filesleft.

The following restore command will also providethe pick interface:

Protect> restore "C:\My Documents\projects\*" "C:\My Documents\temp\restore\" -subdir=yes -inactive -pick

Remember to issue the destination-filespec with the original restore command if you want to prevent overwriting current versions of files with older versions.

The basic syntax for restoring your data is restore <source-file> <destination-filespec>For example:

Protect> restore /Users/ians/projects/hsm41test/* /Users/ians/projects/restore/

If the destination-filespec is omitted then the files will be restoredto their original location. As with backup, you cannot use wildcards in directory/folder names.

By default, the software will restore the most current active version of a file.

If you plan to skip many files during the restoration process because they already exist in the chosen location, make sure to run the restore command with the -disablenqr=yes option. Failing to do so may lead to performance problems with the Storage Protect server.

Restoring multiple files and directories

In order to restore a full directory and the contents of all its sub-directories,you need to use the -subdir=yes option. It is always good practice to terminate the destination-filespec with a trailing /(slash) if the element in the destination-filespec is a directory.

Protect> restore /Users/ians/projects/hsm41test/* /Users/ians/projects/restore/ -subdir=yes

As this restore is wild-carded, it can be restarted if interrupted due to user input (Ctrl-C), server error or communications error. Restartable restores can be queried withquery restore and will restart at the point of interruption.

Restoring entire partitions

Essentially, the syntax is the same as in 'Restoring multiple files and directories' above. However, the obvious caveats are to ensure enough space in the destination partition and to allow enough time.

Protect> restore /Users/* /tmp/restore/ -subdir=yes

As above, since this restore is wild-carded itcan be restarted if interrupted.

Restoring selected files

In order to specify a directory as a destination, you need a trailing /at the end of the destination-filespec, otherwise the software may overwrite a file of the same name:

Protect> restore /Users/ians/myfile.txt /Users/ians/restore/

Or to specify a filename as the destination-filespec:

Protect> restore /Users/ians/myfile.txt /Users/ians/restore/myoldfile.txt

Restores of single files cannot be restarted if interrupted, you will need to restore the file afresh.

Restoring old and/or deleted files

As with the graphical user interface, by default the command line interfacedoes not list or restore old and deleted inactive versions of files and directories. If you need to restore such a file, you need to use the -inactive option.

The -pick option, while not strictly necessary, causes the software to display a list of files from which to pick, allowing you toselect individual files to restore usinganumber to the filesleft.

The following restore command will also providethe pick interface:

Protect> restore /Users/ians/projects/* /Users/ians/temp/restore/ -subdir=yes -inactive -pick

Remember to issue the destination-filespec with the original restore command if you want to prevent overwriting current versions of files with older versions.

The basic syntax for restoring your data is restore <source-file> <destination-filespec>For example:

Protect> restore /home/ians/projects/hsm41test/* /home/ians/projects/restore/

If the destination-filespec is omitted then the files will be restoredto their original location. As with backup, you cannot use wildcards in directory/folder names.

By default, the software will restore the most current active version of a file.

If you plan to skip many files during the restoration process because they already exist in the chosen location, make sure to run the restore command with the -disablenqr=yes option. Failing to do so may lead to performance problems with the Storage Protect server.

Restoring multiple files and directories

In order to restore a full directory and the contents of all its sub-directories,you need to use the -subdir=yes option. It is always good practice to terminate the destination-filespec with a trailing /(slash) if the element in the destination-filespec is a directory.

Protect> restore /home/ians/projects/hsm41test/* /home/ians/projects/restore/ -subdir=yes

As this restore is wild-carded, it can be restarted if interrupted due to user input (Ctrl-C), server error or communications error. Restartable restores can be queried withquery restore and will restart at the point of interruption.

Restoring entire partitions

Essentially, the syntax is the same as in 'Restoring multiple files and directories' above. However, the obvious caveats are to ensure enough space in the destination partition and to allow enough time.

Protect> restore /home/* /tmp/restore/ -subdir=yes

As above, since this restore is wild-carded itcan be restarted if interrupted.

Restoring selected files

In order to specify a directory as a destination, you need a trailing /at the end of the destination-filespec, otherwise the software may overwrite a file of the same name:

Protect> restore /home/ians/myfile.txt /home/ians/restore/

Or to specify a filename as the destination-filespec:

Protect> restore /home/ians/myfile.txt /home/ians/restore/myoldfile.txt

Restores of single files cannot be restarted if interrupted, and you will need to restore the file afresh.

Restoring old and/or deleted files

As with the graphical user interface, by default the command line interface does not list or restore old and deleted inactive versions of files and directories. If you need to restore such a file, you need to use the -inactive option.

The -pick option, while not strictly necessary, causes the software to display a list of files from which to pick, allowing you toselect individual files to restore usinganumber to the files' left.

The following restore command will also providethe pick interface:

Protect> restore /home/ians/projects/* /tmp/restore/-subdir=yes -inactive -pick

Remember to issue the destination-filespec with the original restore command if you want to prevent overwriting current versions of files with older versions.

HFS Storage Protect command line interface (2024)

References

Top Articles
Latest Posts
Article information

Author: Dan Stracke

Last Updated:

Views: 6119

Rating: 4.2 / 5 (63 voted)

Reviews: 94% of readers found this page helpful

Author information

Name: Dan Stracke

Birthday: 1992-08-25

Address: 2253 Brown Springs, East Alla, OH 38634-0309

Phone: +398735162064

Job: Investor Government Associate

Hobby: Shopping, LARPing, Scrapbooking, Surfing, Slacklining, Dance, Glassblowing

Introduction: My name is Dan Stracke, I am a homely, gleaming, glamorous, inquisitive, homely, gorgeous, light person who loves writing and wants to share my knowledge and understanding with you.