Tivoli Storage Manager for UNIX Using the Backup-Archive Clients


Chapter 4. Archiving and Retrieving Files

Archiving and retrieving files is similar to backing up and restoring files. Many of the windows and concepts are similar. In this chapter, we cover the main archive and retrieve tasks, but where windows and concepts are the same as for backup and restore see Chapter 3, Backing Up and Restoring Files.

Task Page
"Performing Estimates" "Performing Estimates"
"Archiving Files Using a Directory Tree" "Archiving Files Using a Directory Tree"
"Deleting Archived Files" "Deleting Archived Files"
"Archive Using Commands" "Archive Using Commands"
"Performing Retrieves" "Performing Retrieves"
"Retrieve Using Commands" "Retrieve Using Commands"

Archiving Files

To archive files, you need to specifically select the files to archive. You can select the files by using a file specification or by selecting them from a directory tree.

Your administrator might have set up schedules to archive certain files on your workstation automatically. See Chapter 5, Automating TSM Tasks for information on checking and running the schedules available to you. The following sections cover how to archive files without using a schedule.

Performing Estimates

You can use the estimate function to estimate the amount of time it takes to process your files and directories. The estimated time is a rough calculation of the time it takes TSM to transfer your data and is based on previous transfers of data between your workstation and the current server. The actual transfer time could be longer or shorter than the estimate due to factors like network traffic, system load on your workstation, or system load on the server.

Archiving Files Using a Directory Tree

Archive a file or a group of files using file names. Or select only the files that match your search criteria using a directory tree. Perform archives using the following procedure:

  1. Click Archive files and directories into long term storage from the TSM main window. The Archive window displays.
  2. Expand the directory tree.
  3. Click on Search from the tool bar. The Find Files (Archive) window displays.
  4. Enter your selection criteria in the Find Files (Archive) window.

    To Search:

    1. Click Search. The Matching Files (Archive) window displays.
    2. Select the selection boxes next to the files you want to archive. Click on Edit; then click on Close to exit. The files selected in the search window display in the tree.

    To Filter:

    1. Click on Filter. The selected files do not display in the tree.
    2. Click the selection boxes next to the files you want to archive.
  5. Enter the description, accept the default description, or a selected existing description for your archive package in the Description box. When an existing archive description is used, the files or directories selected are added to the archive package. All archived packages with the same description are grouped for retrieves, queries, and deletions.
  6. Click on Archive. The Archive Status window displays the archive processing status.

Displaying Archive Processing Status

During a backup or archive, TSM uses a window to provide statistics on the backup or archive processing status.

Deleting Archived Files

You can delete archive copies if you decide you no longer need them. Unlike backup versions, you can delete individual archive copies without deleting the entire file space. To delete an archive copy:

  1. Click on Utilities from the TSM main window.
  2. Click on Delete Archive Data. The Archive Delete window displays.
  3. Expand the directory tree. The directory tree contains groups of files identified by a description and archived to the server.
  4. Click the selection boxes to select the objects you want to delete.
  5. Click on Delete. The Archive Delete Status window displays the archive deletion processing status.

If you are using commands, you can delete archive copies with the delete archive command.

For example, to delete the file /home/jones/t.exe, enter:

   dsmc delete archive /home/jones/t.exe

Archive: Advanced Considerations

This section covers some advanced considerations in archiving files. You do not need to understand this information in order to use TSM for basic work.

Archive Using Commands

You can use wildcards to archive more than one file at a time. You can archive all the files in a directory, and you can use the subdir=yes option to include files in all subdirectories under that directory. Use the deletefiles option if you want TSM to delete the files from your local workstation after they are archived and committed to storage.

For example, to archive the files in the /home/jones/proj directory and the files in its subdirectories, enter:

   dsmc archive /home/jones/proj/ -subdir=yes -deletefiles

You can use more than one file specification on the archive command. For example, to archive the /home/jones/h1.doc and /home/jones/test.doc files, use:

   dsmc archive /home/jones/h1.doc /home/jones/test.doc

Use the description option to assign a description to the archive:

   dsmc archive /home/jones/h1.doc -description="Chapter 1, first version"

When the archive command completes, TSM provides you with statistics similar to those shown in the Archive Status window. Similar statistics are produced by the incremental and selective commands. These also show up in the schedule log for scheduled commands. See Archive for more information.

Saving Access Permissions

When you archive a file, TSM saves standard UNIX access permissions assigned to the file. Depending on your operating system, it also saves extended permissions. For example, for files on an AIX workstation, TSM saves access control lists.

If you are a user, and you archive a file to which you have read access, you own the archived copy of the file. You are the only user who can retrieve the archived file unless you grant access to another user.

Understanding How Symbolic Links are Handled

When you archive a symbolic link, TSM archives the file to which the symbolic link points. It does not archive path information for the directory.

If you archive a symbolic link that points to a directory, TSM archives the files contained in the directory (and its subdirectories if the subdir option is set to yes) under the name of the symbolic link.

The following table shows symbolic link archive and retrieve functions and the action taken:

Figure 5. Symbolic Link Management Table for Archive and Retrieve

Function Action Taken
Archive of a file link. Archives the file to which the symbolic link points.
Archive of a directory link. Archives the directory and its contents.
Archive of a file with subdir=yes. Archives the directory, its contents and contents of subdirectories.
Archive of a directory with subdir=yes. Archives the directory, its contents and contents of subdirectories.
Archive of a symbolic link that points to a file or directory that does not exist. Archives the symbolic link.
Retrieve a symbolic link that points to file; the file and link exist. Replaces the file if replace=y is set.
Retrieve a symbolic link that points to file; the symbolic link no longer exists. Retrieves the file replacing the file name with the symbolic link name, and places it in the directory where the symbolic link resided.
Retrieve a symbolic link that points to a directory; the symbolic link and directory no longer exist. A directory is created in the directory where the symbolic link resides, and all files and subdirectories are restored to that directory. The symbolic link name is used as the new directory name.
Retrieve a symbolic link that points to a directory; the symbolic link and directory still exist. TSM will not retrieve as long as the symbolic link exists.

Understanding How Hardlinks are Handled

When you archive a file that contains a hard link to another file, TSM stores both the link information and the data file on the server.

When you retrieve a file that contains hard link information, TSM attempts to establish the links again. If only one of the hard-linked files is still on your workstation, and you retrieve both files, TSM retrieves both files and hard-links the retrieved files.

The one exception to this procedure occurs if you archive two files that are hard-linked together, and then break the connection between them on your workstation. The two files then contain separate data files. If you retrieve the two files from the server, TSM respects the current file system and does not restore the hard link.

Problems can occur if you archive only one file of a hard-linked pair. For example, files texta and textb contain a hard link to each other. You archive texta, and then edit textb and make changes. If you retrieve texta, the changes you made to textb are lost.

To ensure that hard-linked files remain synchronized, always archive all files that have hard links to each other at the same time, and retrieve those same files together.


Retrieving Archives

Retrieve a file when you want to return an archive copy from the server to your workstation.

Retrieve Compared to Restore

Many of the advanced considerations for retrieving files are the same as they are for restoring files. See Authorizing Another User to Restore/Retrieve Your Files, Restoring or Retrieving Another User's Files, and Restore or Retrieve Files to Another Workstation.

Performing Retrieves

To retrieve an archived file:

  1. Click Retrieve files and directories from long term storage from the TSM main window. The Retrieve window displays.
  2. Expand the directory tree. Select the objects you want to retrieve.
  3. Click the Search icon on the tool bar. The Find List (Retrieve) window displays.
  4. Enter your search information in the Find Files (Retrieve) window.
  5. Click Search. The Matching Files (Retrieve) window displays.
  6. Click the selection boxes next to the files you want to retrieve. Close the Matching Files (Retrieve) window.
  7. Click Retrieve. The Retrieve Destination window displays.
  8. Enter the information in the Retrieve Destination window.
  9. Click Retrieve. The Retrieve Status window displays the retrieve processing status.

Retrieve: Advanced Considerations

This section discusses some advanced considerations for retrieving files. You do not need to understand this information in order to use TSM for basic work.

Retrieve Using Commands

Use the retrieve command to retrieve files. Indicate the file you want to retrieve and the destination. If you do not indicate a destination, the files are retrieved to their original location. For example, to retrieve the /home/jones/h1.doc file to its original directory, enter:

   dsmc retrieve /home/jones/h1.doc

To retrieve the /home/jones/h1.doc file under a new name, enter:

   dsmc retrieve /home/jones/h1.doc /home/jones/h2.doc

Use the pick option to get a list of archives from which you can select. Also see Retrieve for more information.

Understanding How Your Archives Are Managed

As with backing up files, TSM checks the include options in your include-exclude options file to determine which management class to assign to your archived files. If you do not specifically assign a management class to a file with an include option, TSM assigns the file the default management class. TSM can only archive a file if the selected management class contains an archive copy group.

You can override the default management class by using the archmc option, or by selecting the management class from the Archive Options menu in the GUI.

For information on the various management class attributes used to manage your archives, see Displaying Information About Management Classes and Copy Groups. See Assigning a Management Class to Files for information about using the include-exclude options file.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]