RMAN
Using the Media Management Layer
To store the backup of your database on
external tape drives, you need to install the media manager software
of the third-part vendor and use Media Management Layer (MML)APIs that are available in RMAN. While backing up the
database, RMAN client connects to the media manager using specific
allocated channels via the target database instance. To install the
third part media manager, you need to refer to the vendor's software
documentation for instructions.
To establish the connection, allocate a
channel for RMAN by specifying the sbt_library parameter with the
path to the library of the media manager. The general syntax is:
RMAN>configure
channel device type sbt parms sbt_library=pathname';
To test the media manager connection, allocate
a channel and examine an RMAN output. In order to test the backup
and restore, perform backup of spfile and its restoration.
The sbttest Utility
Using this diagnostic tool, RMAN checks
whether it can connect to the third part tape drive incorporating
your current media manager configuration settings. This tool checks
whether the MML is installed correctly and you can read and write to
tape through SBT API. Just call the executable by passing a filename
as a parameter and check the result. If you get the following lines
as a result, then the test was successful:
-bash-3.2$
sbttest test_file
The sbt function pointers are loaded from libobk.so library.
-- sbtinit succeeded
-- sbtinit (2nd time) succeeded
To get the list of all parameters that the
sbttesttool supports, run it
without any parameters:
Error:
backup file name must be specified
Usage: sbttest backup_file_name # this is the only required
parameter
<-dbname database_name>
<-trace trace_file_name>
<-remove_before>
<-no_remove_after>
<-read_only>
<-no_regular_backup_restore>
<-no_proxy_backup>
<-no_proxy_restore>
<-file_type n>
<-copy_number n>
<-media_pool n>
<-os_res_size n>
<-pl_res_size n>
<-block_size block_size>
<-block_count block_count>
<-proxy_file os_file_name bk_file_name
[os_res_size pl_res_size block_size block_count]>
<-libname sbt_library_name>
Simulating SBT Channel
If you do not have any tape drives but you
want to stimulate a tape backup, you can use an API named disksbt
while allocating a channel. The channel will be allocated as a tape
channel allocation. Look at the following example:
RMAN> run {
allocate channel ch1 device type 'sbt_tape'
parms="sbt_library=oracle.disksbt, env=(backup_dir=/tmp/backup)";
backup datafile 1 format='%u';
}
using target database control file instead of recovery catalog
allocated channel: ch1
channel ch1: SID=31 device type=sbt_tape
channel ch1: WARNING: Oracle Test Disk API
As this shows, RMAN reacts as it is connecting
to the tape drive and the warning Oracle Test Disk API? appears in
the output.
To make it a default channel, change the RMAN
configuration as follows:
RMAN> configure
channel device type 'sbt_tape'
parms="sbt_library=oracle.disksbt,
env=(backup_dir=/tmp/backup)";
Now make the default device type as tape:
configure default
device type to sbt_tape;
After making the above configuration, take
backup of any file and you see that RMAN uses a tape backup instead
of disk backup.
|
|
|
Burleson is the American Team
Note:
This Oracle
documentation was created as a support and Oracle training reference for use by our
DBA performance tuning consulting professionals.
Feel free to ask questions on our
Oracle forum.
Verify
experience!
Anyone
considering using the services of an Oracle support expert should
independently investigate their credentials and experience, and not rely on
advertisements and self-proclaimed expertise. All legitimate Oracle experts
publish
their Oracle
qualifications.
Errata?
Oracle technology is changing and we
strive to update our BC Oracle support information. If you find an error
or have a suggestion for improving our content, we would appreciate your
feedback. Just
e-mail:
and include the URL for the page.
Copyright © 1996 - 2020
All rights reserved by
Burleson
Oracle ®
is the registered trademark of Oracle Corporation.
|
|