Restore RMAN from different Database Rman backup

Hi Everybody
I am practicing Rman so I have one query that how to restore rman backup from another database.
For Example :
1. I have Rman backup of DB1 with level 0 and level 1 cumulative database plus archievelog
2. I need to import or restore Rman backup of DB1 to another database DB2.
What is the procedure for doing the above queries. Please anyone one help me out.
I have using oracle 10g r2 running in windows server 2003.
Thanks in advance.

These are the steps ; you need to write the appropiate commands for each step: Hope it helps!
1) Take appropriate RMAN backup of the database db1. Note that you should turn on the CONTROLFILE AUTOBACKUP configuration so that we have the controlfile backed up after the database backup. When we restore the controlfile on new host from this autobackup piece, it will have the information of the latest backup.
2) Create a PFILE for the destination database db2 using the database db1
3) Move the backup pieces and the modified INIT.ORA file to the new host. Starting from 10g it is NO longer compulsory to copy the RMAN backup pieces to exactly the same location on the new host as the production location.
4) Use the pfile created above to STARTUP NOMOUNT the database on the new host
5) Now invoke RMAN and restore the controlfile specifying the location where the controlfile autobackup piece is restored on this new server. You can mount the database once the controlfile is restored successfully.
6) You can skip this step if you have restored the RMAN backup pieces to exactly the same location they were backed up on database db1. If this is not the case then you need to catalog the RMAN backup pieces to make RMAN aware of thier new location on the new host. Note that CATALOG BACKUPPIECE command is available only starting from 10g.
7) Having determined the point up to which media recovery should run, start the restore/recovery using for example:
RMAN> run {
2> set until sequence 59 thread 1;
3> set newname for datafile 1 to '/new_location/system01.dbf';
4> set newname for datafile 2 to '/new_location/undotbs01.dbf';
5> set newname for datafile 3 to '/new_location/sysaux01.dbf';
6> set newname for datafile 4 to '/new_location/users01.dbf';
7> restore database;
8> switch datafile all;
9> recover database;
10> }

Similar Messages

  • Data from different databases in the same report.

    Hi Everyone,
    I am trying to build a reconciliation report in which I need to show the data from the source and target, side by side.
    Source and target are both different databases, although being oracle only
    Whenever a new data model is created, it gets attached to a data source and in the report we need to choose a specific data model.
    Can we have data from different databases in the same report ?

    Yes, it is possible.
    One way Is to use dataTemplates. There you can make queries from any number of different databases (The max I have done is 5).
    It looks something like that:
    <dataTemplate name="NameOfTemplate">
    <dataQuery>
         <sqlStatement name="Q1" dataSourceRef="Connection1">
              <![CDATA[     select * from table1]]>
         </sqlStatement>
         <sqlStatement name="Q2" dataSourceRef="Connection2">
              <![CDATA[     select * from table2]]>
         </sqlStatement>
      </dataQuery>
      <dataStructure>
         <group name="RESULT1" source="Q1">
              <element name="P_FIRST_NAME" value="P_FIRST_NAME"/>
         </group>
         <group name="RESULT2" source="Q2">
              <element name="P_DATE" value="P_DATE"/>     
         </group>
      </dataStructure>
    </dataTemplate>dataStructure is very important when you get data from different places, if you don't define those elements, then only the result from Q1 is shown.
    The second possible way is to make as two different data models, each containing their own query and then set Main Data Set as concatenated SQL Data Source.
    Best of luck,
    Evelyn

  • Select data from different database

    hi,
    may I know how to select data from different database?
    for example,
    I've 2 databases, OracleDB and OracleAR
    Connect with OracleAR in SQL*Plus
    select * from OracleDB.TableName
    does Oracle support this kind of query?
    how can I retrieve data from other database while im connecting with
    other database?

    Hi,
    Yes, it's possible. No, your syntax won't work.
    First of all you have to define a DATABASE LINK inside the DB where you are already connected (in this case OracleAR). Read docs how to do that.
    Second thing is the query. It will look like
    SELECT * from TableName@<NameOfDatabaseLink>Greetings,
    Guido

  • Single query to get data from different databases

    i need to capture certain fields from certain tables in database 1 and certain fields from certain tables in database 2 into one file using a single SQL statement.
    i tried searching on the net
    i found that dblinks can help
    but iam not sure if ill be able to create dblinks in my situation which is:
    i need to get data from oracle to be copied to mysql
    this is not a replication acitivity, but i need certain fields from one database and certain from the other
    so what iwas thinking is, if i use an sql query to get all the fields (i need around 40) from the different oracle databases and create a singlefile with one insert per select, i can then read that file into mysql
    instead of creating multiple sql queries for each table and creating separate files and eventually separate tables in mysql.
    can anyone help me here?
    or maybe suggest another approach.
    thanks

    Hi,
    I think dblink is the only option available to get data from different databases. It will work for your case too.
    CREATE DATABASE LINK db_link CONNECT TO user_name IDENTIFIED BY  password USING 'instance_name'you must have the system privilege 'create database link' to create db links. This way you can get the required data and put it in a table in oracle. But i dont know how to put this data from oracle table to Mysql.
    HTH
    Muneer

  • Help needed to insert data from different database

    Hi ,
    I have a requirement where i need to fetch data from different database through database link .Depending on user request , the dblink needs to change and data from respective table from mentioned datbase has to be fetched and populated .Could i use execute immediate for this, would dblink work within execute immediate .If not , could pls let me know any other approach .

    What does "the dblink needs to change" mean?
    Are you trying to dynamically create database links at run-time? Or to point a query at one of a set of pre-established database links at run-time?
    Are you sure that you really need to get the data from the remote database in real time? Could you use materialized views/ Streams/ etc to move the data from the remote databases to the local database? That tends to be far more robust.
    Justin

  • Fetch data from different database tables

    Hi...
    How can i fetch data from different database tables and put it into a internal table and then display it??? Can provide simple short codes as i'm new to ABAP. Thanks.

    Hi,
    Check this sample code..
    TYPE-POOLS: slis.
    DATA: BEGIN OF itab OCCURS 0,
            vbeln TYPE vbeln,
            expand,
          END OF itab.
    DATA: BEGIN OF itab1 OCCURS 0,
            vbeln TYPE vbeln,
            posnr TYPE posnr,
            matnr TYPE matnr,
            netpr TYPE netpr,
          END OF itab1.
    DATA: t_fieldcatalog TYPE slis_t_fieldcat_alv.
    DATA: s_fieldcatalog TYPE slis_fieldcat_alv.
    s_fieldcatalog-col_pos = '1'.
    s_fieldcatalog-fieldname = 'VBELN'.
    s_fieldcatalog-tabname   = 'ITAB'.
    s_fieldcatalog-rollname  = 'VBELN'.
    s_fieldcatalog-outputlen = '12'.
    APPEND s_fieldcatalog TO t_fieldcatalog.
    CLEAR: s_fieldcatalog.
    s_fieldcatalog-col_pos = '1'.
    s_fieldcatalog-fieldname = 'VBELN'.
    s_fieldcatalog-tabname   = 'ITAB1'.
    s_fieldcatalog-rollname  = 'VBELN'.
    s_fieldcatalog-outputlen = '12'.
    APPEND s_fieldcatalog TO t_fieldcatalog.
    CLEAR: s_fieldcatalog.
    s_fieldcatalog-col_pos = '2'.
    s_fieldcatalog-fieldname = 'POSNR'.
    s_fieldcatalog-tabname   = 'ITAB1'.
    s_fieldcatalog-rollname  = 'POSNR'.
    APPEND s_fieldcatalog TO t_fieldcatalog.
    CLEAR: s_fieldcatalog.
    s_fieldcatalog-col_pos = '3'.
    s_fieldcatalog-fieldname = 'MATNR'.
    s_fieldcatalog-tabname   = 'ITAB1'.
    s_fieldcatalog-rollname  = 'MATNR'.
    APPEND s_fieldcatalog TO t_fieldcatalog.
    CLEAR: s_fieldcatalog.
    s_fieldcatalog-col_pos = '4'.
    s_fieldcatalog-fieldname = 'NETPR'.
    s_fieldcatalog-tabname   = 'ITAB1'.
    s_fieldcatalog-rollname  = 'NETPR'.
    s_fieldcatalog-do_sum    = 'X'.
    APPEND s_fieldcatalog TO t_fieldcatalog.
    CLEAR: s_fieldcatalog.
    DATA: s_layout TYPE slis_layout_alv.
    s_layout-subtotals_text            = 'SUBTOTAL TEXT'.
    s_layout-key_hotspot = 'X'.
    s_layout-expand_fieldname = 'EXPAND'.
    SELECT vbeln UP TO 100 ROWS
           FROM
           vbak
           INTO TABLE itab.
    IF NOT itab[] IS INITIAL.
      SELECT vbeln posnr matnr netpr
             FROM vbap
             INTO TABLE itab1
             FOR ALL ENTRIES IN itab
             WHERE vbeln = itab-vbeln.
    ENDIF.
    DATA: v_repid TYPE syrepid.
    v_repid = sy-repid.
    DATA: s_keyinfo TYPE slis_keyinfo_alv.
    s_keyinfo-header01 = 'VBELN'.
    s_keyinfo-item01   = 'VBELN'.
    CALL FUNCTION 'REUSE_ALV_HIERSEQ_LIST_DISPLAY'
         EXPORTING
              i_callback_program = v_repid
              is_layout          = s_layout
              it_fieldcat        = t_fieldcatalog
              i_tabname_header   = 'ITAB'
              i_tabname_item     = 'ITAB1'
              is_keyinfo         = s_keyinfo
         TABLES
              t_outtab_header    = itab
              t_outtab_item      = itab1
         EXCEPTIONS
              program_error      = 1
              OTHERS             = 2.
    IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    Thanks
    Naren

  • Restore comes from different backups

    While performing a restore of an 8.1.7 database (actually it was a duplicate) from a hot backup, I noticed that the restore used backup sets from different backup days. It used the hot backup from 3/27 for datafiles 4,8, and 9. It used the hot backup from 3/28 (the date I want to restore from) for all other datafiles. I don't understand why RMAN would not use all backup sets from 3/28. These datafiles are not offline or read only.
    Thanks for your input!

    No, every time you restore from backup your data and settings are replaced with the data and settings from the backup you restore from.  About the only thing you could do is restore from one of the backups and then use 3rd party software such as iPhone Backup Extractor to extract the additional data you want from the second one and sync this back to your phone.

  • Database restore from different Database Sid

    I have installed sap ecc6 sr3 on db2 version 9.1 fp5 which is running on WIn2003 Enterprise x64 edition which is working fine. It is my Quality server Database Sid Q11.
    Now i want to restore database from Development server D11 (offline backup) to quality server Q11.
    Development server database Sid is D11.
    How to restore from Different Sid. (In DB2 database).
    Please tell me how to restore database from another Sid.

    Hi,
    what you have to do is a so called "redirected restore".
    The recommended way to that in an SAP-DB2 environment, is to use the tool brdb6brt shipped together with the SAP kernel. For details how to use this tool refer to the DB2-UDS Database Administration Guide.
    kind regards
    Thomas

  • Restore mailbox from exchange database backup

    we are on exchange 2007 sp1 on windows 2008 OS.
    one user has lost all emails in his inbox, the only emails existing are that of today's.
    We have daily backups of the exchange DB/SG.
    Please advise if we can restore/recover his mailbox/inbox from this DB/SG backup. Also if there are any other ways to restore/recover his emails.
    Also, we cannot unmount the current DB, what tasks must i perform to mount this DB and restore/recover the mailbox or can I do this without mounting the DB. I dont want to disturb the existing DB/SG.
    We use commvault simpana 9 as our backup tool.
    please help.

    Hello,
    Come back and mark the replies as answers if they help and unmark them if they provide no help.
    I'm marking the reply as answer as there has been no update for a couple of days.
    If you come back to find it doesn't work for you, please reply to us and unmark the answer.
    Cara Chen
    TechNet Community Support

  • SQL Server wants to open properties of wrong database and cannot restore logs of different databases at the same time

    We have implemented our own way of logshipping by backing up the transaction logs of all our non-system databases every hour. Then we transfer the backups (before SQL Server 2008 R2 with additional zip and unzip steps) to the second environment where we
    restore them only during the night on databases in standby-state (Like this, our developers can access the databases without disturbing the productive system and we can restore the t-logs during night, so not shutting out the developers during the day).
    Now since we replaced our hardware in the productive environment, we replaced the hardware in the second environment with the servers from previous productive environment. Same SQL Server 2008 R2, same Service Pack (SP2), same installation procedure. But
    since then the SQL Server in the second environment behaves different:
    - When the logs of some database "A" are restored, I cannot access the properties of any database, i.e. database "B", I only get the error message "Cannot show requested dialog. (SqlMgmt) Database 'A' cannot be opened. It is in the
    middle of a restore. (Microsoft SQL Server, Error: 927)"
    - Our logshipping runs multiple instance at the same time, so restoring multiple databases' logs. But since the change, two of the instances fail restoring of datatbases, i.e. "B" and "C" with the error message "Database 'A' cannot
    be opened. It is in the middle of a restore.". The jobs guarantee to restore only logs of the database they need to restore, they have strictly separated sets of target databases and only try to restore the databases of their sets.
    Before the new installations, we did not have these strange behaviours. But as said, it is the same SQL Server version, the same service pack, and we followed the same installation document but maybe with the small changes in settings. The user the jobs
    are running under is a domain admin, the login they use has dbcreator, processadmin, db_owner and db_backupoperator roles. My login on the SQL Server has sysadmin rights and as described similar problems.
    Is this problem known or does somebody have an idea where to go looking for?
    Thanks, Chris

    Hi Christar,
    According to your description, after you configuring Log shipping between two database, you remove the hardware from production environment to dev environment, in this hardware, there are saved the transaction logs of your database.
     When restoring  your database, there will occurs error 927, right?
    SQL Server Log shipping allows you to automatically send transaction log backups from a
    primary database on a primary server instance to one or more
    secondary databases on separate secondary server instances. It consists of three operations:
    1.Back up the transaction log at the primary server instance.
    2.Copy the transaction log file to the secondary server instance.
    3.Restore the log backup on the secondary server instance.
    Since you want to move your hardware avoiding copy job, we need to verify if .mdf and .ldf file are not saved in your hardware, or else,
     if you move your hardware, you could not open your database in your Primary Server. I recommend you can refer to the following steps.
    Full back up your primary database and restore it into the secondary database. It would have been set up as WITH STANDBY ,the databases would read StandBy/ Read Only.
    Perform transaction log backups via a SQL Server Agent job running on the primary server instance, save them in your hardware.
    In night, you move hardware to your dev environment, you can manually restore these transaction log backups or set up a SQL Server Agent job to restoring them from your hardware.
    There is detail about how to configure log shipping in SQL Server 2008R2 step by step, you can review it.
    http://mostafaelmasry.wordpress.com/2013/01/02/log-shipping-in-sql-server-2008r2-step-by-step/
    Regards,
    Sofiya Li
    Sofiya Li
    TechNet Community Support

  • How do I restore notes from a time capsule backup in Yosemite?

    All I want to do is restore previously deleted notes form a time capsule backup - something you could easily do in previous releases (I probably haven't tried this for a few years but it used to be really simple)

    This procedure will revert the whole Notes database to a previous version. It's not possible to restore individual notes.
    Triple-click anywhere in the line below on this page to select it:
    ~/Library/Containers/com.apple.Notes
    Right-click or control-click the highlighted line and select
              Services ▹ Reveal in Finder (or just Reveal)
    from the contextual menu.* A folder should open with an item named "com.apple.Notes" selected. Quit the application if it's running. Move the selected item to the Trash, then restore it from a backup that predates the unwanted change. If you back up with Time Machine, enter it and select the snapshot from which you want to restore.
    Log out or restart and empty the Trash.
    If you synchronize Notes with iCloud or another network service, the notes you restored may be immediately deleted after you restore them. In that case, temporarily disconnect from the Internet, for example by turning off your broadband adapter, and restore again. Copy the contents of each note to a document in another application, such as TextEdit. Reconnect to the Internet. If the notes are deleted, recreate them from the TextEdit document. They should then synchronize to the network.
    *If you don't see the contextual menu item, copy the selected text to the Clipboard by pressing the key combination command-C. In the Finder, select
              Go ▹ Go to Folder...
    from the menu bar and paste into the box that opens by pressing command-V. You won't see what you pasted because a line break is included. Press return.

  • Restore mailbox from different user

    Hi
    I got a new Mac. For some reasons I decided to start with a fresh Useraccount. For the most applications I was able to restore settings and mire from the former time machine backup of the old computer. But with Mail it doesn't work. It's not enough to restore user/library/applications support/mail...... . It's also not working to open mail, choose time machine backup from another disk. As it is a different user I can not restore anything.
    How do I restore Mailbox from an other user properly?

    Hello,
    Come back and mark the replies as answers if they help and unmark them if they provide no help.
    I'm marking the reply as answer as there has been no update for a couple of days.
    If you come back to find it doesn't work for you, please reply to us and unmark the answer.
    Cara Chen
    TechNet Community Support

  • Restoring data from a Time machine backup of a potentially corrupted drive

    I seem to be the queen of failing hard drives, heh. I'm on my third in a year, and will be addressing the root cause of these failures, of course, but right now, I'm wondering how safe it is to restore from my Time Machine backup. Here's the scenario:
    -- Drive started throwing I/O errors, detected via SMARTReporter, about 2-3 months ago. No change in how the machine functioned, all OK.
    -- I continued to back up daily to TM & Crashplan
    -- While traveling for a month (and not backing up anymore, I left TM home), the machine started acting funny. Finder freezing, etc. I decided to clear some caches (by booting into safe mode) and see what happened.
    -- This caused the HD to fail completely. Recovery mode, target disk mode, booting into single user mode and command-lining fixes, and DiskWarrior all failed to rebuild the directory. Failures were in multi-linked files/directories, the catalog file, etc.
    -- I ordered a warranty replacment drive (and a new hard drive cable for starters).
    When I got home, I borrowed another machine and just did a Verify Disk on the TM backup. It came back totally clean. So, my question is: is it safe to restore the data from my TM backup to the new drive when it arrives?

    Shouldn't be any problem.
    Boot from your SL installer DVD (hold down the C key on startup or hold down Alt/option on start and choose the installer disc).
    OK the language page (if present). From the installer screen, go to the menu bar and choose Disk Utility; depending on the OS version it may be in the Utilities menu or Tools menu.
    In DU, select your internal drive in the sidebar (the top item with the makers name and serial no.). Run Repair Disk. If that comes up as disk OK, click the partition tab. Select the partiton from the drop-down above the graphic; 1 partiton is all you need. Go to the options button and ensure that the partition scheme is GUID (for Intel Macs) or APM (for G5 and earlier) and the file system to Mac OS Extended (Journalled). Name the partiton (usually Macintosh HD), click Apply.
    When that's finished, select the new volume in the sidebar (indented to the right below the drive) and go to the Erase tab, select Security options and select zero data (one pass is more than sufficient). Click erase. That will take quite some time; probably measured in hours and dependant on the size of the drive.
    When that's completed, close DU and continue with the installation.
    Shortly into the installation process, you'll be asked if you want to migrate data from another source. Select 'from a Time Machine Backup' and follow the prompts.
    See Pondini's FAQs;
    http://web.me.com/pondini/Time_Machine/19.html
    http://web.me.com/pondini/AppleTips/SetupAsst.html
    That should leave you with the same setup as you had on the previous MB.

  • Restore/recover from cold user-managed backup.

    i shutdown db,(db is in no-archivelog mode), copy the dir having *.ctl, *.log & *.dbf files, what would be steps to recover in case,
    my idea is restore all files in original dir and alter database open resetlogs should do the work,
    if that did'n work then mount db and try
    recover database using backup controlfile until cancel;
    and give path one of online logfile and hit enter; & open db with resetlogs.make me right, if i am not......or any quick way to restore/recover tip?

    DBA2008 wrote:
    i shutdown db,(db is in no-archivelog mode), copy the dir having *.ctl, *.log & *.dbf files, what would be steps to recover in case,
    my idea is restore all files in original dir and alter database open resetlogs should do the work,
    if that did'n work then mount db and try
    recover database using backup controlfile until cancel;
    and give path one of online logfile and hit enter; & open db with resetlogs.make me right, if i am not......or any quick way to restore/recover tip?Why resetlogs ? All what you need is a pfile, if its not there already and start the db. That's all!
    Aman....

  • Restore files from last Time Machine backup after HD erase and install

    I just had to do an "erase and install" ... trying to restore files from my last Time Machine backup but after completing the Airport Utility setup / configure steps, it says "waiting to restart" for a few minutes and then says it cannot find TIme Capsule after restart (though TC never restarted). I'm pretty desperate to get my files back as it's Sunday night and my business needs to be up and running by morning. Any help would be greatly appreciated ... even if it's saying I need to take TC into a Mac store to have them retrieve my files.

    While in Time Machine, press the key combination shift-command-C. The front window will show all mounted volumes. All snapshots should now be accessible. Select the one you want and navigate to the files you want to restore.

Maybe you are looking for

  • Issue with Emoji icons when sent from iOS6 to iOS5

    Issue with Emoji icons when sent from iOS6 to iOS5, all icons appear as a square on the iOS5 message screen. Both iOS are the current version and the phones are 4S 64GB Anybody got this problem

  • Include Javascript in ADF file

    Hi, I use JDev TP4 with ADF This is what the beginning of my page looks like. I am wondering where I have to put the script tag, if I want the script in my header. Putting <script> after <jsp:directive...> will put the script in the header, but the c

  • My iphone 5 is not turning on

    hi i am using iphone 5 an year old.sday i have 50%of chrage b4 i slept.when i woke up in the morn my phone is switch of.i have put my phone in charge for an hr still no sign in the phone...anyhelp..?pls

  • ACI Modification with Plug-in, bnt,...

    I coded plugin which Modifies ACI. Following is the plugin working and Problem. Plugin working. Client requests to modify "Macl" atrribute of some entry A. (Here, "Macl" attribute is user-defined attribute.) with this request, On server side, Plugin

  • Australian iphone4, using UK sim, calls & data fine, can't text!

    I'm using an ( unlocked from Vodafone Australia) iphone 4 in the UK with a 3 prepaid sim. Data and calls are fine. However, I can't send a text. Tried fiddling with the imessage settings, switching on/ off, no joy. Any help gratefully received!!!!