Oracle Rman Media management issues

Source: Internet
Author: User
Tags require valid oracle database

Rman usage in Oracle 10g is primarily concerned with the best way to restore disk backup as a media recovery solution. As disk prices have fallen, a large number of storage area networks (Storagearea Network:san) have found permanent storage space in many data centers. As the business progresses towards a more affordable and affordable disk, the functions of rman, such as flashback, are upgraded to make the most efficient use of available storage space.

The RMAN Backup utility is a logical process, and writing to disk is the work that Oracle databases excel at. Therefore, when the Oracle database begins to improve disk write capabilities, the RDBMS does the work to improve performance.

In many cases, however, the size of the database and its location make it impossible to back up to disk. Or you still have business requirements for a copy of your resume or for your outbound archive. It is therefore still necessary to write to an older tape device.

Tape backups of Oracle databases require third-party assistive devices, mainly because of the very different nature of the continuous media subsystems that are prevalent on the market. RMAN developers typically use a read-write tape product provided by a large vendor without attempting different system calls to these different types of tape devices.

Oracle has its own media management software solution, known as Oracle Security Backup (Oracle secure BACKUP:OSB). OSB is fully integrated, RMAN to disk solution, it does not require any third-party vendor software Plug-ins, but OSB immature.

A Why tape backups are used

The first reason is because of the size of the database. The average database size has now reached 100GB, and the data continues to increase. The size of the database determines whether a tape backup operation needs to be performed. Even though disk prices are falling rapidly, it is expensive to buy a lot of disks. The advantage of Backup-to-disk is rapid recovery, while disk backup and restore is relatively slow.

The second reason is ease of management. Typically, the implementation and execution of an enterprise-wide backup strategy is centrally managed by people on the central system, saving the size and expense of backups, and the company's ability to buy large-capacity tape-cartridges to store more data.

A third reason: portability. In order to archive and avoid disaster, it is easy to move a pile of tapes away from the station, while the hard drive is not so easy to transfer.

The disadvantage of centralizing backup resources is that it can lead to complex backup, especially Oracle database complications. The complexity of Oracle data files, log files, and control files means that we cannot simply execute an OS job. Let it copy the file in idle time. Instead, we must make the database perform the backup operation, then notify the start of replication, and finally reconfigure the database.

Using Rman avoids the configuration of this database, and backup operations can occur at any time, however, to write backups to a centralized tape backup location, you must perform some special Rman configuration.

Two RMAN and Media Manager overview

By using the media manager, Rman backs up data to tape. Media manager:mm is provided by a Third-party software provider that passes data streams from the data block to the appropriate tape from the Rman channel process. Typically, a media server is located in a corporate network. The media Management Server, media Management Server, is a centralized system where you can handle enterprise-wide tape backup operations.

The computer system must have Media management (MM) client software installed to use the Media manager. The media management client software can connect to the MM server and transmit data over the network.

If Rman wants to use the MM server, additional software components are required. After installing the client software, we must also install the Oracle module for the media manager. Oracle Module (oraclemodule) is a software plug-in for Oracle Rdmbs, which connects Rman with client management software, which can transfer data to a mm server. This plug-in for Oracle is also known as the Media Management library, media management LIBRARY:MML.

2.1 Media Manager Directory

Media Manager is an independent subsystem in the entire backup system that we use. It has three components: a Media Management library (MML) with Oracle, media Management client, and media Management Server. The MM server has several components, the specifications of which are provided by the vendor, and all MM servers must have some of the same components.

The Media Manager directory is the information database on the MM server that holds information about the physical tape itself, the access rights of the tape, and the contents of the tape storage. When the backup completes, the Media Manager directory records the Rman file handle, and the handle (Handle) is the name of the backup slice that was created when the backup operation was performed using Rman. If you perform a disk backup operation, the handle is the physical file name.

If you perform a tape backup, the handle used in the Media Manager directory is the tape location where the backup resides.

When RMAN completes a tape backup operation, it provides a handle name to the manager, which the media manager records in the directory. When a restore operation is required, Rman requests the specified handle from the media manager based on its own directory. The media manager then looks up the handle, associates the handle with the specified tape, and determines whether the tape is valid. If the tape is valid, the media Manager uses the tape and starts sending the data back to Rman so that the data file can be rebuilt.

2.2 Other software components of the media Manager

In addition to the Media Manager directory, the MM Manager contains two basic components:

(1) Device agent (Device agent): Device agent is the component responsible for using the actual tape device and transferring data on the device

(2) Automatic machine interface (robotic Interface): Automatic machine interface controls all automatic machine software, which is responsible for replacing tapes when tape is full or when a request is written to a filled tape.

Rman in Oracle is not aware of the presence of these components. RMAN simply sends the command request to MML, and the MM software handles all of the corresponding events. However, since the success of backup and recovery depends on these components, it is also critical to familiarize yourself with these software components. Most of the problems with Rman are related to device agents or automated machine interfaces, but these problems are almost imperceptible from the Rman interface.

2.3 Media Management Library (MML)

MML is a library file that interprets the consistency of Rman's backup or restore requests as being based on a specific system call on the Management Server to achieve the required operation. MML is provided by the same vendor as MM client software and mm server software, but we need to purchase MML and obtain permission separately.

When a tape channel is first allocated, MML is loaded into the Oracle memory space as an integrated library file, which is a logical part of Oracle RDBMS software, so rman can generate the correct mm client software calls. This integration is actually very simple: when allocating a tape channel, Oracle loads a file named libobk.so. This file is located in the Oracle_hom/bin directory and is just a symbolic connection to the MML file you want to use. On the Windows platform, Oracle looks for a library file named Orasbt.dll in the search path. Regardless of the media manager, the media manager is typically written to the Windows/system32 directory in the media management DDL file named: Orasbt.dll. If this file is not located in the directory, there is a search path in the system PATH environment variable that can find the Orasbt.dll file.

Example: Testing a tape channel using the Oracle default SBT interface

Rman> Run

2> {

3> Allocate channel C1 type ' Sbt_tape '

4> parms= "SBT_LIBRARY=ORACLE.DISKSBT,

5> env= (backup_dir=f:/backup/) ";

6> BACKUP DATABASE format= '%u ';}

Channel Freed: Ora_disk_1

Allocated Channel: C1

Channel c1:sid=21 Device Type =sbt_tape

Channel C1:WARNING:Oracle Test Disk API

Start Backup in 1 August-June-10

Channel C1: Starting all data file backup sets

Channel C1: Specifying Data files in Backup set

Enter data file: File Number = 00001 is called =D:/APP/ADMINISTRATOR/ORADATA/ORCL/SYSTEM01. Dbf

Enter data file: File Number = 00002 is called =d:/app/administrator/oradata/orcl/sysaux01. Dbf

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.