Content, Filters, and Regular Expressions

Backup Restore Best Practices FAQs  

Restoring Files and Folders/Directories

Supported Wildcard Expressions

Mixed Mode Restores

Methods of Restoring Data using Wildcard Expressions

Restoring Files and Folders/Directories

Wildcard expressions can be used to restore file system data, to. This function provides the ability to restore files and/or folders/directories that have a common naming convention.

For example, msde2.txt and msj4j.txt.

When restoring directories, if a wildcard pattern that matches the name of a directory was specified, the system restores the directory, but none of the directory's contents. For example, if the wildcard restore string is tem?, the system restores any and all data named with a four-character string starting with the letters t, e, and m. If a directory name satisfies the wild card condition (e.g., sys:\temp) then only the directory would be restored; however, none of the files or any subdirectories contained therein are restored.

Supported Wildcard Expressions

A combination of wildcards in a single expression (e.g., access?.h*) can also be used. If the expression is specified by itself, without a path (*.txt), the system searches for and returns all data within the backup set that satisfies the expression. By preceding the expression with a path, the scope of the restored data can be narrowed. For example, specifying sys:\data\*.txt, would restore only those files and directories within the sys:\data directory with extensions of .txt.

The following Wildcards are supported for the respective agent type:

Mixed Mode Restores

In addition to specifying the data to be restored using the wildcard expressions, the system allows you to also select specific data to restore. This is known as a mixed mode restore. Both the selected data as well as the data that satisfies the wildcard expression(s) is restored, with one important exception. All directories that are to be restored, whether they were specifically named or selected, or merely satisfy the wildcard expression(s) are restored without their content. That is, any directory to be restored is handled in the same way as if the directory was being restored as a result of a wildcard expression.

  1. From the CommCell Browser, navigate to Client Computers | <Client> | <Agent>.
  2. Right-click the BackupSet and then click All Tasks | Restore.
  3. Enter the wildcard characters to specify the patterns for files and folders to be included in the restore.

    For example: If you want to restore all .dll files in C drive under folder Test, then specify C:\Test\*.dll

  4. In the Destination Client list, select the name of the client computer.
  5. Click the Job Initiation tab.
  6. Select Immediate from the Job Initiation tab.
  7. Click OK.

Restoring Data using Wildcard Expressions

The system provides two methods of using wildcard characters to restore data. They are:

Restoring Data Directly using Wildcards

This method of restoring data is fast because you do not have to browse the backup data first.

  1. From the CommCell Browser, navigate to Client Computers | <Client> | <Agent>.
  2. Right-click the BackupSet and then click All Tasks | Restore.
  3. Enter the starting path of the data that you want to restore.

    For example: If you want to restore all the files in C drive under folder Test, then specify C:\Test\

  4. In the Destination Client list, select the name of the client computer.
  5. Click the Job Initiation tab.
  6. Select Immediate from the Job Initiation tab.
  7. Click OK.

Browsing and Restoring Data Using Wildcards

This method of restoring data uses the browse feature. This method is helpful when you are uncertain of the organization of data that you want to restore.

  1. From the CommCell Browser, navigate to Client Computers | <Client> | File System | <Backup Set>.
  2. Right-click the <Subclient> in the right pane and then click Browse Backup Data.
  3. Click OK.
  4. Select the data that you want to restore and click Recover All Selected.
  1. In the Recover Options for All Selected Items dialog box, click Advanced.
  2. Select the Paths/Filters tab.
  3. If you want to remove any files or folders from restore operation, click Add for Filter Item list and enter the path of the data. Wildcard entries must be expressed as complete paths.

    You can also click Delete to remove existing source or filter items.

  4. In the Advanced Recover Options dialog box, click OK.
  5. In the Recover Options for All Selected Items dialog box, click OK.

 

Specifying Source Path for Restore

One of the advanced options available during a restore operation is the ability to specify a source path. Some iDataAgents allow you to choose to detect or ignore regular expressions (wildcard characters) in the specified source path. This allows you to restore files and folders which contain regular expressions in their name (e.g., c:\[test]). This is similar in concept to the use of wildcards in filters, and works according to these guidelines:

testing a restore without restoring data?

Use this procedure to test a restore job without writing to media, applicable for Windows, Unix and Macintosh File System iDataAgents. Testing a restore job allows you to get a list of all files that would be restored without actually restoring them, based on your restore selections and filters.

  1. Create a text file on the client that contains a list of all folders/directories to be included in the restore test. The purpose of this map file is to tell the system that you do not want these folders and any data contained within them to actually be restored. Use the following syntax:

    "c:\test",""

    Note that a Windows-based path is used in the above example. The path portion of the syntax will vary by operating system.

  2. Follow the procedure to Restore Data Using a Map File and be sure to select the option to Restore Unmapped Files.
  3. After the test restore job has completed, you can find the list of files/objects that would have been restored in a text file called restore.out residing within a subfolder (corresponding to the Job ID Number) of the Job Results directory on the client.

Filter Data From Restore/Recover Operations

Using the Restore/Recover Filter feature, you can specify the files, directories, file name patterns, or NDS containers/objects, that you want to filter from the restore data.

Supported Wildcard Characters

The following wildcard characters are supported by the restore filter operation. These characters can be used to broaden the scope of the filter operation:

Wildcard Character Definition
*, Any number of characters
?, Any one character
[] Any range or set of characters

You can also use a combination of wildcards in a single expression (e.g., access?.h*).

  1. When you reach the Restore Options (General) dialog box, click Advanced.
  2. From the Paths/Filters tab in the Advanced Restore Options dialog box, type the files, directories, file name patterns, or NDS objects that you want to filter in the Filter Paths pane.  Use the Add button to specify your filter entries.  Each entry must be specified as a complete path and must be a child of the Source Paths pane.  Wildcard entries must be expressed as complete paths (e.g. C:\Test\*.dll, or /usr/lib/*.so).
  3. Continue restore.