In this post I would show you how to integrate RMAN with a media manager, in my case EMC Legato Networker 7.4
Launch EMC Legato Networker 7.4 from your browser or double click on the link to the java web interface.
Enter your administrative credentials into the Networker Management Console Login window.
The Networker Management Console will show the host used as Networker Server. Double clicking on the NAME Networker...
... it will show you the Networker Administration window
Expand the Groups and select the group created for the Data Warehouse, in my case it's called Gr_ORACLE_DWH
If you double click on the client associated with Gr_ORACLE_DWH on the right panel, the properties panel will be showed. On the General panel, Identity-->Name is the name of my vip server, IndexManagement shows the Browse and Retention policy for this backup, Backup-->Save Set shows you the path of the RMAN command that Networker will execute on the client, Backup-->Group identifies Gr_ORACLE_DWH as group, Backup-->Schedule show that this backup is scheduled as ORACLE_DWH_FULL.
On the Apps & Modules panel, Backup-->Backup command will show the command executed by Networker Server on the client, including some environment variables or pre and post backup command. This command nsrnmo_dwhdb2 is placed on the client under /usr/sbin/
If you instead right click on Gr_ORACLE_DWH group and select Properties the following screen is showed. In my case this backup starts at 19:00 but at present is disabled.
Selecting Schedules from the Networker Administration window on the left panel you can double click on ORACLE_DWH_FULL to view when and what type of backup is scheduled.
Select Media button on the top of Networker Administration window and then Media Pools.
The Media Pools for this backup is called ORAdatawarehouse. Backup data is sorted into backup media volumes by using media pools. A media pool is a specific collection of volumes to which the NetWorker server writes data. The server uses media pools to sort and store data. Media pools act as filters that tell the server which backup volumes should receive specific data.
When a scheduled backup occurs, the NetWorker server tries to match the save
stream to a media pool configuration. If the save stream matches the criteria of a
media pool configuration, it is directed to a labeled volume in the media pool. The
server then checks if a correctly labeled volume for that media pool is mounted on a
◆ If a correctly labeled volume is mounted on a storage device, the NetWorker
server writes data to the volume.
◆ If there is no correctly labeled volume mounted on a storage device, the
NetWorker server requests that such a volume be mounted and waits until an
operator or an autochanger mounts an appropriate volume.
If you double click on ORAdatawarehouse a Basic Properties window is showed with some informations.
From the panel Selection Criteria, Target Device-->Devices shows that this kind of Media Pools use a TAPE Library (in my case they are /dev/nst0 and /dev/nst1)
General informations about the tapes available on the TAPE Library (ADIC Scalar i500) are showed selecting Devices button on the top of Networker Administration window and then Libraries-->ADIC.
Let's see the file what there is inside the file /usr/sbin/nsrnmo_dwhdb2 on the client.
You can find the required variables ORACLE_HOME and PATH, the optional variables ORACLE_SID...
...NLS_LANG, NSR_RMAN_ARGUMENTS, NSR_RMAN_OUTPUT, NSR_SB_DEBUG_FILE...
...PRECMD, POSTCMD and TNS_ADMIN.
Set PRECMD to the complete pathname of a file containing a preprocessing script to be executed before the RMAN backup script. If the pre-command script fails (returns a nonzero value), the scheduled Oracle backup does not proceed (that is, the RMAN script is not executed).
Set POSTCMD to the complete pathname of a file that contains a postprocessing script to be executed after the RMAN backup script. If the RMAN backup script fails, the failure is reported, and the postprocessing script is executed nevertheless. If the postprocessing script fails, an error message is reported.
These script files must have permissions that allow execution by the root user, as the scheduled Oracle backup is always launched by root. The scripts should return a zero value when they succeed and a nonzero value when they fail. The return of a nonzero value will cause the scheduled backup to fail.
My PRECMD file is located on /u01/app/oracle/srvctl_scripts/dwhdb/stop_database_DWHDB.sh and you can view what commands are executed. I need to shutdown my RAC database and then start it up in mount mode to execute a cold backup.
My POSTCMD file is located on /u01/app/oracle/srvctl_scripts/dwhdb/start_database_DWHDB.sh and you can view what commands are executed. I need to shutdown my RAC database (RMAN open it after is execution) and then start it up in open mode.
The RMAN commands for my Data warehouse cold backup is showed here.
Selecting Monitoring button on the top of Networker Administration window and then right click on Gr_ORACLE_DHW, you can start manually the group.
A popup window will ask you to proceed.
Double clicking on the group just started, you can view the Networker Server is trying to contact the client...
... and how the backup proceed.
You can select the tab Monitoring-->Devices to view how much Bytes are written on tape.
The backup is successfully completed.