Home » RDBMS Server » Backup & Recovery » Oracle RMAN Backup API
Oracle RMAN Backup API [message #382681] Fri, 23 January 2009 10:09 Go to next message
alwar
Messages: 2
Registered: January 2009
Location: chennai
Junior Member
Hi,

can any one tell me RMAN Backup API that we can integrate into our application program?.

Thanks in advance..
Alwar
Re: Oracle RMAN Backup API [message #382684 is a reply to message #382681] Fri, 23 January 2009 10:15 Go to previous messageGo to next message
ebrian
Messages: 2794
Registered: April 2006
Senior Member
Sure...it's called rman.
Re: Oracle RMAN Backup API [message #382687 is a reply to message #382684] Fri, 23 January 2009 10:23 Go to previous messageGo to next message
alwar
Messages: 2
Registered: January 2009
Location: chennai
Junior Member
Hi Ebrian,

Thanks. I am aware of RMAN. But i just want to know is there any API that we can integrate RMAN with our application program? Like the following..
MSSQL backup -> VDI API
Exchange Mailbox backup -> MAPI

Do you understand what i expect?

Many thanks,
Alwar.

Re: Oracle RMAN Backup API [message #382695 is a reply to message #382687] Fri, 23 January 2009 10:38 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
No, there is none.

Regards
Michel
icon5.gif  Re: Oracle RMAN Backup API [message #687630 is a reply to message #382695] Fri, 21 April 2023 01:57 Go to previous messageGo to next message
Pratiksha_Ratnaparkhi
Messages: 2
Registered: April 2023
Junior Member
Hi Michel Cadot,
Let me know if I get it right.

If I want to integrate rman backup and recovery to my existing application, then I won't be able to do that using APIs, I need to manually launch RMAN console and execute backup and restore commands.
If this is right then,

Do you have any remote console way to that?
In the customer facing organisation, we can not ask them to launch the console and fire commands, is there any way we can do it through code?
Re: Oracle RMAN Backup API [message #687631 is a reply to message #687630] Fri, 21 April 2023 03:35 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

If you can launch a shell script or command then you can do it easily using something like:
rman target / nocatalog log=$LOGFILE append cmdfile=$CMDFILE
where $CMDFILE is a file containing your RMAN commands.

There is an API (DBMS_BACKUP_RESTORE) but it is not documented.
A description can be found in Morgan's Library
You can find examples of using it on the web, for instance:
http://www.orafaq.com/forum/mv/msg/57760/156152/#msg_156152
http://www.orafaq.com/maillist/oracle-l/2006/08/10/0447.htm

Re: Oracle RMAN Backup API [message #687636 is a reply to message #382681] Sat, 22 April 2023 04:57 Go to previous messageGo to next message
John Watson
Messages: 8929
Registered: January 2010
Location: Global Village
Senior Member
alwar wrote on Fri, 23 January 2009 16:09
Hi,

can any one tell me RMAN Backup API that we can integrate into our application program?.

Thanks in advance..
Alwar
The API is dbms_backup_restore, but it isn't documented so you have to do a lot of reverse engineering to suss out how to use it. And I would think it unlikely that calling it directly is supported. I've used it occasionally, for instance this is a very simple way to get a directory file listing:


var ns varchar2(1024)
var dirname varchar2(1024)
exec :dirname:='c:\tmp'
exec sys.dbms_backup_restore.searchfiles(:dirname,:ns)
select fname_krbmsft FROM x$krbmsft;

Re: Oracle RMAN Backup API [message #687639 is a reply to message #687636] Mon, 24 April 2023 02:08 Go to previous messageGo to next message
Pratiksha_Ratnaparkhi
Messages: 2
Registered: April 2023
Junior Member
Hi @Michel Cadot,

Thanks for your previous inputs.

I am using AWS EC2 instance. So to execute RMAN commands for AWS, I have to launch SQLPLUS CLI. And from there I will not be able to execute the rman command you provided as that utility is not present.
EX., I use rdsadmin_rman_util library on sqlplus to execute RMAN related tasks.

I went through API link you provided but it will also not work in this case.

Do you have any inputs in this scenario?
Re: Oracle RMAN Backup API [message #687640 is a reply to message #687639] Mon, 24 April 2023 02:34 Go to previous message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator

With SQL*Plus you can execute an OS command using the SQL*Plus HOST command:
SQL> host echo list incarnation;quit | rman target / nocatalog

Recovery Manager: Release 11.2.0.4.0 - Production on Lun. Avr. 24 09:32:39 2023

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

connected to target database: MIKB2 (DBID=288523517)
using target database control file instead of recovery catalog

RMAN>

List of Database Incarnations
DB Key  Inc Key DB Name  DB ID            STATUS  Reset SCN  Reset Time
------- ------- -------- ---------------- ------- ---------- ----------
1       1       MIKB2    288523517        CURRENT 1          30/08/2010 16:57:33


Recovery Manager complete.

SQL>

Previous Topic: Oracle cannot open database
Next Topic: RMAN restore - only DB backup ( no SF\CF\archivelog backup )
Goto Forum:
  


Current Time: Sat Apr 20 02:38:36 CDT 2024