Using the UNIX Backup-Archive Clients


Backing Up Files and Directories

There are two types of backup using ADSM: incremental and selective.

An incremental backup backs up all files that are new or that have changed since the last incremental backup.
A selective backup backs up the specific files you indicate.

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

Backing Up New and Changed Files

The most effective way of maintaining a complete set of backup versions for your most important files is to regularly run incremental backups. An incremental backup backs up the new or changed files on your workstation.

There are two types of incremental backup: full and partial. A full incremental is also referred to simply as an incremental backup.

Do You Want a Full or Partial Incremental?

If you are a casual user of ADSM, and you do not want to worry about the details, skip this section and perform only full incremental backups of your file systems. See "Running a Full Incremental Backup" for how to perform full incremental backups.

There are two main differences between full and partial incremental backup:

In a full incremental, the client queries the ADSM server so that it knows the exact state of your storage as of your last incremental. During a full incremental, ADSM uses this information to:

All of this processing is required to maintain your backups according to the policies defined in the management classes.

In a partial incremental, only certain information is considered when deciding whether to back up a file. You can specify one of two types of partial incremental backups:

In both types of partial incremental, files are not expired or rebound on the server; in addition, the copy group's frequency attribute of the management classes is ignored.

Use partial incremental only if you must meet a limited backup time window, and a full incremental takes longer than the allowed time. Periodically perform full incremental backups to bring the ADSM server in line with your workstation's status. For example, if you have only a limited time during the week to perform backups, but extra time on the weekend, you can use partial backups on the weekdays, and then use full incremental backups on the weekends.

Running a Full Incremental Backup

To run a full incremental backup:

  1. Click on Backup files and directories from the ADSM Hub window. The Backup window displays.
  2. Expand the directory tree. Click on the directory and files you want to backup.
  3. Click on Changed or Deleted Files from the Type of Backup list.
  4. Click on Backup. The Backup Status window displays the backup processing status.

ADSM starts the incremental backup, and displays the status of the backup in the Backup Status window (see "Understanding the Backup Status Window"). ADSM tells you when the backup is complete. The first time you do an incremental backup, ADSM has to back up all your files, which can take a long time. Subsequent backups usually do not take as long.

Running an Incremental Backup by Date

To run an incremental backup by date:

  1. Click on Backup files and directories from the ADSM Hub window. The Backup window displays.
  2. Expand the directory tree. Click on the directories and files you want to back up.
  3. Click on Quick: Changed Files from the Type of Backup list.
  4. Click on Backup. The Backup Status window displays the backup processing status.

ADSM starts the incremental by date, and displays the status of the backup in the Backup Status window (see "Understanding the Backup Status Window").

Understanding the Backup Status Window

During any type of backup, ADSM uses the Backup Status window to provide you with statistics on your backup. ADSM does not use the Backup Status window with the command line or for schedule backups.

Using an Include-Exclude Options File to Control Processing

Usually, there are files on some of your file systems that you do not want to back up. Those files might be core files, local caches of network file systems, operating system or application files that could be easily recovered by reinstalling the program, or any other files that you could easily rebuild.

An ADSM authorized user on your workstation can use the EXCLUDE and INCLUDE options in your include-exclude options file to tell ADSM which files to exclude from backup processing.

If you have the ADSM HSM client installed on your workstation, the EXCLUDE option excludes a file from both backup and space management services. You can use the EXCLUDE.BACKUP option to exclude a file from backup services only, and you can use the EXCLUDE.SPACEMGMT option to exclude a file from space management services only.

ADSM honors the include-exclude options file whether you are doing an incremental or selective backup. ADSM backs up any file that is not explicitly excluded from backup. You do not need to use an INCLUDE option to include specific files unless those files are in a directory you are trying to exclude.

The INCLUDE and EXCLUDE options can also be specified in the dsm.sys file. For more information on creating an include-exclude options file, see "Creating an Include-Exclude Options File".

Setting a Virtual Mount Point

If you want ADSM to consider files for backup beginning with a specific directory within a file system, an ADSM authorized user can define that directory as a virtual mount point (see Virtualmountpoint).

Defining a virtual mount point within a file system provides a direct path to the files you want to back up, thus saving processing time. It is more efficient than defining the file system with the DOMAIN option, and then using an EXCLUDE option in your include-exclude options file to exclude the files you do not want ADSM to consider for backup. It also allows you to store backups and archives for specific directories in separate file spaces in ADSM storage.

Understanding How ADSM Stores Files in File Spaces

When you back up and archive files, ADSM stores the backups and archives in a file space in ADSM storage that has the same name as the file system or virtual mount point from which the files originated.

For example, if you have a file system named /home, and you back up a file named doc1 in the /home/jones directory, ADSM stores the file in a file space named /home. However, if an ADSM authorized user subsequently defines /home/jones as a virtual mount point, any files you back up from the /home/jones directory, such as doc2, are stored in a file space named /home/jones.

If you enter this command:

  dsmc query backup /home/jones/*

ADSM looks for files in the /home/jones file space. It always looks for a file in the file space with the longest name that matches the file specification you include in a command. It finds the file named doc2 that was backed up after the virtual mount point was defined. However, it does not find the file named doc1 because that file was backed up before the virtual mount point was defined, and the backup was stored in the /home file space.

To list or restore the doc1 file using a command, you must specify the file space name explicitly by enclosing it in braces. For example:

   dsmc query backup {/home/}jones/*
   dsmc restore {/home/}jones/doc1

If the ADSM authorized user subsequently removes the /home/jones virtual mount point, and you then back up additional files in the /home/jones directory, the backups are once again stored in the /home file space. For example, if you now back up a file named doc3 in the /home/jones directory, it is stored in the /home file space. It is not stored in the existing /home/jones file space.

However, because the /home/jones file space already exists, when you try to list or restore the doc3 file, ADSM looks in the /home/jones file space for the file unless you specify the correct file space name as follows:

   dsmc query backup {/home/}jones/*
   dsmc restore {/home/}jones/doc2
Note:You must specify the file space name explicitly only when there can be more than one resolution to the file specification you enter.

Here is another example. If these file spaces exist in ADSM storage:

   /home
   /home/jones
   /home/jones/project1
   /home/jones/project1/planning

and you enter this command:

   dsmc query backup /home/jones/project1/planning/*

ADSM looks for files only in the /home/jones/project1/planning file space, even if one or more of the other file spaces contains a path with the same name. But, if you enter:

   dsmc query backup {/home/}jones/project1/planning/*

ADSM looks for files only in the /home file space.

Or, if you enter one of the following:

   dsmc query backup {/home/jones/}project1/planning/*
   dsmc query backup {/home/jones/project1/}planning/*

ADSM looks for files only in the /home/jones file space or the /home/jones/project1 file space.

Saving Access Permissions

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

If you use the AFS or DFS versions of the DSM and DSMC commands (DSMAFS and DSMCAFS for AFS, DSMDFS and DSMCDFS for DFS) to back up AFS or DFS files (on an AIX workstation only), ADSM also saves the access control lists that exist for each AFS or DFS directory. If you back up AFS or DFS files using the non-AFS/DFS versions, ADSM backs up the files and standard UNIX access permissions, but does not save the AFS or DFS access control lists for directories. See "Using the AFS/DFS Versions of ADSM" for more information.
Note:If an ADSM authorized user backs up files for a user, the user owns the backup versions of the files on ADSM storage. The ADSM authorized user does not need to grant the user access to the backup versions.

Incremental Backup: Advanced Considerations

This section discusses some advanced considerations for using incremental backup. You do not need to understand this information in order to use ADSM for basic work.

Starting an Incremental Backup with a Command

You can perform an incremental backup from the command line using the INCREMENTAL command. For example, to back up the /home file system, issue:

   dsmc incremental /home 

If you do not indicate the file systems you want backed up, ADSM uses your default domain (see "Setting Your Default Domain"). You can add file systems to the default domain with the DOMAIN option. For example, if your default domain contains file systems /home and /usr, you can back up those file systems plus the /mfg file system using:

   dsmc incremental -domain="/mfg"

To start an incremental by date, add the INCRBYDATE option:

   dsmc incremental -incrbydate

When the INCREMENTAL command completes, ADSM provides you with statistics similar to those shown in the GUI's Backup Status window. Similar statistics are produced by the selective and archive commands. These also show up in the schedule log for scheduled commands. See Incremental for more information about the INCREMENTAL command.

Setting Your Default Domain

When you start ADSM, or use the INCREMENTAL command without indicating file systems, ADSM automatically selects the file systems in your default domain as the file systems to process. Your default domain is set with the DOMAIN option in your client user options file (see Domain). If you do not have the DOMAIN option set, the default domain is all local file systems.

Understanding What ADSM Considers a Changed File

For full incrementals, ADSM considers a file to be changed if any of these items are different from the last backup taken:

Understanding Which Files Are Backed Up

When you request an incremental backup, ADSM backs up a file if all of the following requirements are met:

When you run an incremental backup, ADSM also backs up all directory information which is not already backed up. You can exclude the files within a directory or a directory from being backed up. Directories are counted in the number of objects backed up.

Understanding How Your Files Are Managed

ADSM uses management classes to determine how to manage your backups on the ADSM server. Every time you back up a file, the file is assigned a management class. The management class used is either a default chosen for you, or one assigned to the file by an ADSM authorized user with an INCLUDE option in the include-exclude options file. The chosen management class must contain a backup copy group in order for the file to be backed up. See Chapter 5. "Automating ADSM Tasks" for more information on management classes and how an ADSM authorized user assigns them to files.

Understanding How Symbolic Links Are Handled

A UNIX symbolic link is a file that contains a pointer to another file or directory. ADSM handles symbolic links differently than it does regular files and directories. In some operations, such as a backup, only the path information that the symbolic link contains is backed up. In other operations, such as archive, the file to which the symbolic link points is archived, but under the name of the symbolic link.

For directories, most operations are affected by the setting of the SUBDIR option. If the SUBDIR option is set to no, only the directory and the files it contains are affected. If the SUBDIR option is yes, ADSM recursively processes all files and directories in the directory tree.

Incremental Backup: When you run an incremental backup, ADSM backs up only the path information to a file or directory to which a symbolic link points. The contents of the file or the contents of files in the directory are not backed up.

Selective Backup: When you run a selective backup on a symbolic link that points to a file, ADSM backs up only the path information to that file. The contents of the file are not backed up.

Restore: When you restore a symbolic link that originally pointed to a file, the symbolic link is restored, regardless of whether the file it points to still exists.

If you restore a symbolic link that originally pointed to a directory, without the files in the directory (for example, /home/smith/symdir/), and the symbolic link does not exist on your file system, nothing is returned.

If you restore a symbolic link that originally pointed to a directory, along with the files in the directory (for example, /home/smith/symdir/*), and the symbolic link does not exist on your file system, ADSM builds the directory on your workstation and puts the files in that directory. If the SUBDIR option is set to yes, ADSM recursively restores all subdirectories of the directory.

If you restore a symbolic link that originally pointed to a directory, and the symbolic link already exists on your workstation, the result depends on how the FOLLOWSYMBOLIC option is set. If the FOLLOWSYMBOLIC option is set to yes, the symbolic link is restored and overwrites the directory on your workstation. If the FOLLOWSYMBOLIC option is no (which is the default), ADSM displays an error message.
Note:If the FOLLOWSYMBOLIC option is set to yes, a symbolic link can be used as a virtual mount point.

Understanding How Hard Links Are Handled

A hard link is established when two files point to the same data file. When you back up a file that contains a hard link to another file, ADSM stores both the link information and the data file on the ADSM server. If you back up two files that contain a hard link to each other, ADSM stores the same data file under both names, along with the link information.

When you restore a file that contains hard link information, ADSM attempts to reestablish the links. If only one of the hard-linked files is still on your workstation, and you restore both files, ADSM hard-links them together.

The one exception to this procedure occurs if you back up 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 restore the two files from the ADSM server, ADSM will respect the current file system and not restore the hard link.

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

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

Understanding How NFS Hard and Soft Mounts are Handled

When you connect an ADSM backup-archive client to an NFS file system, you can use either a hard mount or a soft mount. ADSM uses the nfstimeout option setting to determine how long to wait for an NFS system call to respond before timing out, this applies to hard and soft mounts. The default is 2 seconds.

You should be aware of the consequences of hard and soft mounts if the mount becomes stale (for example, if the server for the file system is not available).

Backing Up Opened Files

ADSM looks for files that have changed between the start of the file's backup and it's completion, some files on your system may be in use, or opened, when you try backing them up, because an open file is likely to change, it is likely that any backup of an open file will not correctly reflect the contents of the file at a given time.

If you find that certain files are not getting backed up because they are open and get changed when you try backing them up (or when the backup schedule starts), you need to consider your options:

Backing Up Specific Files or Directories

A selective backup backs up specific files, a group of files with similar names, or entire directories that you indicate.

You can choose the files you want to back up either by using a file specification (the path, name, and extension of the file) or by choosing the files or directories from a directory list.

Backing Up Specific Files Using File Specifications

To back up selected files using file specifications you must specify the file name or path in the Find Files (Backup) window:

  1. Click on Backup files and directories from the ADSM Hub window. The Backup window displays.
  2. Expand the directory tree. Click on the directory or file you want to backup.
  3. Click on the Search icon on the tool bar. The Find Files (Backup) window displays.
  4. Enter your search criteria in the Find Files (Backup) window.
  5. Click on Search. The Matching Files (Backup) window displays.
  6. Click on the selection boxes next to the files you want to back up and close the Matching Files (Backup) window by selecting Edit then Close.
  7. Click on Always Backup from the Type of Backup list.
  8. Click on Backup. The Backup Status window displays the backup processing status.

Backup Using Directory Tree Filtering

Filtering a directory tree task lets you display, in the right hand side section of the file tree, only the files that match the filter criteria for your backup. Any files that do not match the filter criteria do not display. To filter a directory tree in preparation for your back up:

  1. Click on Backup files and directories from the ADSM Hub window. The Backup window displays.
  2. Expand the directory tree. Click on the directory or file you want to backup.
  3. Click on Search icon on the tool bar. The Find Files (Backup) window displays.
  4. Enter your filter criteria in the Find Files (Backup) window.
  5. Click on Filter.
  6. Click on Always Backup from the Type of Backup list.
  7. Click on the selection boxes next to the files or filtered directories you want to back up.
  8. Click on Backup. The Backup Status window displays the backup processing status.

Selective Backup: Advanced Considerations

This section discusses some advanced considerations for using selective backup. You do not need to understand this information in order to use ADSM for basic work.

Backing Up Specific Files Using Commands

You can use the SELECTIVE command to back up specific files. Use wildcards to back up more than one file at a time. If you back up a directory, you can use the SUBDIR=YES option to include all the subdirectories under that directory in the backup.

For example, to back up the /home/jones/proj directory and its subdirectories, use:

   dsmc selective /home/jones/proj/ -subdir=yes

If a subdirectory is a mounted file system, ADSM does not back up the files in that subdirectory when you use the SUBDIR=YES option.

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

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

When the SELECTIVE command completes, ADSM provides you with statistics similar to those shown in the GUI's Backup Status window. Similar statistics are produced by the incremental and archive commands. These also show up in the schedule log for scheduled commands. See Selective for more information about the SELECTIVE command.

Using Wildcard Characters

You can use the operating system's wildcard characters in file specifications with ADSM, including on ADSM commands, for most ADSM tasks. These characters allow you to select groups of files that have similar names.

In a command, wildcard characters can only be used in the file name or extension. They cannot be used to specify destination files, file systems, or directories. When using wildcard characters in non-loop mode, as in dsmc sel /home/*, enclose the parameter containing asterisk in quotes, such as dsmc sel "/home/*", to insure the system does not interpret the wildcard character and produce unexpected results.

The wildcard characters are:

*
Asterisk. This stands for zero or more characters. For example:
*.exe matches all files that have an extension exe
hm*.* matches all files that start with hm, regardless of extension
hm* matches all files that start with hm, regardless if an extension exists or not
*h*.* matches all files with an h somewhere in the file name, regardless of extension

?
Question mark. This stands for one character. For example:
?.exe matches all files with the extension exe that have one, and only one, character in their file name
hm?.exe matches all files that have three-character names beginning with hm and that have the exe extension

You can combine the asterisk and question mark in a file specification. For example, ??hm.* matches all four-character file names ending in hm., no matter what extension they have.
Note:In a path name for a file specification, you cannot specify a directory whose name is an asterisk (*) or a question mark (?). ADSM will recognize those characters only as wildcard characters.

Sorting File Lists

To sort the files in the File List, you can select either:

You can sort a file list, whether you are backing up, restoring, archiving, or retrieving them. Sorting files by last modification date is especially useful if you are trying to recover files to their state as of a particular date.

Understanding Which Files Are Backed Up

When you request a selective backup, ADSM backs up a file if all of the following requirements are met:

When you run a selective backup, ADSM also backs up all directory information. You can exclude the files within a directory or a directory from being backed up. Directories are counted in the number of objects backed up.

WebShell Backup Selection Web Page

The WebShell client Backup Selection web page provides both backup information and actions. It states the name of the accessed workstation. It lists the file systems on the accessed workstation and the date and time of their last incremental backup. It also provides two types of actions: actions relative to a selected file system and general actions.

The actions relative to a selected file system are:

Backup New/Changed Files
For the selected file system, backup all new and changed files (i.e., an incremental backup). If no file system is selected, all new and changed files are backed up for the file systems specified within the client domain (see ADSM options file). If there is no explicit client domain, the default file systems are the local file systems on the workstation. The results of the incremental backup operations will be displayed immediately following the redisplay of this web page.

View Backup Menu
For the selected file system, view the directories and files on the accessed workstation. (If no file system is selected, the default is the boot file system.) From there you can selectively back up directories and files to the ADSM server.
Note:An input field is provided so that you can enter the fully qualified path name of a directory to view via View Backup Menu. Unless it is an actual file system, you will not be able to Backup its New/Changed Files. That is an ADSM restriction.

The general actions are:

Refresh Backup Status
Refresh the file system selection list and the date and time of their last incremental backup. This is typically used after a Backup New/Changed Files operation to refresh the dates/times.

End Authenticated Session
Typically Web browsers will cache the userid and password entered to start the WebShell session, so that it only has to be entered once per session. The End Authenticated Session operation will force the userid and password to be re-entered on the next WebShell interaction through this Web browser. This would typically be used in a help desk or ADSM administrative environment where the Web browser is located in a public area. When the help desk or ADSM administrative person finishes the WebShell interactions with each accessed workstation, he should End Authenticated Session.

Change User
This operation is only available for user root on AIX. The default mode for root is to access all the directories and files on the workstation. With the Change User operation, root can now access/backup/restore the directories and files of a particular user on the workstation.

The date and time of the last successful incremental backup for each file system on the accessed workstation is displayed. If none of the dates and times are present, then one of the following conditions might exist:

If some of the dates and times are not present, then there have been no successful incremental backups for those file systems.

WebShell View Backup Menu

The purpose of WebShell client View Backup Menu is to list the directories and files within the selected file system, so as to perform a selective backup.

Use the built in file manager to traverse the directories on the accessed workstation. To change directories within the selected file system (e.g., from TCPIP to ADSM):

Displayed within the Directories selection box and the Files selection box are the directories and files, respectively, contained within the top directory of the selected file system. When a directory is changed, the directories and files displayed will be those contained within the changed directory.

Backup Path will display the fully qualified path from the top of the selected file system.

File Filter allows the display of files to be restricted. For example to only display the C++ source files within a directory, type *.cpp . Or to only display versions of config.sys, type config.* .

The and its sub-directories option will recursively descend directories allowing files within sub-directories to also be backed up. To turn on the option, check its box. To turn it off, check its box again.

From the View Backup Menu you can backup:

To backup a specific file or a group of files:

To backup a specific directory (that is all the files within that directory):

To backup a specific tree (that is all the files within that directory and all its sub-directories):

To backup the files within the file system (all files, not just the new and changed files):


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