When you dump a database or transaction log, Backup Server creates a default file name for the dump by concatenating the:
Last 7 characters of the database name
2-digit year number
3-digit day of the year (1–366)
Number of seconds since midnight, in hexadecimal
You can override this default using the file = file_name option. The file name cannot exceed 17 characters and must conform to the file naming conventions for your operating system.
You can specify a file name for each dump device. You can also specify a file name for all devices in the with clause. File names specified for individual devices take precedence over those specified in the with clause.
Table 12-11 shows the syntax for specifying the name of a dump.
Backing up a database or log |
Loading a database or log |
|
---|---|---|
|
|
|
File name for single device |
|
|
|
|
|
File name for additional devices |
|
|
|
|
|
File name for all devices |
|
|
|
|
The following examples dump the transaction log for the publications database without specifying a file name. The default file name, cations930590E100, identifies the database, the date, and time the dump was made:
Figure 12-1: File-naming convention for database and transaction log dumps
Backup Server sends the file name to the default message destination or to the notify location for the dump command. Label each backup tape with the volume name and file name before storing it.
When you load a database or transaction log, use the file = file_name clause to specify which dump to load from a volume that contains multiple dumps.
When loading the dump from a multifile volume, you must specify the correct file name.
dump tran publications to "/dev/nrmt3" load tran publications from "/dev/nrmt4" with file = "cations930590E100"
The following examples use a user-defined file-naming convention. The 15-character file name, mydb97jul141800, identifies the database (mydb), the date (July 14, 1997), and the time (18:00, or 6:00 p.m.) that the dump was made. Using the load command advances the tape to mydb97jul141800 before loading:
dump database mydb to "/dev/nrmt3" with file = "mydb97jul141800" load database mydb from "/dev/nrmt4" with file = "mydb97jul141800"