Re: Delete Datafile and Recover DB Without Using Backup?

  • From: Tim Gorman <tim@xxxxxxxxx>
  • To: "oracle-l@xxxxxxxxxxxxx" <oracle-l@xxxxxxxxxxxxx>
  • Date: Mon, 28 Feb 2005 01:57:12 -0700

...your luck will have to extend as far as the session also having SYSDBA
privileges, which is required to use the DBMS_BACKUP_RESTORE package...

And, if your RECID/STAMP combination points to tape media, then Shared
Server (MTS) would be a hindrance, not an aid, as I believe that RMAN MMV
"shared libraries" require "dedicated server".



on 2/24/05 6:11 PM, Jeremiah Wilton at jeremiah@xxxxxxxxxxx wrote:

> What a great question.
> 
> Here's an untested idea:
> 
> 1) Find a running session (SQL*Plus?) that has the deleted datafile open =
> (Unix lsof <file>), or if you are running Shared Server (MTS) just log in=
> and hope to get a server process that has the file open.
> 
> 2) In that session, run:
> declare
>   a varchar2;
>   b number;
>   c number;
> begin
>   sys.dbms_backup_restore.copydatafile (
>       DFNUMBER=3D>file#,
>       FNAME=3D>'datafile copy name',
>       FULL_NAME=3D>a,
>       RECID=3D>b,
>       STAMP=3D>c
>   );
> end;
> 
> Can anyone think of a way to force this PL/SQL to be run in any open sess=
> ion without *being* that session?
> 
> People please correct me if necc. on my PL/SQL and use of dbms_backup_res=
> tore.
> 
> --
> Jeremiah Wilton
> ORA-600 Consulting
> Emergencies - Seminars - Hiring
> http://www.ora-600.net
> 
> 
>> -----Original Message-----
>> From: mkb [mailto:mkb125@xxxxxxxxx]
>> 
>> If a Oracle datafile is removed from a file while the
>> instance is still running and the database is open, is
>> it possible to recover without using a backup before
>> shutting down the database?
> 
> 
> 
> --
> //www.freelists.org/webpage/oracle-l
> 

--
//www.freelists.org/webpage/oracle-l

Other related posts: