Using Media Sets and Families
A media set can contain one or more backup sets and describes all of the media used by those backup sets, regardless of the number of media or backup devices involved. For example, if four tape backup devices are used when creating a database backup, and five tapes per tape backup device are used to store the backup, the media set contains 20 tapes.
A media family describes all the media used by a single backup device for a single backup set. In the example earlier, there are four media families with each set of five tapes used by each tape backup device comprising one media family.
The initial media is the first media in a media family. If the initial media becomes full during the backup operation, more media is used until the backup operation is complete. All media in a media family except the initial media is described as continuation media.
Note Only tape backup devices use continuation media, allowing Microsoft® SQL Server™ to continue writing the backup after the initial tape is full.
To distinguish between each physical medium used within a media family, each medium is tagged with a sequence number to specify the order in which the media were used. The initial media is tagged with 1, the second media (the first continuation media) is tagged with 2, and so on. These sequence numbers are used when the backup set is restored to ensure that the operator restoring the backup mounts the correct media in the correct order. Additionally, media families within a media set are numbered sequentially.
When appending a backup set to a media set containing multiple media families, you must mount the last media in the family. If the last media is not mounted, SQL Server scans forward to the end of the media, requiring media to be changed until the last media in the family is mounted correctly.
Each SQL Server backup is stored on a media set, regardless of the number of backup devices used by the individual backup operation. Examples of media sets include:
- A single disk file.
- A single tape.
- A set of tapes written by one backup device. This set of tapes consists of a single media family (an initial media and one or more continuation media).
- A set of tapes written by four backup devices. Each set of tapes written by one backup device is the media family. Each media family contains an initial media and possibly one or more continuation media.
- A set of three disk files, used by one or more backup operations, with each backup operation using three backup devices.
When using multiple backup devices:
- The entire media set created by a backup operation must be used by all subsequent backup operations. For example, if a media set was created using two tape backup devices, all subsequent backup operations involving the same media set must use two backup devices.
- When restoring using tape devices, it is not necessary to use the same number of backup devices used by the media set when the backup was created. For example, restoring using fewer backup devices may be necessary when moving a database to another server, because the server may have fewer physical backup devices. You can restore media families in parallel. However, you must complete restoring an entire media family before starting another on a given tape device.