This chapter discusses the native NetWare 4 backup services. NetWare 4.x backup uses the Storage Management Services (SMS). SMS is a hardware- and software-independent method for performing backups.
This chapter describes the different backup strategies available to NetWare 4.x users:
This chapter will also show you how to use SBACKUP, the principal backup tool in NetWare 4.
In NetWare 4.x the backup services are consolidated in SBACKUP.NLM. Because SBACKUP is an NLM, it can only run on a NetWare server. The server on which the SBACKUP.NLM runs should have a backup device. This server is called the host server. The data source that is to be backed up and restored is called the target. The target could be a file system, a NetWare 3.x server, a NetWare 4.x server, or a DOS or OS/2 workstation (see fig. 18.1).
Figure 18.1 SBACKUP host and target machines.
The following sections descibe the types of backups you can perform in NetWare 4.
In a full backup, all data is backed up. An example of this would be a backup of all directories and files in a volume or a backup of all volumes on a file server. After the data is backed up, the archive bit is cleared for all files that were backed up.
The archive bit is used to indicate whether the data should be backed up. When a file is modified, the archive bit is set, indicating that this file is a candidate for being backed up the next time, because it has been modified. Backup programs clear the archive bit to indicate that the file is now backed up.
The full backup strategy is the most comprehensive of all backup strategies because it backs all files regardless of whether they have been modified since the last backup. Because of the large volume of data that might need to get backed up, however, it is the slowest of the backup strategies.
Incremental backup is used to back up all files that have been modified since the last backup (full or incremental). Files that have not been modified are not backed up. To obtain a complete record of the most updated versions of the files, you would have to start with the most recent full backup and add all the incremental changes recorded in each incremental backup session. That is, where each i is an incremental backup, the formula is such:
Most Recent Backup = Last Full Backup + [partialdiff]1 + [partialdiff]2 + .... [partialdiff]n = Last Full Backup + [partialdiff]i (i = 1 to n)
The incremental backup contains a sequential history of the files that have been modified. This means that to restore data, you need the last full backup and every incremental backup after it. If the data on one of the backup tapes is corrupt, you might not be able to restore data. The exception to this is situations in which later incremental backups have the files that were inaccessible on the corrupt tape. In this case, you could restore the data from a later tape.
Because only the modified files are backed up, the incremental backup strategy tends to be very fast. If the number of files that are modified between incremental backups increases, the time required for doing an incremental backup also increases.
After performing an incremental backup, the archive bits of the files that have been backed up are cleared.
Differential backup is used to back up all files that have been modified since the last full backup. The archive bit is not cleared at the end of the backup, as is done in the case of full and incremental backups. This means that all files that were backed up in the first differential backup are also backed up in the second differential backup, together with any files that have been modified since the first differential backup. This process continues with each differential backup, and more files can be expected to be backed up with each differential backup.
To obtain a complete record of the most updated versions of the files, you would have to start with the most recent full backup and add to it the files in the most recent differential backup session. That is, where d is the most recent differential backup, the formula is this:
Most Recent Backup = Last Full Backup + [partialdiff]d
Because the differential backup contains all files that have been modified since the last full backup, you can restore data with just two tape backup sets: the backup set for the full backup and the backup set for the last differential backup.
If the data on one of the last differential backups is corrupt, you will have to fall back on the next to the last differential backup. On the other hand, if any data in another differential backup tape is corrupt, it does not matter as long as the data in the most recent differential backup is good.
Because all modified files are backed up, the differential backup is the same as the incremental backup for the first backup after the full backup. After that, the size of the data that needs to be backed up tends to grow with each differential backup. If all files have been modified, the differential backup session is the same as the full backup sessions. This tends not to be the case because most network volumes contain a mix of program and data, and program files are not usually modified.
It is best to use either a differential backup or incremental backup strategy. Mixing these two, though theoretically possible, can lead to potential confusion and should therefore be avoided.
Custom backup gives you complete control over what files to back up or not to back up. You can include or exclude parts of the directory structure to be backed up or select different types of data items to be backed up. Custom backup options are presented in detail in a later section in this chapter.
Custom backups are useful if you want to selectively back up a few files and directories and not wait for a scheduled backup.
NetWare 4.x implements backup services using Storage Management Service. SMS allows data to be backed up and restored independent of the backup hardware and file system. The Storage Management Service supports a variety of backup hardware devices and can back up file systems for DOS, OS/2, Macintosh, and Unix. This capability to back up different file systems is particularly important because NetWare-based networks support a heterogeneous workstation operating system environment. SMS provides support for the following workstations and data representations:
Table 18.1 contains a list of TSAs that are installed with NetWare 4.x. These TSAs can be found in the SYS:SYSTEM directory.
TABLE 18.1 Target Service Agents
|TSA312.NLM||NetWare 3.11 file system TSA.|
|TSA312.NLM||NetWare 3.12 file system TSA.|
|TSA410.NLM||NetWare 4.1 file system TSA.|
|TSA410.NLM||NetWare 4.0, 4.01, 4.02 file system TSA.|
|TSA220.NLM||NetWare 2.2 file system TSA.|
|TSADOS.NLM||TSA for backing up DOS files_runs at server.|
|TSASMS.COM||TSA runs at DOS workstation to be backed up/restored. Normally kept in the C:\NWCLIENT directory of the workstation.|
|TSANDS.NLM||NetWare 4.1 TSA for backing up NDS.|
|TSA_OS2.NLM||TSA for backing up OS/2 file system.|
Besides SBACKUP.NLM and TSAs, SMS consists of a number of other support NLMs that work together to provide backup and restore operations. Figure 18.2 shows the components of SMS.
Figure 18.2 SMS components.
SMS consists of a number of other modules such as the Storage Management Data Requester (SMDR), which is used to pass commands between SBACKUP and the TSAs, and device drivers that use the Storage Device Interface (SDI) to communicate between the SBACKUP program and the storage devices (see fig. 18.2).
The SBACKUP uses the SMDR to access the TSA. If the TSA is on the same server as the SBACKUP NLM, then the data source is on the same server. An example of this would be using the TSA410.NLM on the host server to back up the host file system. Another example would be to use the TSANDS.NLM on the host to back up the NDS database on the host server.
If the TSA is on a remote machine, such as a NetWare 3.x server running TSA312.NLM, the file system on the remote machine can be backed up. It is the responsibility of the TSA to obtain the requested data and pass it on to SBACKUP via the SMDR. The TSA is the agent that is closest to the source data that is being backed up and restored.
SBACKUP is able to back up or restore the data by communicating with the backup device via the Storage Device Interface NLM (SDI.NLM) and the backup device drivers. The Storage Device Interface is used to detect the presence of the device and media and present a list of devices that are available to the SBACKUP program. The backup operator can then select the appropriate backup device via the SBACKUP interface. The SMDR.NLM provides a highlevel interface to the backup device drivers. The backup device drivers have knowledge of the backup device hardware and use commands for reading, writing, rewinding, and ejecting the storage media. SDI.NLM, SMDR.NLM, STREAMS.NLM, CLIB.NLM, SPXS.NLM, and NWSNUT.NLM are autoloaded when SBACKUP loads.
To back up and restore workstations, a component called the Workstation Manager (WSMAN.NLM) must be loaded on the host server. WSMAN NLM is autoloaded when TSADOS or TSA_OS2 load. The Workstation Manager keeps an internal list of DOS TSRs (or OS/2 and Unix daemons) that have contacted it and are available for backup/restore operation.
The SBACKUP.NLM is loaded at the server. It is similar to the SBACKUP.NLM for NetWare 3.x servers but has been customized for the NetWare 4.x operating system.
To use SBACKUP, you must first load all the necessary drivers and TSAs for the target being backed up. NetWare 4.x ships with the tape drivers listed in table 18.2. The TAPEDAI.DSK tape driver can work with any tape device on a SCSI controller.
NOTE: If the TAPEDAI.DSK driver is not installed in the SYS:SYSTEM directory on the server, you can find a copy of it in the \NW410\DISKDRV directory on the NetWare 4.x CD-ROM distribution.
TIP: Contact the tape vendor to find out if they have specialized tape device drivers that work with NetWare 4.x SBACKUP. Specialized tape device drivers are optimized for speed and can be expected to work more efficiently than generic device drivers. The list of drivers that are bundled with NetWare 4.x can be expected to change with time. Contact your Novell reseller or Novell at 1-800-NETWARE or 801-429-7000 for a list of the latest drivers that are supported.
TABLE 18.2 Backup Device Drivers
|TAPEDAI.DSK||This is a generic ASPI-compatible tape driver for SCSI controllers. It is designed to use the Advanced SCSI Programming Interface (ASPI).|
|MNS16S.NLM and||These are device drivers for Mountain Network Solutions, Inc.|
|MNSDAT.DSK||SCSI controllers and tape devices.|
|PS2SCSI.DSK||These work with PS/2 SCSI controllers and IBM 2.2 GB 8mm tape devices.|
|AHA1540.DSK, AHA1640.DSK, AHA1740.DSK, ASPITRAN.DSK||These work with devices that use the Adaptec 1540, 1640, and 1740 controllers.|
The following steps guide you through the basics of performing a backup using SBACKUP.
NOTE: The actual screens that are presented using SBACKUP often depend on the selections you make from the SBACKUP menu for your network environment. For instance, you can select the Backup option without logging in to the target service first. In this case, you will be presented with a screen to log in to the target service first before performing the backup operation. Another example is the writing of labels on tapes. If you are using a new tape or completely rewriting the tape and you have not written a new label on the tape, you will be presented with a screen to label the tape.
Figure 18.3 LOAD TAPEDAI messages.
Figure 18.4 shows the server console screen when the TSA for the NetWare 4.x file system loads. The version number of the TSA and its date of creation are displayed.
Figure 18.5 shows the server console screen when the TSA for the NDS database loads. The version number of the TSA and its date of creation are displayed.
Figure 18.4 LOAD TSA400 messages.
Figure 18.5 LOAD TSA_NDS messages.
Figure 18.6 shows the output of the LIST DEVICES command. Only one device, device # 0, is listed. This is the Micropolis 1528 hard disk with 1.2 gigabyte capacity.
SCAN FOR NEW DEVICES
Figure 18.6 LIST DEVICES command before scanning for new devices.
Figure 18.7 shows the SCAN FOR NEW DEVICES command. No output is generated, but the command takes a few seconds.
Figure 18.7 The SCAN FOR NEW DEVICES command screen.
TIP: When the SCAN FOR NEW DEVICES command is executed, you will see the light indicators on the backup device light up when the device is accessed. If this does not happen, check for a loose cable or incorrect hardware configuration for the tape device.
Figure 18.8 shows the output of the LIST DEVICES command, after the SCAN FOR NEW DEVICES command recognizes the backup device. An additional device, device # 1, is listed. This is the HP 35470A tape drive unit for DAT tapes.
Figure 18.8 LIST DEVICES command after scanning for new devices.
NOTE: SBACKUP has a SIZE and BUFFERS option, as shown here:LOAD SBACKUP SIZE=sizeInKB BUFFERS=numberOfBuffers
The SIZE parameter is the buffer size used by SBACKUP in kilobytes. The value can be 16, 32, 64, 128, or 256 KB. The default value is 64 KB.
The BUFFERS parameter is the number of buffers reserved by SBACKUP. The value can range from 2 to 10. The default value is 4.
You might want to experiment with higher values to improve backup performance. If you do, take into account the additional memory required by SBACKUP. This could adversely affect server performance. For example, selecting a buffer size of 256 KB and 10 buffers will require an additional 2.56 MB of server RAM. Because NetWare 4.x does not use virtual memory, this is a genuine RAM requirement.
After SBACKUP is loaded, you can use it to perform backups and restores.
Unload SBACKUP and the support NLMs in the reverse order of their load sequence; that is, you must unload SBACKUP first, then the TSA NLMs, and finally the backup device drivers. An example of this unload sequence is shown here: UNLOAD SBACKUP
UNLOAD TSA410 UNLOAD TSANDS
The following steps show the sequence for performing a backup operation. The steps assume that all the necessary drivers have already been loaded.
Figure 18.9 The SBACKUP Main Menu.
Figure 18.10 List of devices.
Figure 18.11 Device Status.
Figure 18.12 Media List.
Figure 18.13 Status of media in backup device.
Figure 18.14 Selected media.
Figure 18.15 Target Services.
Figure 18.16 Username for Target Service.
Figure 18.17 Password for Username/Target Service.
TIP: If you are having a problem logging in as a user name, use the complete name. For example, if you are logging in as user Admin in container O=ESL, use the name:.CN=Admin.O=ESL
Some of the NLMs expect complete names with attribute-type specifications.
Figure 18.18 Device media to be used for backup.
Figure 18.19 Location of log/error files.
Figure 18.20 Type of Backup.
Figure 18.21 Backup Options.
Figure 18.22 Proceed with Backup options.
Figure 18.23 Schedule a Backup.
Figure 18.24 Status screen on media label.
The following steps show the sequence for performing a restore operation. The steps assume that all the necessary drivers have already been loaded.
Figure 18.25 Media List for restore.
Figure 18.26 Selected media.
Figure 18.27 Restore Target Services.
Figure 18.28 Username for target service for Restoring.
Figure 18.29 Password for Username/target service.
Figure 18.30 Session restore options.
Figure 18.31 Location of log/error files for restoring.
Figure 18.32 List of sessions to restore from.
TIP: It is important to use descriptive names for the sessions so that you can identify them at a later time.
Figure 18.33 Status message for selecting device and media.
Figure 18.34 Media and device to be used for restoring.
Figure 18.35 Restore options for NDS.
Figure 18.36 Verify Restore option.
Figure 18.37 Restore completion.
Occasionally, you might have a corrupt session log or the session log may have been accidentally deleted. In this case you must perform the restore without a session log. The following steps show you the sequence of steps to be performed. These steps complement the steps outlined in the previous section.
Figure 18.38 Message on selecting device and media to restore from.
Figure 18.39 Media identified by Restore.
Figure 18.40 Session description read from media and restore choices.
The example of the restore operation was given in the context of restoring an NDS database. The restore options that were presented are quite different for restoring a file system. This section discusses the restore options that are peculiar to restoring a file system.
When you select the Restore a Session option from the Restore Menu for restoring a file system, you are asked to select the device/media and the name of the session to restore from. If you select Custom Restore, you will see the restore options shown in figure 18.41.
Figure 18.41 Restore Options for a file system.
Selecting the "Subsets of what you are restoring" option from the Restore Options form will show you the data items (also called data structure) that are available for restoring (see fig. 18.42). This option classifies data items as Major TSA or Minor TSA resources. A Major TSA resource contains data that can be backed up as a whole when selected. Examples of Major TSAs are the File Server and the Volume. When you select a Major TSA resource such as a Volume, all directories and files within it are considered for restore operation. A Minor TSA resource is contained within a directory structure of a Major TSA resource. An example of this would be the directories and files within a volume.
Figure 18.42 Selecting restore subsets.
In figure 18.42, if you want to include an entire volume for a restore operation, you would select "Include major TSA resources" (see fig. 18.43) and press Ins to see a list of major TSA resources that are available for selection (see fig. 18.44).
Figure 18.43 Include major TSA resources.
Figure 18.44 Selections for Major TSA resources.
You can use the other options for excluding or including directories or files. If you want to include a specific directory for back up, you can select Include directories (full path) and press Ins to add a directory name. Figure 18.45 shows the directory SYS:SYSTEM is selected for the restore operation.
Selecting the "How to Scan What You are Restoring" option from the Restore Options form shows you the options for excluding different aspects of the file system (see fig. 18.46).
Figure 18.45 Using the "Include directories" option.
Figure 18.46 The How to Scan What You Are Restoring options.
The group of data files and directories that you are restoring is called a data set. You can select the data sets that you want to exclude from the restore operation. If you want to restore a type of data from this list, select a value of No; otherwise select a value of Yes. By default all of the Exclude options have a value of No. This means that all aspects of the data set should be scanned for the restore operation. The data stream refers to the data that is being restored. This option works with the other options "Subsets of what you are restoring" and the "Overwrite" option. It narrows the types of data sets that should be scanned for in the restore operation. For example, you can use this to exclude or include any of the following:
If you want to restore data to a different location from where it was backed up, set the "Restore data to different location" field to Yes. The default value for this field is No, which means that data will be restored on top of existing data.
The example of the backup operation was given in the context of backing up an NDS database. The backup options that were presented are quite different when the Custom Backup Method is selected for file systems.
When you select the "Custom: Only Specified Data" option from the Type of Backup Menu, you will then see the custom backup options shown in figure 18.47.
Selecting "What do you want to backup?" shows the Major TSA resource that is to be backed up (see fig. 18.48). Pressing Ins gives you a choice of other Major TSAs that can be backed up.
Figure 18.47 Custom Backup Options for a file system.
Figure 18.48 The "What do you want to back up?" option.
A Major TSA resource contains data that can be backed as a whole when selected. Examples of Major TSAs are the File Server and the Volume. When you select a Major TSA resource such as a Volume, all directories and files within it are considered for restore operations. A Minor TSA resource is contained within a directory structure of a Major TSA resource. An example of this would be the directories and files within a volume.
Selecting the "Choose subsets of what you are backing up" option from the Custom Backup Options form will show you the data items (also called data structure) that are available for backing up (see fig. 18.49). This option classifies data items as Major or Minor TSA resources.
Figure 18.49 Selections for the "What do you want to back up?" option.
In figure 18.50, if you want to include an entire volume for a restore operation, you would select "Include major TSA resource" (see fig. 18.51) and press Ins to see a list of major TSA resources that are available for selection (see fig. 18.52).
Selecting the "How to scan what you are backing up" option from the Custom Backup Options form shows you options for excluding different aspects of the file system (see fig. 18.53). This option shows the type of data contained in the data sets for the type of target (NetWare 4.x file system, in this case) that is being backed up. A group of data files and directories that you are restoring is called a data set.
Figure 18.50 The "Choose subsets of what you are backing up" option.
Figure 18.51 Include Major TSA resources for Backup.
Figure 18.52 Selections for Major TSA resources for Backup.
Figure 18.53 The "How to Scan What You Are Backing Up" options.
You can select the data sets that you want to exclude from the backup operation. If you want to back up a type of data from this list, select a value of No; otherwise select a value of Yes. By default, all of the Exclude options have a value of No, meaning that all aspects of the data set should be scanned for during the backup operation. This option works with the "Subsets of what you are backing up" option. It narrows the types of data sets for which you should scan in the backup operation. You can, for example, use this to exclude from (Yes), or include (No), any of the following:
Using SBACKUP, you can specify if the files that you want to back up should be backed up in a compressed state or not. The default on NetWare 4.x volumes is that compression is enabled. This default is set at the time a volume is first created as part of the server installation.
In general, back up compressed files in their compressed state because the backup is faster. If you back up compressed files in the compressed state, you cannot restore the compressed files to a NetWare 3.x server that does not support NetWare 4.x compression.
It is not a good idea to run SBACKUP when file compression is occurring on the volume. This would degrade the performance of SBACKUP. Because both the default time for compressing newly created or modified files and scheduling a delayed backup is 12:00 a.m., schedule an SBACKUP several hours after volume compression begins.
The SBACKUP session files can be administered by selecting the Log/error File Administration option from the SBACKUP Main Menu. Figure 18.54 shows the options that are available when this option is selected. You can select a log file to view by selecting the "View a Log File" option (see fig. 18.55). Similarly, the error file can be viewed by selecting the "View an Error File" option. You can specify the location of log and error files by selecting the "Set Location of Log and Error Files" option (see fig. 18.56).
Figure 18.54 The Log/error File Administration menu.
Figure 18.55 View a log file.
Figure 18.56 Setting location of log and error files.
Before SMS can be used, the backup operator must be able to log in to NDS. In addition to this, to perform SBACKUP, you need Read and File Scan rights to the file system being backed up. These rights enable the operator to read the files and scan for names of files in directories being backed up.
If you are performing an Incremental or Full backup, the archive bit is cleared at the end of the backup pass. To perform this, the backup operator must have the Modify right.
To back up the NDS database, you must be able to view the NDS tree structure and read the property values of the NDS object. To perform these operations, the backup operator must have the Browse object trustee right to the NDS tree and the Read property right to All Properties. Because the Browse right is assigned to the implicit group [Public], no special considerations need to be made, unless this right is blocked by the IRF. The Read All Properties right must be assigned to the root of the NDS sub-tree that the backup operator has the authority for.
If the TSA at the workstation has a password set, the backup operator must have knowledge of this password.
SBACKUP can be used to backup and restore DOS workstations. You can backup specific drives and directories at the workstation. To perform a backup/restore of the DOS workstation you need the following:
TSASMS /P=shiv /D=c /SE=NW4KS
TABLE 18.3 TSASMS Options
|/H[elp]||Displays help screen. Using /? produces an ?error message, but the help screen is still displayed.|
|/B[uffers]=nbuf||Sets aside nbuf 1-KB buffers that will be used for backing up. The default is 1 buffer. Increasing this number will increase the backup speed at the expense of using more RAM at the workstation. Novell notes that the number of buffers does not seem to affect performance of restore functions. nbuf can be from 1 to 30.|
|/D[rives]=drives||Specifies a list of drive letters that can be backed up at the workstation. The list consists of a string of one-letter drive letters with no spaces or colons. For example, to backup drive C only, you would use /D=C, and to back up drives A, C, and E, you would use /D=ACE. The /DRIVES parameter is mandatory.|
|/N[ame]=wkstn_name||Sets the workstation's name. It must be specified to create the workstation name for the first time. This name is displayed in the SBACKUP menu. Once specified, the workstation name is created as a permanent entry in the emulated bindery of the host server that was specified in the /SE option. The network and node addresses are also stored in the emulated bindery entry. Any attempt to backup this workstation with another name will fail. To remove the name, network, and node address information, you can use the /REMOVE option. If you move the workstation to another cable segment or change its network adapter address, use the /REMOVE option and use the /NAME option again. You can use any name up to 10 characters for the workstation. Because the name is registered with the host server, use a consistent logical scheme.|
|/R[emove]=host_server,wkstn_name||Deletes the workstation name, wkstn_name, that you originally specified with the /NAME parameter from the host server. The /REMOVE option removes the workstation name entry in the emulated bindery of the host_server. Use this option to register a different workstation name, network address, or node address.|
|/SE[rver]=host_server||Specifies the name of the host server on which the SBACKUP program runs. The TSASMS, on loading, connects to the specified host_server. The /SERVER parameter is mandatory.|
|/P[assword]=passwd||Used for security reasons, so that only the backup operator who knows the registered workstation name and password can perform SBACKUP operations. You must use the /PASSWORD option or the /TRUST option, but not both. These options are mutually exclusive.|
|/T[rust]||Enables the backup operator, to backup/restore the workstation without knowing the workstation password. As the name of the option suggests, this option requires you to trust the backup operator with the confidentiality of the files. You must use the /TRUST option or the /PASSWORD option, but not both. These options are mutually exclusive.|
|/ST[ack]=size||Specifies the size of the stack. The default stack size is 2048 bytes.The stack size can range from 512 to 4096 bytes. Use this option if you get stack overflow error messages. When this error message occurs, you might want to increase the default value, by 128 byte increments, until the error message disappears.|
|/U[nload]||Unloads the TSASMS from memory.|
There are a number of caveats to keep in mind when performing SBACKUP. The following is a list of things to keep in mind:
TIP: Always have an extra supply of reusable tapes on hand, just in case you need to backup more data than usual.
This chapter discussed the native backup service for NetWare 4.x. The primary tool for NetWare 4.x backup, SBACKUP.NLM, uses the Storage Management Services (SMS).
You can use SBACKUP for full backups, differential backups, incremental backups, or custom backups. This chapter dicussed the advantages and disadvantages of each of these backup strategies.
© Copyright, Macmillan Computer Publishing. All rights reserved.