DBAsupport.com Forums - Powered by vBulletin
Results 1 to 7 of 7

Thread: RMAN - Testing

  1. #1
    Join Date
    Jan 2001
    Posts
    642
    Hi,

    I want to make use of the RMAN utility, available with the oracle 8i. I have installed 2 databases(prod and catdb). The initial steps of connecting to RMAN, registering db etc are complete.

    I wanted to create and resolve this scenerio

    1) Create a table (A) on tablespace (TSA), populate it.
    2) Take the rman tablespace backup(TSA).
    3) Drop the table(A)

    Now, I want to get back the table(A) from the rman backup.

    How can I get it back;

    Steps will be very useful.
    Badrinath

  2. #2
    Join Date
    Oct 2000
    Location
    Saskatoon, SK, Canada
    Posts
    3,925
    Take a look at the table space point in time recovery.

    Sam
    Thanx
    Sam



    Life is a journey, not a destination!


  3. #3
    Join Date
    Jun 2001
    Location
    Charlotte, NC
    Posts
    27
    Originally posted by badrinathn
    Hi,

    I want to make use of the RMAN utility, available with the oracle 8i. I have installed 2 databases(prod and catdb). The initial steps of connecting to RMAN, registering db etc are complete.

    I wanted to create and resolve this scenerio

    1) Create a table (A) on tablespace (TSA), populate it.
    2) Take the rman tablespace backup(TSA).
    3) Drop the table(A)

    Now, I want to get back the table(A) from the rman backup.

    How can I get it back;

    Steps will be very useful.
    Badrinath
    Rman does not support logical backups. If you wanted to create the scenario it would be best to do a export then drop the table and perform a import. If you were to do this with Rman you would essentially have to perform a tablespace recovery or database recovery using the restore database;
    recover database while inside of RMAN. Make sure you have at least one good backup before you begin.

  4. #4
    Join Date
    Feb 2000
    Location
    New York,U.S.A.
    Posts
    245
    I just did one not long ago with Rman to recovery tablespace.
    I accidentally dropped one tablespace and its datafile . I use Rman to do my backup and recovery. Be sure you have a good copy of full backup, and on archivelog mode.
    To use Rman to recover tablespace:
    RMAN> run {
    sql 'alter tablesapce tablespacename offline immediate';
    allocate channel ch1 type disk;
    set new name for datafile '/.../...' to '/.../...';
    restore tablespace tablespacename;
    switch datafile all;
    recover tablespace tablespacename;
    sql 'alter tablespace tablespacename online';
    }

    If you have any problems in doing so, please email me @youngz99@hotmail.com. I am glad to help.

    Dragon



  5. #5
    Join Date
    Jan 2001
    Posts
    642
    Hi,

    Continuing with the tablespace recovery method, I did the following.

    I took the tablespace(WHS) backup.
    I dropped one table(order_detail)
    I restored the tablespace as given by dragon:


    RMAN> run {
    sql 'alter tablespace whs offline immediate';
    allocate channel ch1 type disk;
    ##set new name for datafile '/.../...' to '/.../...';
    restore tablespace whs;
    switch datafile all;
    recover tablespace whs;
    sql 'alter tablespace whs online';
    }

    ## I don't know what this line means.

    Now the tablespace is recovered, but I am unable to get the dropped table.
    Where did I go wrong?
    Badrinath


  6. #6
    Join Date
    Jan 2001
    Posts
    642
    Is is that the tablespace is recovered with table and on appling the redo log files, the table is getting dropped again.

    Correct me
    Badrinath

  7. #7
    Join Date
    Oct 2000
    Location
    Saskatoon, SK, Canada
    Posts
    3,925
    You apply the log files to the point just before the table was dropped. That would be an incomplete recovery, b'cos anu changes that had taken place after this point on other tables would be lost. The best is clone the db from the backup. Do an incomplete recovery on the backup to the point the table was dropped, on the clone db. Then export that table space and import it into the production db. You are set.


    Sam
    Thanx
    Sam



    Life is a journey, not a destination!


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width