Creating restore specifications

Contributors Download PDF of this page

The restore specification file is an XML file that contains the original and alternate locations from which the file can be restored. SnapManager uses this specification file to restore files from the specified location.

You can create the restore specification file by using any text editor. You must use a .xml extension for the file.

  1. Open a text file.

  2. Enter the following: <restore-specification xmlns="http://www.netapp.com">

  3. Enter any file mapping information using the format shown in the following example:

    <file-mapping>
        <original-location>/path/dbfilename.dbf</original-location>
        <alternate-location>/path/dbfilename1.dbf</alternate-location>
    </file-mapping>

    File mapping specifies where a file is restored from. The original location is the location of the file on the active file system at the time of backup. The alternate location is the location from where the file is restored.

  4. Enter any mounted file system mapping information using the format shown in the example:

    <mountpoint-mapping>
         <original-location>/path/db_name</original-location>
         <snapname>snapname</snapname>
         <alternate-location>/path/vaultlocation</alternate-location>
    </mountpoint-mapping>
    <mountpoint-mapping>
         <original-location>+DiskGroup_1</original-location>
         <snapname>snapname</snapname>
         <alternate-location>+DiskGroup_2</alternate-location>
    </mountpoint-mapping>

    Mountpoint refers to directory path /mnt/myfs/)or an Automatic Storage Management (ASM) disk group mountpoint (for example, +MY_DG). The mountpoint mapping specifies the mountpoint from which the files are restored. The original location is the location of the mountpoint in the active file system at the time of backup. The alternate location is the mountpoint from which the files in the original location are restored. The snapname is the name of the Snapshot copy in which the original files were backed up.

    For ASM, the disk group name must be the same as the disk group that SnapManager cloned to register the backup with RMAN. This name can be obtained by viewing the backup properties.

    Note The Snapshot copy name is a necessary component because the same file system can be used multiple times in a single backup operation (for example, once for the data files and once for the logs).
  5. Enter raw device mapping tags and locations using the format shown in the example:

    <raw-device-mapping>
         <original-location>/path/raw_device_name</original-location>
         <alternate-location>/path/raw_device_name</alternate-location>
    </raw-device-mapping>

    Raw device mapping specifies the location from which a raw device is restored.

  6. Enter the following: </restore-specification>

  7. Save the file as a .xml file and close the specification.

Restore specification example

The following example shows the restore specification structure:

<?xml version="1.0" encoding="UTF-8"?>
<restore-specification xmlns="http://www.netapp.com">
<!-- "Restore from file(s)" -->
     <file-mapping>
          <original-location>/mnt/pathname/dbname/users01.dbf</original-location>
          <alternate-location>/mnt/vault/users01.dbf</alternate-location>
     </file-mapping>
<!-- "Restore from host mounted file system(s)" -->
     <mountpoint-mapping>
          <original-location>/mnt/pathname/dbname/fs</original-location>
          <snapname>Snapshotname</snapname>
          <alternate-location>/mnt/vaultlocation</alternate-location>
     </mountpoint-mapping>
<!-- "Restore from ASM mounted file system(s)" -->
     <mountpoint-mapping>
          <original-location>+DISKGROUP_1</original-location>
          <snapname>snapshotname</snapname>
          <alternate-location>+DISKGROUP_2</alternate-location>
     </mountpoint-mapping>
<!-- "Restore from raw device" -->
     <raw-device-mapping>
          <original-location>/pathname/devicename</original-location>
          <alternate-location>/pathname/devicename</alternate-location>
     </raw-device-mapping>
</restore-specification>