You create a new backup medium or change the data for a backup medium that already exists.
The properties of the backup medium defined in this way are stored in the log file dbm.mdf of the Database Manager. The backup medium is not created physically until it is first used for a backup.
You have the server authorization Backup.
medium_put <name> [<location> [<type> [<backup_type> [<size> [<block_size> [<overwrite> [<autoloader> [<os_command> [<tool_type>]]]]]]]]]
<name> |
The backup medium specified in <name> is created or updated. The name of the medium can comprise a group name and a member name. These are separated by a slash. <name> ::= [<group_name>/]<member_name> Groups of parallel backup media of this type are used when data is backed up or restored in parallel. To create a group of parallel backup media, execute the command for creating one backup medium as many times as you need. Create the group by assigning each different <member_name> to the same <group_name>. |
<location> |
The name of the device/file with which it can be addressed through operating system functions. Versioning of log backups with the <type> FILE is carried out by the system (see also: Version File of the Log Backup). In Microsoft Windows: The <location> of a backup medium of type PIPE must adhere to the following convention: \\.\pipe\<pipe_name>. For a backup medium of type TAPE, the path must adhere to the following convention: \\.\tape<running_number>. If you specify a relative path for a backup medium of type FILE, the backup medium is stored in the run directory of the database instance. In UNIX, any path can be used for backup media of type FILE and PIPE. If you enter relative paths, the backup media are stored in the run directory of the database instance. You must specify absolute paths for backup media of type TAPE. You have to specify an absolute path name for the NSR backup tool. This must be identical for both the backup and restore operations. Also note that parts of the path name that represent only links are replaced with the actual directory or file name by NetWorker. If you do not define this value, the medium cannot be used. |
<type> |
Type of the backup medium. Possible values are: AUTO | TAPE | FILE | PIPE The media type AUTO is the default value for the command to activate the automatic log backup. There can be only one backup medium of this type. If a backup medium of type AUTO already exists and you create a backup medium of type AUTO again, the system changes the media type of the existing backup medium to FILE. Specify TAPE for backups to a non-rewindable tape, FILE for backups to a file, and PIPE for backups to a pipe. If you do not define this value, the medium cannot be used. |
<backup_type> |
Backup type for which the backup medium is to be used: Possible values are: DATA | PAGES | LOG Specify DATA for a full data backup, PAGES for an incremental data backup, and LOG for a log backup. If you do not define this value, the medium cannot be used. |
<size> |
Maximum number of pages that can be written to the backup medium. The default value of the system is 0, that is, the size of the medium is unlimited. |
<block_size> |
Number of pages transferred when the medium is accessed. This value is interpreted only for the media type TAPE. The system default for this media type is 8. |
<overwrite> |
Obligatory only for
the media type FILE and only for data backups. It defines the behavior
if the file already exists. YES | NO If you enter YES and the file already exists, it is overwritten by the new backup. If you enter NO and the file already exists, the backup fails. This entry is not interpreted for log backups. Log backups can only be written to files. A sequential number is added to the names of these files after every backup operation and the names are not overwritten. The system default is NO. |
<autoloader> |
Details of whether the device changes the medium automatically: Relevant only for
Microsoft Windows. YES | NO The system default is NO. |
<os_command> |
Operating system command to be executed before backing up to a succeeding medium or restoring from a succeeding medium. |
<tool_type> |
Backup tool to be used. Possible values are: NONE (No automatic backup tool is used) If you use UNIX and you enter the value NONE with PIPE as the <type>, the pipe must be created before the backup process starts. If you use Microsoft Windows, the pipe must not yet exist. If you enter a value other than NONE, you must enter 0 for <type> PIPE and for <size>. If you use either UNIX or Microsoft Windows, the pipe must not exist before the backup process begins. For NSR, note the additional information listed under <location>. The system default is NONE. |
OK
In the event of errors, see Reply Format.
Logging on to the Database Manager CLI as operator DBM with password DBM, connecting to the HOTELDB database instance,
· Defining the file logsave as a backup medium with the name LogBackup under the path C:/sdb/data/wrk/HOTELDB/logsave as a backup medium for an interactive log backup:
dbmcli -u DBM,DBM -d HOTELDB medium_put LogBackup C:/sdb/data/wrk/HOTELDB/logsave FILE LOG
The system numbers the files sequentially if they are used for a log backup. After a log backup has been completed, the files are written to the new backup medium. In other words, you will find only one file with the file name logsave.<running_number> on your hard disk.
·
Defining the
file autosave as a backup medium with the name AutoLogBackup under the path C:/sdb/data/wrk/HOTELDB/autosave for an automatic log backup:
dbmcli
-u DBM,DBM -d HOTELDB medium_put AutoLogBackup C:/sdb/data/wrk/HOTELDB/autolog FILE
AUTO
·
Defining the file
completeF as an overwriteable backup medium without size
restriction with the name DataFile under the path C:/sdb/data/wrk/HOTELDB/completeF for a full data backup:
dbmcli
-u DBM,DBM -d HOTELDB medium_put DataFile C:/sdb/data/wrk/HOTELDB/completeF FILE DATA 0 0
YES
·
Defining an
overwriteable backup medium of type TAPE with the name DataTape, a size of 64000 pages and a block size of 8 page
for a full data backup on a tape device:
dbmcli
-u DBM,DBM -d HOTELDB medium_put DataTape /dev/rft0 TAPE DATA 64000 16
YES
·
Defining the file
incr as a backup medium with the name IncBackup for an incremental data backup:
dbmcli
-u DBM,DBM -d HOTELDB medium_put IncBackup C:/sdb/data/wrk/HOTELDB/incr FILE
PAGES
·
Defining the pipe
example as an external backup medium with the name
123 for an incremental data backup using an external
backup tool running on Microsoft Windows:
dbmcli -u DBM,DBM -d HOTELDB
medium_put TSM123 \\.\pipe\example PIPE
PAGES