Restoring a database from a different database

I want to restore database new2db from newdb. both dbs are on different sql server instances.
I have backup of newdb called newdb_july.bkup.
I ran the below command :
restore database new2db from disk = 'c:\mssql\backup\newdb_july.bkup' with file=1,
move 'newdb' to 'C:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA\new2db.mdf',
move 'newdb_log' to 'C:\Program Files\Microsoft SQLServer\MSSQL10.MSSQLSERVER\MSSQL\DATA\new2db_log.ldf', 
replace,norecovery,stats=10
the restore completed successfully but the database is still in 'Restoring' status.
how do I get the database in active accessible status?
appreciate the feedback.

Yes norecovery if you want to restore more tlog or diff backup files... If you use recovery then you cant further restore any more tlog or diff backup's..
WITH RECOVERY includes both the redo and undo phases and recovers the database; additional backups cannot be restored. This is the default.
If the roll forward set has not been rolled forward far enough to be consistent with the database, the undo phase cannot occur. The Database Engine issues an error and recovery stops.
If the whole roll forward set is consistent with the database, recovery is performed, and the database can be brought online.
WITH NORECOVERY omits the undo phase to preserve uncommitted transactions. Omitting the undo phase allows for restoring other backups to roll the database further forward in time. Occasionally, RESTORE WITH NORECOVERY rolls forward data
to where it is consistent with the database. In these cases, the Database Engine issues an informational message stating that the roll forward set can now be recovered by using the RECOVERY option.
With the REPLACE option, restore allows you to overwrite an existing database with whatever database is in the backup set, even if the specified database name differs from the database name recorded in the backup set. This can result in
accidentally overwriting a database by a different database.
Raju Rasagounder Sr MSSQL DBA

Similar Messages

  • Can you restore to factory from a different computer then restore backup from the original computer?

    My son reset then forgot his passcode, when I try to restore from his computer his pc freezes. I have tried several times and continues to freeze. He does not want to lose his contacts, purchased songs and apps but all else does not really matter.
    So, am I able to restore his touch from my computer then restore the backup from his computer?  It did complete the backup on his PC.
    Please help, we have been messing with this for a few weeks now and I am just tired of trying to restore when his pc keeps freezing...

    Yes, just plug in into iTunes and it'll give you the option to restore as a new device..

  • How can I restore my iPhone from a different backup?

    Okay I don't know if this is possible, but it would really make my life easier if someone knew how to do this.
    My old iPhone was named Joe's iPhone. It had all my contacts, pics, apps, everything. That phone broke and my Mom gave me her old iPhone, both are 3g. So on my computer I obviously had sync'd my old phone (Joe's iPhone) and backed it up. Can I restore my Moms phone and boot it up with my old backup so I'll have all my contacts? I've tried restoring it, but I also backed up my Mom's phone on my computer so whenever I restore it, it just comes back with all her contacts. I want to chose to restore from my old phone backup.
    Is this possible? Can anyone walk me through doing that?

    Hi Joe,
    Just right-click on the iPhone(on the left side of iTunes, under Devices) and then choose Restore from Backup. Then choose the backup that has the date and name of your previous phone.
    These articles provide additional information about iPhone backups:
    http://support.apple.com/kb/HT1766
    http://support.apple.com/kb/HT1414
    -Jason

  • Restoring book marks from a different drive

    i had to delete Firefox 3.6 do to a conflict with searchtempest. so i copied the favorites from Firefox to my flash drive and now i need to put them back so Firefox will see them. just where are the favorites in Firefox so i can use them again?

    thanks for these answers but they are after the fact. i just copied the bookmarks folder to the flash drive then i deleted Firefox then i downloaded a new copied of the program and then installed it. then i went to locate the bookmarks data and i did not see the folder. so i just imported the bookmarks from internet explorer and rearranged them to my taste. thanks for the help.
    i suppose i should have used the backup link and that may have worked better.
    i would rather use a newer version of Firefox but the spellbound program fails in the newer versions and i like that little program. no one seems to have updated spellbound to work with the new versions of Firefox. when version 3.6 fails and i can't get it to go again i will go back the internet explorer or to chrome they have nice spell checker programs that i like but I'm use the fire fox so i just keep using it.

  • Can you restore a backup from an iPhone 6 to an iPad 2?

    I bought my wife an iPad 2 and I want to set it up to be just like her iPhone 6 (absent the iPhone only apps, obviously). However, I cannot seem to get it done.
    I do not use iCloud backup - this is from a backup on a Mac running Yosemite via iTunes.  Both devices are running iOS 8.1.3.
    I select 'Restore Backup', then select the backup of my wife's iPhone and I get a message: "Settings and data from some apps are not compatible with iPad and will not be restored." I figure this means it will restore everything except the iPhone specific apps.
    I click 'continue' and it appears to go through the restore process, but then nothing gets installed on the iPad.
    Thoughts?
    MotionMan

    I restored a backup from a DIFFERENT iPad (mini) to my target iPad 2.  I have not been able to restore the backup from the iPhone to the target iPad.
    I have tried the following:
    Backup of iPhone 6 to target iPad 2 - Fail
    Backup of iPhone 5S to target iPad 2 - Fail
    Backup of different iPad mini to target iPad 2 - Complete
    So the target iPad 2 will take a restore from a different iPad (mini), but not from two different iPhones.
    Is it just me, or can such a restore just not be done?
    MotionMan

  • Restoring a backup from a 9500 to a 9300

    I broke my 9500 (yes silly me ) and the insurance copmpany said there are no more 9500s available but I could have a 9300 so I took one, however the tech support at Club Nokia now say I can't restore the data from backup of the 9500 to the 9300, so my five years of contacts is gone!! Did some engineer at Nokia really think about this, no upward compatibility between backup data ??? Additionally why isn't the backup data stored in an 'open' format, it's not accessible to any other application, are these guys living in the real world, has no one at Nokia heard of 'open' systems ?

    No, don't copy files anywhere. Just go into your backup area in My Documents and rename the existing folder to reference your new device.
    Hang on. From one of my FAQs:
    "Should you need to restore a Nokia 9300 or 9500 backup onto a new device (either because you've swapped one for the other or because you've got a replacement after a hardware fault), it's worth noting that PC Suite needs you to make sure that the backup files have the right name. If the names don't match, it won't let you do the restore.
    Let's say you had a 9500. Having connected up your new 9300 for the first time, it will probably take the name 'Nokia 9300' (surprise, surprise). Now the last backup of your 9500 can be found in '\My Documents\Backup files', with a filename resembling 'Nokia 9500 25-04-2005.nfb'. Simply rename the file, changing the start of the filename to be 'Nokia 9300'. You should now be able to restore your 9500 backup.
    Do please note that restoring a backup from a different device isn't guaranteed to work. Hardware differences (no camera or Wi-Fi on the 9300) and firmware differences mean that a direct restore is very much an experiment. If it doesn't work, you'll have to rebuild your internal 'C' disk from scratch, syncing over your latest PIM data and then installing applications and documents."
    Steve Litchfield
    Steve Litchfield
    3-Lib (Tips/resources/Info for Nokia smartphones and Communicators) plus All About Symbian

  • Restore a database in a new instance with different name

    Hello, I need restore a database in a different server. I have a backup of 01-Jan-2008 on tape on DataProtector and I need to restore in another server in order to extract some information for a datawarehouse, I need restore with a name different because on that server we have a standby database. The both servers are HP ia64 and have Unix. I have installed Oracle 10.2.0.4.0 EE. I read the Oracle RMAN Advanced but the process is for duplicate the database, I need restore a backup from 01-Jan-2008. Can you help me please. What steps should I run. Thanks for your answer.
    Ruben Nieto
    DBA

    Hi Ruben Nieto,
    Can you check on the target if the backup pieces are still registered in the controlfile?
    < connect target /; >
    < list backup completed before 'to_date('2009-01-02:00:00:00','YYYY-MM-DD:HH24:MI:SS')'; >
    If no information is available:
    1) "I can't use the same name for the database." -> excludes a restore/recover on the standby server.
    2) "how can I restore the database whitout catalog in other server" -> excludes a duplication to new name.
    If you want to keep it simple find a third HP ia64 machine where you can mirror your production environment and restore the complete backup set and recover the database keeping the name of the target.
    Regards,
    Tycho

  • How to restore a database from backup taken in standby database

    Its our  environment standard to run backup in standby database.
    Now we have to perform refresh production database to UAT database.
    I have performed normal refresh/duplicate.  Is there any additional procedures need to be followed to perform refresh from standby database backup

    RMAN Restoration to New Server with Different Directory and New Database Name
    In this case, I have an existing production database with RMAN Level 0 backup:
    CONFIGURE CONTROLFILE AUTOBACKUP ON;
    CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO 'C:\flash_recovery_area\galaxy\backupsets\autobackup\SAMSUNG-ctl_%F';
    CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 7 DAYS;
    CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT 'C:\flash_recovery_area\galaxy\backupsets\level0\level0-%d-%T-%U' MAXPIECESIZE 4G;
    DELETE NOPROMPT ARCHIVELOG ALL COMPLETED BEFORE 'SYSDATE - 7';
    SHOW ALL;
    REPORT SCHEMA;
    LIST BACKUP OF DATABASE;
    REPORT NEED BACKUP;
    REPORT UNRECOVERABLE;
    LIST EXPIRED BACKUP BY FILE;
    LIST ARCHIVELOG ALL;
    REPORT OBSOLETE;
    CROSSCHECK BACKUP DEVICE TYPE DISK;
    CROSSCHECK COPY OF ARCHIVELOG ALL;
    DELETE NOPROMPT EXPIRED BACKUP DEVICE TYPE DISK;
    DELETE NOPROMPT OBSOLETE DEVICE TYPE DISK;
    RUN {
    sql 'alter system archive log current';
    BACKUP INCREMENTAL LEVEL 0 DATABASE PLUS ARCHIVELOG DELETE INPUT;
    LIST BACKUP OF DATABASE;
    REPORT NEED BACKUP;
    REPORT UNRECOVERABLE;
    LIST EXPIRED BACKUP BY FILE;
    LIST ARCHIVELOG ALL;
    REPORT OBSOLETE;
    CROSSCHECK BACKUP DEVICE TYPE DISK;
    CROSSCHECK COPY OF ARCHIVELOG ALL;
    DELETE NOPROMPT EXPIRED BACKUP DEVICE TYPE DISK;
    DELETE NOPROMPT OBSOLETE DEVICE TYPE DISK;
    The backupsets will be restored into a new server with different file structure. The database will also be different. In the new server, I have created a blank database (SID or CUSTOM database with the name DBGRID). This is easier so I won't have to create any directories, user ORADIM or create new PWFile.
    This document assumes that a blank (starter) database has been created in the new server. The RDBMS version is the same as the source database.
    In this example, the source database name is GALAXY and the target database name is DBGRID.
    Let me know if you have any feedback or comments. All I want is to share these steps with you and make it better so we can help other DBA's as well.
    Steps start here
    -->
    ORIGINAL DATABASE: GALAXY
    DUPLICATE DATABASE: DBGRID
    FROM THE SOURCE DATABASE (GALAXY)
    1. Backup the database using RMAN incremental backups.
    2. Check the RMAN logs generated and look for the result of the command:
    C:\Users\Administrator>set ORACLE_SID=GALAXY
    C:\Users\Administrator>rman target /
    Recovery Manager: Release 11.2.0.1.0 - Production on Wed Aug 1 06:55:08 2012
    Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
    connected to target database: GALAXY (DBID=3578870300)
    RMAN> report schema;
    using target database control file instead of recovery catalog
    Report of database schema for database with db_unique_name GALAXY
    List of Permanent Datafiles
    ===========================
    File Size(MB) Tablespace RB segs Datafile Name
    1    680      SYSTEM *** C:\ORACLE\ORADATA\GALAXY\SYSTEM01.DBF
    2    510      SYSAUX *** C:\ORACLE\ORADATA\GALAXY\SYSAUX01.DBF
    3    140      UNDOTBS1 *** C:\ORACLE\ORADATA\GALAXY\UNDOTBS01.DBF
    4    5        USERS *** C:\ORACLE\ORADATA\GALAXY\USERS01.DBF
    5    106      EXAMPLE *** C:\ORACLE\ORADATA\GALAXY\EXAMPLE01.DBF
    6    2048     ALLINDEX *** C:\ORACLE\ORADATA\GALAXY\ALLINDEX01.DBF
    List of Temporary Files
    =======================
    File Size(MB) Tablespace Maxsize(MB) Tempfile Name
    1    29       TEMP 32767 C:\ORACLE\ORADATA\GALAXY\TEMP01.DBF
    This command shows all the physical database files that will be backed-up by the current RMAN job.
    List the online redolog files:
    SQL> select * from v$logfile;
    GROUP# STATUS  TYPE    MEMBER IS_
    3         ONLINE C:\ORACLE\ORADATA\GALAXY\REDO03A.LOG     NO
    3         ONLINE C:\ORACLE\ORADATA\GALAXY\REDO03B.LOG     NO
    2         ONLINE C:\ORACLE\ORADATA\GALAXY\REDO02A.LOG     NO
    2         ONLINE C:\ORACLE\ORADATA\GALAXY\REDO02B.LOG     NO
    1         ONLINE C:\ORACLE\ORADATA\GALAXY\REDO01A.LOG     NO
    1         ONLINE C:\ORACLE\ORADATA\GALAXY\REDO01B.LOG     NO
    6 rows selected.
    3. Since the target server has different structure, it is easier to use a pfile to startup the database rather than restoring the spfile from backup.
    C:\Users\Administrator>set ORACLE_SID=GALAXY
    C:\Users\Administrator>sqlplus / as sysdba
    SQL*Plus: Release 11.2.0.1.0 Production on Wed Aug 1 06:56:14 2012
    Copyright (c) 1982, 2010, Oracle.  All rights reserved.
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> create pfile='C:\TEMP\initGALAXYrman.ora' from spfile;
    File created.
    4. Edit the pfile to have the following parameters:
    (These parameters has been edited to fit the target database requirements)
    galaxy entries has been changed to dbgrid. Directories has been corrected as well.
    dbgrid.__db_cache_size=192937984
    dbgrid.__java_pool_size=4194304
    dbgrid.__large_pool_size=4194304
    dbgrid.__oracle_base='D:\app\Administrator'#ORACLE_BASE set from environment
    dbgrid.__pga_aggregate_target=281018368
    dbgrid.__sga_target=524288000
    dbgrid.__shared_io_pool_size=0
    dbgrid.__shared_pool_size=301989888
    dbgrid.__streams_pool_size=4194304
    *.audit_file_dest='D:\app\Administrator\admin\DBGRID\adump'
    *.audit_trail='db'
    *.compatible='11.2.0.0.0'
    *.control_files='D:\oradata\DBGRID\control01.ctl','D:\oradata\DBGRID\control02.ctl'
    *.db_block_size=8192
    *.db_domain=''
    Leave as it is for now --> *.db_name='GALAXY'
    *.db_recovery_file_dest='D:\fra\backupsets\duplicate'
    *.DB_RECOVERY_FILE_DEST_SIZE=4G
    *.diagnostic_dest='D:\app\Administrator'
    *.dispatchers='(PROTOCOL=TCP) (SERVICE=DBGRIDXDB)'
    *.job_queue_processes=1000
    *.log_archive_dest_1='location=D:\fra\backupsets\archs'
    *.log_buffer=10485760
    *.memory_target=805306368
    *.open_cursors=300
    *.processes=800
    *.remote_login_passwordfile='EXCLUSIVE'
    *.session_cached_cursors=300
    *.sessions=885
    *.undo_tablespace='UNDOTBS1'
    Make sure that all the directory values in this edited pfile are existing in the target server.
    5. Copy all the RMAN backup pieces generated in the source database. Transfer the edited pfile as well. Make sure that all directories presented in the pfile exists in the target server.
    In this example, RMAN backupsets are located at:
    Backupsets:
    Level0 and Level1 = D:\fra\backupsets\duplicate\level0 , D:\fra\backupsets\duplicate\level1
    Controlfile and Spfile Autobackup = D:\fra\backupsets\duplicate\autobackup
    Edited pfile initGALAXYrman= C:\TEMP\initDBGRIDnew.ora
    FROM THE TARGET DATABASE (DBGRID)
    6. Connect to RMAN and perform database duplication using RMAN backup restoration
    C:\Users\Administrator>rman target /
    Recovery Manager: Release 11.2.0.1.0 - Production on Wed Aug 1 07:26:45 2012
    Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.
    connected to target database (not started)
    RMAN> set dbid = 3578870300; --> THIS IS THE DBID OF THE SOURCE DATABASE!
    executing command: SET DBID
    RMAN> startup nomount pfile='C:\TEMP\initDBGRIDnew.ora'; -->restore the edited pfile
    Oracle instance started
    Total System Global Area     535662592 bytes
    Fixed Size 1375792 bytes
    Variable Size 327156176 bytes
    Database Buffers 192937984 bytes
    Redo Buffers 14192640 bytes
    RMAN> restore controlfile from 'D:\fra\backupsets\duplicate\autobackup\SAMSUNG-CTL_C-3578870300-20120801-00'; -->restore the correct controlfile
    Starting restore at 01-AUG-12
    using target database control file instead of recovery catalog
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=19 device type=DISK
    channel ORA_DISK_1: restoring control file
    channel ORA_DISK_1: restore complete, elapsed time: 00:00:07
    output file name=D:\ORADATA\DBGRID\CONTROL01.CTL
    output file name=D:\ORADATA\DBGRID\CONTROL02.CTL
    Finished restore at 01-AUG-12
    RMAN> alter database mount; -->mount the database
    database mounted
    released channel: ORA_DISK_1
    RMAN> catalog start with "D:\fra\backupsets\duplicate";
    --> catalog the location of the backup pieces to make it known to the control file
    Starting implicit crosscheck backup at 01-AUG-12
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=19 device type=DISK
    Crosschecked 3 objects
    Finished implicit crosscheck backup at 01-AUG-12
    Starting implicit crosscheck copy at 01-AUG-12
    using channel ORA_DISK_1
    Finished implicit crosscheck copy at 01-AUG-12
    searching for all files in the recovery area
    cataloging files...
    no files cataloged
    searching for all files that match the pattern D:\fra\backupsets\duplicate
    List of Files Unknown to the Database
    =====================================
    File Name: D:\FRA\BACKUPSETS\duplicate\autobackup\SAMSUNG-CTL_C-3578870300-20120801-00
    File Name: D:\FRA\BACKUPSETS\duplicate\level0\LEVEL0-GALAXY-20120801-01NHGTGV_1_1
    File Name: D:\FRA\BACKUPSETS\duplicate\level0\LEVEL0-GALAXY-20120801-02NHGTIA_1_1
    File Name: D:\FRA\BACKUPSETS\duplicate\level0\LEVEL0-GALAXY-20120801-03NHGTMT_1_1
    Do you really want to catalog the above files (enter YES or NO)? YES
    cataloging files...
    cataloging done
    List of Cataloged Files
    =======================
    File Name: D:\FRA\BACKUPSETS\duplicate\autobackup\SAMSUNG-CTL_C-3578870300-20120801-00
    File Name: D:\FRA\BACKUPSETS\duplicate\level0\LEVEL0-GALAXY-20120801-01NHGTGV_1_1
    File Name: D:\FRA\BACKUPSETS\duplicate\level0\LEVEL0-GALAXY-20120801-02NHGTIA_1_1
    File Name: D:\FRA\BACKUPSETS\duplicate\level0\LEVEL0-GALAXY-20120801-03NHGTMT_1_1
    RMAN> list backup summary; -->check your backup they are now known
    List of Backups
    ===============
    Key TY LV S Device Type Completion Time #Pieces #Copies Compressed Tag
    1 B  A  A DISK 01-AUG-12       1       2 NO         TAG20120801T011054
    2 B  0  A DISK 01-AUG-12       1       2 NO         TAG20120801T011137
    3 B  A  A DISK 01-AUG-12       1       2 NO         TAG20120801T011405
    RMAN> list archivelog all; -->list you archivelog for point in time recovery
    List of Archived Log Copies for database with db_unique_name GALAXY
    =====================================================================
    Key Thrd Seq     S Low Time
    26 1    29      A 01-AUG-12
    Name: D:\FRA\BACKUPSETS\ARCHS\ARC0000000029_0785167457.0001
    Perform database restoration and recovery. The sequence number is Seq+1 for complete recovery, so that will be 29 + 1 = 30. You can also do recovery via SCN or time based recovery.
    Remember in the previous step: RMAN> REPORT SCHEMA;
    Each datafile has a corresponding datafile number.
    Follow the format to convert them into their respective new restoration directory in the target server.
    SET NEWNAME has the format:
    SET NEWNAME FOR DATAFILE [FILE NUMBER IN THE REPORT SCHEMA COMMAND] TO
    ‘[NEW LOCATION AND FILENAME OF THE DATAFILES]’;
    RMAN> run {
    2> SET UNTIL SEQUENCE 30 THREAD 1;
    3> set newname for datafile 1 to 'D:\oradbgrid\oradata\SYSTEM01.DBF';
    4> set newname for datafile 2 to 'D:\oradbgrid\oradata\SYSAUX01.DBF';
    5> set newname for datafile 3 to 'D:\oradbgrid\oradata\UNDOTBS01.DBF';
    6> set newname for datafile 4 to 'D:\oradbgrid\oradata\USERS01.DBF';
    7> set newname for datafile 5 to 'D:\oradbgrid\oradata\EXAMPLE01.DBF';
    8> set newname for datafile 6 to 'D:\oradbgrid\oradata\ALLINDEX01.DBF';
    9> restore database;
    10> switch datafile all;
    11> recover database;
    12> }
    executing command: SET until clause
    executing command: SET NEWNAME
    executing command: SET NEWNAME
    executing command: SET NEWNAME
    executing command: SET NEWNAME
    executing command: SET NEWNAME
    executing command: SET NEWNAME
    Starting restore at 01-AUG-12
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: SID=19 device type=DISK
    channel ORA_DISK_1: starting datafile backup set restore
    channel ORA_DISK_1: specifying datafile(s) to restore from backup set
    channel ORA_DISK_1: restoring datafile 00001 to D:\oradbgrid\oradata\SYSTEM01.DBF
    channel ORA_DISK_1: restoring datafile 00002 to D:\oradbgrid\oradata\SYSAUX01.DBF
    channel ORA_DISK_1: restoring datafile 00003 to D:\oradbgrid\oradata\UNDOTBS01.DBF
    channel ORA_DISK_1: restoring datafile 00004 to D:\oradbgrid\oradata\USERS01.DBF
    channel ORA_DISK_1: restoring datafile 00005 to D:\oradbgrid\oradata\EXAMPLE01.DBF
    channel ORA_DISK_1: restoring datafile 00006 to D:\oradbgrid\oradata\ALLINDEX01.DBF
    channel ORA_DISK_1: reading from backup piece D:\FRA\BACKUPSETS\DUPLICATE\LEVEL0\LEVEL0-GALAXY-20120801-02NHGTIA_1_1
    channel ORA_DISK_1: piece handle=D:\FRA\BACKUPSETS\DUPLICATE\LEVEL0\LEVEL0-GALAXY-20120801-02NHGTIA_1_1 tag=TAG20120801T011137
    channel ORA_DISK_1: restored backup piece 1
    channel ORA_DISK_1: restore complete, elapsed time: 00:02:06
    Finished restore at 01-AUG-12
    Starting recover at 01-AUG-12
    using channel ORA_DISK_1
    starting media recovery
    archived log for thread 1 with sequence 29 is already on disk as file D:\FRA\BACKUPSETS\ARCHS\ARC0000000029_0785167457.0001
    archived log file name=D:\FRA\BACKUPSETS\ARCHS\ARC0000000029_0785167457.0001 thread=1 sequence=29
    media recovery complete, elapsed time: 00:00:01
    Finished recover at 01-AUG-12
    Log in to SQL*Plus to recreate the redolog files.
    Format:
    ALTER DATABASE RENAME FILE ‘[OLD REDOLOG LOCATION]’ TO ‘[NEW REDOLOG LOCATION]’;
    C:\Users\Administrator>sqlplus "/ as sysdba"
    SQL*Plus: Release 11.2.0.1.0 Production on Wed Aug 1 08:54:27 2012
    Copyright (c) 1982, 2010, Oracle.  All rights reserved.
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> select instance_name, status from v$instance;
    INSTANCE_NAME STATUS
    dbgrid MOUNTED
    SQL> ALTER DATABASE RENAME FILE 'C:\ORACLE\ORADATA\GALAXY\REDO03A.LOG' TO 'C:\oracle\oradata\dbgrid\REDO03A.LOG';
    Database altered.
    SQL> ALTER DATABASE RENAME FILE 'C:\ORACLE\ORADATA\GALAXY\REDO03B.LOG' TO 'C:\oracle\oradata\dbgrid\REDO03B.LOG';
    Database altered.
    SQL> ALTER DATABASE RENAME FILE 'C:\ORACLE\ORADATA\GALAXY\REDO02A.LOG' TO 'C:\oracle\oradata\dbgrid\REDO02A.LOG';
    Database altered.
    SQL> ALTER DATABASE RENAME FILE 'C:\ORACLE\ORADATA\GALAXY\REDO02B.LOG' TO 'C:\oracle\oradata\dbgrid\REDO02B.LOG';
    Database altered.
    SQL> ALTER DATABASE RENAME FILE 'C:\ORACLE\ORADATA\GALAXY\REDO01A.LOG' TO 'C:\oracle\oradata\dbgrid\REDO01A.LOG';
    Database altered.
    SQL> ALTER DATABASE RENAME FILE 'C:\ORACLE\ORADATA\GALAXY\REDO01B.LOG' TO 'C:\oracle\oradata\dbgrid\REDO01B.LOG';
    Database altered.
    Open the database in resetlogs option. Create spfile from the edited pfile then bounce the database.
    RMAN> alter database open resetlogs;
    database opened
    SQL> create spfile from pfile='C:\TEMP\initDBGRIDnew.ora';
    File created.
    SQL> shutdown immediate
    Database closed.
    Database dismounted.
    ORACLE instance shut down.
    SQL> startup
    ORACLE instance started.
    Total System Global Area  535662592 bytes
    Fixed Size 1375792 bytes
    Variable Size 327156176 bytes
    Database Buffers 192937984 bytes
    Redo Buffers 14192640 bytes
    Database mounted.
    Database opened.
    SQL> select instance_name, status from v$instance;
    INSTANCE_NAME STATUS
    dbgrid OPEN
    Create a new TEMP tablespace, make this as the new default temporary tablespace. Drop the old TEMP tablespace. Restart the database.
    SQL> CREATE TEMPORARY TABLESPACE TEMP01 TEMPFILE 'D:\oradbgrid\oradata\TEMP0101.dbf' SIZE 200M;
    Tablespace created.
    SQL> ALTER DATABASE DEFAULT TEMPORARY TABLESPACE TEMP01;
    Database altered.
    SQL> drop tablespace TEMP including contents and datafiles;
    Tablespace dropped.
    SQL> shutdown immediate
    Database closed.
    Database dismounted.
    ORACLE instance shut down.
    SQL> startup mount;
    ORACLE instance sta

  • APEX Application accessing data from two different databases

    Hi All,
    Currently as we all know that APEX Application resides in database and is connected to the schema of that database.
    I want APEX Application to be running and accessing data from two different databases. Elaborating my question,
    Currently, my APEX Production Application is connected with XXXX Schema of DB1 Database(Where APEX Resides). Now I want to add some pages into this APEX Application for REPORT Purpose, But I want to connect this REPORT APEX Pages to get data from Different Schema YYYY for Database DB2.
    Is it possible to configure this scenario?
    The reason for doing this is to avoid the REPORT related (adhoc queries) resource utilization effect on Production DB1 Database.
    Thanks
    Nil

    1. If you do the joining of two or more tables in DB1 then all data is pulled over to DB1 and then the join is executed: so more data over the databaselink and more work for DB1. Better keep the joining stuff where the data resides and just pull exactly that data over that you need.
    2. Don't know about your different block sizes. Seems a nice question for one of the other forums (DBA or SQL).
    3. I mean create synonyms on DB1 for reports VIEWS in DB2.
    Hope all is clear!

  • Table transformation from two different database

    Hi all,
    I am trying to load table from one database table to another database table in ODI 10g.I have created two physical and logical topology.
    But when in interface design i have drag the source and target tables in the diagram window, but here it doesnot shows the auto mapping options, when i try it manually by dragging a field, i have failed. when i execute the operation the following error occured:
    create or replace view db1."C$_0 W_INT_ORG_D"
    as select     
    from     db1.W_INT_ORG_DS W_INT_ORG_DS
    where     (1=1)
    here both the source and target db are same..
    How can i resolve it

    Hi,
    Thanks it worked.
    I am getting another error on Insert flow into I$ table step.
    I am connecting two database from two different hosts, both are in oracle.
    I have two logical schema prepared for both database.
    should i have to mentioned these schema in one physical topology? what should be placed in schema and work schema option.
    I have used LKM Oracle to Oracle(DBLINK) as KM.
    Please help
    Best regards,
    manish

  • How to restore a database backup taken from a SQL Server 2012 instance to SQL Server 2014

    I am trying to restore a database backup taken from a SQL Server 2012 instance to my new SQL Server 2014 instance.  When I add the .bak through the Mgmt studio UI, it does not seem to find a backup set in the file so I cannot proceed (does not give
    me any errors though either.  I tried restoring through TSQL command but only got a database restore terminating abnormally error with no other details.  How can I restore this database to SQL 2014?

    Hello,
    Please examine SQL Server Error Log and share with us any error you can find. The following article may locate the log:
    http://msdn.microsoft.com/en-us/library/ms187109.aspx
    Regards,
    Alberto Morillo
    SQLCoffee.com

  • Restored standby database from primary; now no logs are shipped

    Hi
    We recently had a major network/SAN issue and had to restore our standby database from a backup of the primary. To do this, we restored the database to the standby, created a standby controlfile on the primary, copied this across to the control file locations and started in standby recover and applied the logs manually/registered to get it back up to speed.
    However, no new logs are being shipped across from the primary.
    Have we missed a step somewhere?
    One thing we've noticed is that there is no RFS process running on the standby:
    SQL> SELECT PROCESS, CLIENT_PROCESS, SEQUENCE#, STATUS FROM V$MANAGED_STANDBY;
    PROCESS CLIENT_P SEQUENCE# STATUS
    ARCH ARCH 0 CONNECTED
    ARCH ARCH 0 CONNECTED
    MRP0 N/A 100057 WAIT_FOR_LOG
    How do we start this? Or will it only show if the arc1 process on the primary is sending files?
    The arc1 process is showing at OS level on the primary but I'm wondering if its faulty somehow?
    There are NO errors in the alert logs in the primary or the standby. There's not even the normal FAL gap sequence type error - in the standby it's just saying 'waiting for log' and a number from ages ago. It's like the primary isn't even talking to the standby. The listener is up and running ok though...
    What else can we check/do?
    If we manually copy across files and do an 'alter database register' then they are applied to the standby without issue; there's just no automatic log shipping going on...
    Thanks
    Ross

    Hi all
    Many thanks for all the responses.
    The database is 10.2.0.2.0, on AIX 6.
    I believe the password files are ok; we've had issues previously and this is always flagged in the alert log on the primary - not the case here.
    Not set to DEFER on primary; log_archive_dest_2 is set to service="STBY_PHP" optional delay=720 reopen=30 and log_archive_dest_state_2 is set to ENABLE.
    I ran those troubleshooting scripts, info from standby:
    SQL> @troubleshoot
    NAME DISPLAY_VALUE
    db_file_name_convert
    db_name PHP
    db_unique_name PHP
    dg_broker_config_file1 /oracle/PHP/102_64/dbs/dr1PHP.dat
    dg_broker_config_file2 /oracle/PHP/102_64/dbs/dr2PHP.dat
    dg_broker_start FALSE
    fal_client STBY_PHP
    fal_server PHP
    local_listener
    log_archive_config
    log_archive_dest_2 service=STBY_PHP optional delay=30 reopen=30
    log_archive_dest_state_2 DEFER
    log_archive_max_processes 2
    log_file_name_convert
    remote_login_passwordfile EXCLUSIVE
    standby_archive_dest /oracle/PHP/oraarch/PHParch
    standby_file_management AUTO
    NAME DB_UNIQUE_NAME PROTECTION_MODE DATABASE_R OPEN_MODE
    PHP PHP MAXIMUM PERFORM PHYSICAL S MOUNTED
    ANCE TANDBY
    THREAD# MAX(SEQUENCE#)
    1 100149
    PROCESS STATUS THREAD# SEQUENCE#
    ARCH CONNECTED 0 0
    ARCH CONNECTED 0 0
    MRP0 WAIT_FOR_LOG 1 100150
    NAME VALUE UNIT TIME_COMPUTED
    apply finish time day(2) to second(1) interval
    apply lag day(2) to second(0) interval
    estimated startup time 8 second
    standby has been open N
    transport lag day(2) to second(0) interval
    NAME Size MB Used MB
    0 0
    On the primary, the script has froze!! How long should it take? Got as far as this:
    SQL> @troubleshoot
    NAME DISPLAY_VALUE
    db_file_name_convert
    db_name PHP
    db_unique_name PHP
    dg_broker_config_file1 /oracle/PHP/102_64/dbs/dr1PHP.dat
    dg_broker_config_file2 /oracle/PHP/102_64/dbs/dr2PHP.dat
    dg_broker_start FALSE
    fal_client STBY_R1P
    fal_server R1P
    local_listener
    log_archive_config
    log_archive_dest_2 service="STBY_PHP" optional delay=720 reopen=30
    log_archive_dest_state_2 ENABLE
    log_archive_max_processes 2
    log_file_name_convert
    remote_login_passwordfile EXCLUSIVE
    standby_archive_dest /oracle/PHP/oraarch/PHParch
    standby_file_management AUTO
    NAME DB_UNIQUE_NAME PROTECTION_MODE DATABASE_R OPEN_MODE SWITCHOVER_STATUS
    PHP PHP MAXIMUM PERFORMANCE PRIMARY READ WRITE SESSIONS ACTIVE
    THREAD# MAX(SEQUENCE#)
    1 100206
    NOW - before you say it - :) - yes, I'm aware that fal_client as STBY_R1P and fal_server as R1P are incorrect - should be PHP - but it looks like it's always been this way! Well, as least for the last 4 years where it's worked fine, as I found an old SP file and it still has R1P set in there...?!?
    Any ideas?
    Ross

  • How to restore a database from host A to host B by using RMAN

    Hi there
    I wanted to restore 1 database from machine A to machine B with the differente files systemes. I did these steps below, but I have a problem when I restore the controlfile from machine A to machine B.
    1-copy the controlfile from machine A to machine B by using OS utility.
    2-startup nomount the database on machine B.
    3-connect target and catalog RMAN.
    4-I have to restore the controlfile from last full backup of the machine A to machine B (see the procedure RMAN).
    I have the error messages like:
    RMAN> connect target /
    RMAN-06006: connected to target database: dbtest (not mounted)
    RMAN> connect catalog rman/rman@rcattest
    RMAN-06008: connected to recovery catalog database
    RMAN> run {
    2> allocate channel c1 type 'sbt_tape' ;
    3> restore controlfile ;
    4> }
    RMAN-03022: compiling command: allocate
    RMAN-03023: executing command: allocate
    RMAN-08030: allocated channel: c1
    RMAN-08500: channel c1: sid=10 devtype=SBT_TAPE
    RMAN-08526: channel c1: VERITAS NetBackup for Oracle8 - Release 3.2GA
    RMAN-03022: compiling command: restore
    RMAN-03022: compiling command: IRESTORE
    RMAN-03023: executing command: IRESTORE
    RMAN-08016: channel c1: starting datafile backupset restore
    RMAN-08502: set_count=177 set_stamp=419449530 creation_time=19-JAN-01
    RMAN-08021: channel c1: restoring controlfile
    RMAN-08505: output filename=/db/oracle/dbtest/dbtestcontrol01.ctl
    RMAN-03026: error recovery releasing channel resources
    RMAN-08031: released channel: c1
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure during compilation of command
    RMAN-03013: command type: restore
    RMAN-03007: retryable error occurred during execution of command: IRESTORE
    RMAN-07004: unhandled exception during command execution on channel c1
    RMAN-10035: exception raised in RPC: ORA-19507: failed to retrieve sequential file, handle="5hcg0ilq_1_1", parms=""
    ORA-27029: skgfrtrv: sbtrestore returned error
    ORA-19511: sbtrestore: Backup file not found.
    RMAN-10031: ORA-19624 occurred during call to DBMS_BACKUP_RESTORE.RESTOREBACKUPPIE
    null

    Hi there
    I'm also trying to restore a full RMAN backup to our DR site using Netbackup as MML
    My scenario is:
    We have one tape library at our PROD data center and another one at our DR site both using Netbackup as Storage manager
    I performed a full RMAN backup on 4 DLT tapes with recovery catalog at our PROD datacenter, then I removed the 4 tapes and place it in our tape lib at DR site
    I tried to import the tapes using bpimport from Netbackup which has been successful up to now
    But when I tried to restore controlfile from RMAN, I get the following error:
    connected to target database: prod (not mounted)
    connected to recovery catalog database
    RMAN> run {
    2> allocate channel c1 type 'SBT_TAPE';
    3> allocate channel c2 type 'SBT_TAPE';
    4> allocate channel c3 type 'SBT_TAPE';
    5> allocate channel c4 type 'SBT_TAPE';
    6> set until time '16-AUG-2005 15:00:00';
    7> restore controlfile;
    8> }
    allocated channel: c1
    channel c1: sid=13 devtype=SBT_TAPE
    channel c1: VERITAS NetBackup for Oracle - Release 5.0GA (2003103005)
    allocated channel: c2
    channel c2: sid=12 devtype=SBT_TAPE
    channel c2: VERITAS NetBackup for Oracle - Release 5.0GA (2003103005)
    allocated channel: c3
    channel c3: sid=11 devtype=SBT_TAPE
    channel c3: VERITAS NetBackup for Oracle - Release 5.0GA (2003103005)
    allocated channel: c4
    channel c4: sid=9 devtype=SBT_TAPE
    channel c4: VERITAS NetBackup for Oracle - Release 5.0GA (2003103005)
    executing command: SET until clause
    Starting restore at 18-AUG-2005:10:28:23
    channel c1: starting datafile backupset restore
    channel c1: restoring controlfile
    output filename=/oracle9i/dba/dbs/control01_drprod.ctl
    released channel: c1
    released channel: c2
    released channel: c3
    released channel: c4
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of restore command at 08/18/2005 10:28:25
    ORA-19507: failed to retrieve sequential file, handle="df_t566491965_s8860_p1", parms=""
    ORA-27029: skgfrtrv: sbtrestore returned error
    ORA-19511: Error received from media manager layer, error text:
    Failed to process backup file <df_t566491965_s8860_p1>
    Anyone mastering this, please help !!
    thks
    BL

  • Query to compare 2 different tables from 2 different database

    Is it possible to write a SQL query to compare 2 Tables from 2 different Oracle Database. Also I need a query to do the same when the database is same.
    Thanks in advance

    OK, well "compare" can mean one of two things: Compare structure or compare contents. Here is a quick script to compare column structures of two tables on one database:
    (select COLUMN_NAME,
    DATA_TYPE,
    DATA_LENGTH,
    DATA_PRECISION,
    DATA_SCALE,
    NULLABLE
    from dba_Tab_columns
    where owner=:OWNR1
    and table_name = :tablename
    minus
    select COLUMN_NAME,
    DATA_TYPE,
    DATA_LENGTH,
    DATA_PRECISION,
    DATA_SCALE,
    NULLABLE
    from dba_Tab_columns
    where owner=:ownr2
    and table_name = :tablename)
    union all
    (select COLUMN_NAME,
    DATA_TYPE,
    DATA_LENGTH,
    DATA_PRECISION,
    DATA_SCALE,
    NULLABLE
    from dba_Tab_columns
    where owner=:ownr2
    and table_name = :tablename
    minus
    select COLUMN_NAME,
    DATA_TYPE,
    DATA_LENGTH,
    DATA_PRECISION,
    DATA_SCALE,
    NULLABLE
    from dba_Tab_columns
    where owner=:ownr1
    and table_name = :tablename)
    If this query returns any rows, then these indicate that there are structural differences between the tables. We do a minus in both directions to ensure that an additional column in either schema will be returned in the query.
    If you are going across dblinks to remote tables then you have to amend the "dba_tab_columns" to "sys.dba_tab_columns@yourdblink"
    If you also want to compare indexes, triggers, etc then do the same sort of thing for the associated dba_ views for those objects.
    And if you want to compare table contents, then often the fastest way is also to check minuses in both directions, if the tables are not too big:
    e.g.
    (select * from schema1.table@dblink1
    minus
    select * from schema2.table@dblink2)
    union all
    (select * from schema2.table@dblink2
    minus
    select * from schema1.table@dblink1)
    local tables, of course, simply omit the "@dblink" issues.
    There are tools to help in such things. TOAD, for example, has a pretty good schema comparison tool, and there are plenty of other options out there. But if you need to script this yourself then the logic I've shown is a good starting point.
    Cheers,
    Mike

  • Problem with restoring a database from cold backup

    All,
    I've got a 10.2.0.4 database that we perform a cold backup on every night with RMAN. On Sunday 2/21, we have level 0 backup. On Monday-Wednesday nights, we take a cold level 1. We also perform a controlfile auto backup each night.
    On a second server where I want to restore the database (same version of Oracle 10.2.0.4), I've copied the control file auto backups, the level 0 and the most recent level 1. I now want to restore. I use an RMAN script similar to the following to restore the control files:
    connect target /;
    set dbid 1973354860;
    # Restore the controlfile from the tag that auto backed up the controlfile at the end of the level 0
    run
    startup nomount;
    allocate channel c1 type disk;
    restore controlfile to '/u01/app/oracle/oradata/ORADB1/control01.ctl' from AUTOBACKUP;
    restore controlfile to '/u02/app/oracle/oradata/ORADB1/control02.ctl' from AUTOBACKUP;
    restore controlfile to '/u03/app/oracle/oradata/ORADB1/control03.ctl' from AUTOBACKUP;
    release channel c1;
    shutdown immediate;
    After the control files restore successfully, I perform some RMAN checks to ensure that all of the files I need for a recovery are there. The RMAN> list backup of database; command shows all of my backup savesets as AVAILABLE for the level0 and level1 backups.
    I then try a restore database command; and get the following errors:
    RMAN> run
    2> {
    3> allocate channel c1 type disk;
    4> allocate channel c2 type disk;
    5> allocate channel c3 type disk;
    6> allocate channel c4 type disk;
    7> restore database from tag='TAG20100221T200045';
    8> }
    using target database control file instead of recovery catalog
    allocated channel: c1
    channel c1: sid=74 devtype=DISK
    allocated channel: c2
    channel c2: sid=70 devtype=DISK
    allocated channel: c3
    channel c3: sid=166 devtype=DISK
    allocated channel: c4
    channel c4: sid=168 devtype=DISK
    Starting restore at 25-FEB-10
    released channel: c1
    released channel: c2
    released channel: c3
    released channel: c4
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of restore command at 02/25/2010 13:33:19
    RMAN-06026: some targets not found - aborting restore
    RMAN-06023: no backup or copy of datafile 44 found to restore
    RMAN-06023: no backup or copy of datafile 43 found to restore
    RMAN-06023: no backup or copy of datafile 42 found to restore
    RMAN-06023: no backup or copy of datafile 40 found to restore
    RMAN-06023: no backup or copy of datafile 39 found to restore
    RMAN-06023: no backup or copy of datafile 38 found to restore
    RMAN-06023: no backup or copy of datafile 37 found to restore
    RMAN-06023: no backup or copy of datafile 36 found to restore
    RMAN-06023: no backup or copy of datafile 35 found to restore
    RMAN-06023: no backup or copy of datafile 34 found to restore
    RMAN-06023: no backup or copy of datafile 33 found to restore
    RMAN-06023: no backup or copy of datafile 32 found to restore
    RMAN-06023: no backup or copy of datafile 31 found to restore
    RMAN-06023: no backup or copy of datafile 30 found to restore
    RMAN-06023: no backup or copy of datafile 29 found to restore
    RMAN-06023: no backup or copy of datafile 28 found to restore
    RMAN-06023: no backup or copy of datafile 27 found to restore
    RMAN-06023: no backup or copy of datafile 26 found to restore
    RMAN-06023: no backup or copy of datafile 25 found to restore
    RMAN-06023: no backup or copy of datafile 24 found to restore
    RMAN-06023: no backup or copy of datafile 23 found to restore
    RMAN-06023: no backup or copy of datafile 22 found to restore
    RMAN-06023: no backup or copy of datafile 21 found to restore
    RMAN-06023: no backup or copy of datafile 20 found to restore
    RMAN-06023: no backup or copy of datafile 19 found to restore
    RMAN-06023: no backup or copy of datafile 18 found to restore
    RMAN-06023: no backup or copy of datafile 17 found to restore
    RMAN-06023: no backup or copy of datafile 16 found to restore
    RMAN-06023: no backup or copy of datafile 15 found to restore
    RMAN-06023: no backup or copy of datafile 14 found to restore
    RMAN-06023: no backup or copy of datafile 13 found to restore
    RMAN-06023: no backup or copy of datafile 12 found to restore
    RMAN-06023: no backup or copy of datafile 11 found to restore
    RMAN-06023: no backup or copy of datafile 10 found to restore
    RMAN-06023: no backup or copy of datafile 9 found to restore
    RMAN-06023: no backup or copy of datafile 8 found to restore
    RMAN-06023: no backup or copy of datafile 7 found to restore
    RMAN-06023: no backup or copy of datafile 6 found to restore
    RMAN-06023: no backup or copy of datafile 5 found to restore
    RMAN-06023: no backup or copy of datafile 4 found to restore
    RMAN-06023: no backup or copy of datafile 3 found to restore
    RMAN-06023: no backup or copy of datafile 2 found to restore
    RMAN-06023: no backup or copy of datafile 1 found to restore
    RMAN>
    But I know from the RMAN crosscheck and list backup commands that the savesets are available on disk. For example:
    RMAN> list backup of datafile 1;
    List of Backup Sets
    ===================
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4875 Incr 0 4.37G DISK 00:22:53 21-FEB-10
    BP Key: 4875 Status: AVAILABLE Compressed: YES Tag: TAG20100221T200045
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4929_piece_1_date_20100221_711578185
    List of Datafiles in backup set 4875
    File LV Type Ckp SCN Ckp Time Name
    1 0 Incr 5086110241948 21-FEB-10 /u01/app/oracle/oradata/ORADB1/system01.dbf
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4894 Incr 1 1.92G DISK 00:13:46 24-FEB-10
    BP Key: 4894 Status: AVAILABLE Compressed: YES Tag: TAG20100224T200037
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4949_piece_1_date_20100224_711836434
    List of Datafiles in backup set 4894
    File LV Type Ckp SCN Ckp Time Name
    1 1 Incr 5086113791743 24-FEB-10 /u01/app/oracle/oradata/ORADB1/system01.dbf
    RMAN> list backup of datafile 44; (the first one in the list above)
    List of Backup Sets
    ===================
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4872 Incr 0 7.15G DISK 00:35:17 21-FEB-10
    BP Key: 4872 Status: AVAILABLE Compressed: YES Tag: TAG20100221T200045
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4927_piece_1_date_20100221_711576046
    List of Datafiles in backup set 4872
    File LV Type Ckp SCN Ckp Time Name
    44 0 Incr 5086110241948 21-FEB-10 /u04/app/oracle/oradata/ORADB1/NETINSIGHT_INDEXES_03.dbf
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4893 Incr 1 4.06G DISK 00:26:52 24-FEB-10
    BP Key: 4893 Status: AVAILABLE Compressed: YES Tag: TAG20100224T200037
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4947_piece_1_date_20100224_711835238
    List of Datafiles in backup set 4893
    File LV Type Ckp SCN Ckp Time Name
    44 1 Incr 5086113791743 24-FEB-10 /u04/app/oracle/oradata/ORADB1/NETINSIGHT_INDEXES_03.dbf
    As you can see, the level 0 and level 1 backups are showing as available. To double check, I perform a crosscheck backup of database;
    RMAN> crosscheck backup of database;
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: sid=74 devtype=DISK
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4927_piece_1_date_20100221_711576046 recid=4872 stamp=711576046
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4928_piece_1_date_20100221_711576046 recid=4873 stamp=711576046
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4930_piece_1_date_20100221_711578189 recid=4874 stamp=711578189
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4929_piece_1_date_20100221_711578185 recid=4875 stamp=711578186
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4932_piece_1_date_20100221_711579570 recid=4876 stamp=711579570
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4931_piece_1_date_20100221_711579392 recid=4877 stamp=711579393
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4934_piece_1_date_20100221_711580369 recid=4878 stamp=711580370
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4935_piece_1_date_20100221_711580535 recid=4879 stamp=711580535
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4933_piece_1_date_20100221_711580122 recid=4880 stamp=711580123
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4948_piece_1_date_20100224_711835237 recid=4892 stamp=711835238
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4947_piece_1_date_20100224_711835238 recid=4893 stamp=711835238
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4949_piece_1_date_20100224_711836434 recid=4894 stamp=711836436
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4950_piece_1_date_20100224_711836866 recid=4895 stamp=711836866
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4951_piece_1_date_20100224_711837267 recid=4896 stamp=711837268
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4952_piece_1_date_20100224_711837971 recid=4897 stamp=711837972
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4953_piece_1_date_20100224_711837989 recid=4898 stamp=711837989
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4955_piece_1_date_20100224_711838522 recid=4899 stamp=711838522
    crosschecked backup piece: found to be 'AVAILABLE'
    backup piece handle=/u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4954_piece_1_date_20100224_711838520 recid=4900 stamp=711838521
    Crosschecked 18 objects
    RMAN>
    So I'm unclear as to why RMAN believes the backups of these files don't exist when I attempt to restore the database. Anyone have a clue?
    NOTE: I've also tried to restore spcifically with the tag= clause but I get the same results:
    RMAN> restore database from tag='TAG20100221T200045';
    Starting restore at 25-FEB-10
    using channel ORA_DISK_1
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of restore command at 02/25/2010 13:41:04
    RMAN-06026: some targets not found - aborting restore
    RMAN-06023: no backup or copy of datafile 44 found to restore
    RMAN-06023: no backup or copy of datafile 43 found to restore
    RMAN-06023: no backup or copy of datafile 42 found to restore
    RMAN-06023: no backup or copy of datafile 40 found to restore
    RMAN-06023: no backup or copy of datafile 39 found to restore
    RMAN-06023: no backup or copy of datafile 38 found to restore
    RMAN-06023: no backup or copy of datafile 37 found to restore
    RMAN-06023: no backup or copy of datafile 36 found to restore
    RMAN-06023: no backup or copy of datafile 35 found to restore
    RMAN-06023: no backup or copy of datafile 34 found to restore
    RMAN-06023: no backup or copy of datafile 33 found to restore
    RMAN-06023: no backup or copy of datafile 32 found to restore
    RMAN-06023: no backup or copy of datafile 31 found to restore
    RMAN-06023: no backup or copy of datafile 30 found to restore
    RMAN-06023: no backup or copy of datafile 29 found to restore
    RMAN-06023: no backup or copy of datafile 28 found to restore
    RMAN-06023: no backup or copy of datafile 27 found to restore
    RMAN-06023: no backup or copy of datafile 26 found to restore
    RMAN-06023: no backup or copy of datafile 25 found to restore
    RMAN-06023: no backup or copy of datafile 24 found to restore
    RMAN-06023: no backup or copy of datafile 23 found to restore
    RMAN-06023: no backup or copy of datafile 22 found to restore
    RMAN-06023: no backup or copy of datafile 21 found to restore
    RMAN-06023: no backup or copy of datafile 20 found to restore
    RMAN-06023: no backup or copy of datafile 19 found to restore
    RMAN-06023: no backup or copy of datafile 18 found to restore
    RMAN-06023: no backup or copy of datafile 17 found to restore
    RMAN-06023: no backup or copy of datafile 16 found to restore
    RMAN-06023: no backup or copy of datafile 15 found to restore
    RMAN-06023: no backup or copy of datafile 14 found to restore
    RMAN-06023: no backup or copy of datafile 13 found to restore
    RMAN-06023: no backup or copy of datafile 12 found to restore
    RMAN-06023: no backup or copy of datafile 11 found to restore
    RMAN-06023: no backup or copy of datafile 10 found to restore
    RMAN-06023: no backup or copy of datafile 9 found to restore
    RMAN-06023: no backup or copy of datafile 8 found to restore
    RMAN-06023: no backup or copy of datafile 7 found to restore
    RMAN-06023: no backup or copy of datafile 6 found to restore
    RMAN-06023: no backup or copy of datafile 5 found to restore
    RMAN-06023: no backup or copy of datafile 4 found to restore
    RMAN-06023: no backup or copy of datafile 3 found to restore
    RMAN-06023: no backup or copy of datafile 2 found to restore
    RMAN-06023: no backup or copy of datafile 1 found to restore

    Just as a follow on to my last post, after the RMAN-06023 messages, I list backups of the three datafiles and as you can see RMAN thinks that they are available. If I exit RMAN and list them at the OS level, they are where RMAN things they should be:
    RMAN> restore database;
    Starting restore at 25-FEB-10
    using channel ORA_DISK_1
    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-03002: failure of restore command at 02/25/2010 16:17:39
    RMAN-06026: some targets not found - aborting restore
    RMAN-06023: no backup or copy of datafile 4 found to restore
    RMAN-06023: no backup or copy of datafile 3 found to restore
    RMAN-06023: no backup or copy of datafile 1 found to restore
    RMAN> list backup of datafile 4;
    List of Backup Sets
    ===================
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4880 Incr 0 1.36G DISK 00:08:57 21-FEB-10
    BP Key: 4880 Status: AVAILABLE Compressed: YES Tag: TAG20100221T200045
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4933_piece_1_date_20100221_711580122
    List of Datafiles in backup set 4880
    File LV Type Ckp SCN Ckp Time Name
    4 0 Incr 5086110241948 21-FEB-10 /u02/app/oracle/oradata/ORADB1/users01.dbf
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4890 Incr 1 934.82M DISK 00:09:42 22-FEB-10
    BP Key: 4890 Status: AVAILABLE Compressed: YES Tag: TAG20100222T200047
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4943_piece_1_date_20100222_711664989
    List of Datafiles in backup set 4890
    File LV Type Ckp SCN Ckp Time Name
    4 1 Incr 5086111401249 22-FEB-10 /u02/app/oracle/oradata/ORADB1/users01.dbf
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4898 Incr 1 947.57M DISK 00:08:49 24-FEB-10
    BP Key: 4898 Status: AVAILABLE Compressed: YES Tag: TAG20100224T200037
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4953_piece_1_date_20100224_711837989
    List of Datafiles in backup set 4898
    File LV Type Ckp SCN Ckp Time Name
    4 1 Incr 5086113791743 24-FEB-10 /u02/app/oracle/oradata/ORADB1/users01.dbf
    RMAN>
    RMAN> list backup of datafile 3;
    List of Backup Sets
    ===================
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4874 Incr 0 2.65G DISK 00:19:50 21-FEB-10
    BP Key: 4874 Status: AVAILABLE Compressed: YES Tag: TAG20100221T200045
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4930_piece_1_date_20100221_711578189
    List of Datafiles in backup set 4874
    File LV Type Ckp SCN Ckp Time Name
    3 0 Incr 5086110241948 21-FEB-10 /u02/app/oracle/oradata/ORADB1/sysaux01.dbf
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4885 Incr 1 1.95G DISK 00:15:54 22-FEB-10
    BP Key: 4885 Status: AVAILABLE Compressed: YES Tag: TAG20100222T200047
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4940_piece_1_date_20100222_711663910
    List of Datafiles in backup set 4885
    File LV Type Ckp SCN Ckp Time Name
    3 1 Incr 5086111401249 22-FEB-10 /u02/app/oracle/oradata/ORADB1/sysaux01.dbf
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4895 Incr 1 1.97G DISK 00:18:13 24-FEB-10
    BP Key: 4895 Status: AVAILABLE Compressed: YES Tag: TAG20100224T200037
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4950_piece_1_date_20100224_711836866
    List of Datafiles in backup set 4895
    File LV Type Ckp SCN Ckp Time Name
    3 1 Incr 5086113791743 24-FEB-10 /u02/app/oracle/oradata/ORADB1/sysaux01.dbf
    RMAN>
    RMAN>
    RMAN> list backup of datafile 1;
    List of Backup Sets
    ===================
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4875 Incr 0 4.37G DISK 00:22:53 21-FEB-10
    BP Key: 4875 Status: AVAILABLE Compressed: YES Tag: TAG20100221T200045
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level0_set_4929_piece_1_date_20100221_711578185
    List of Datafiles in backup set 4875
    File LV Type Ckp SCN Ckp Time Name
    1 0 Incr 5086110241948 21-FEB-10 /u01/app/oracle/oradata/ORADB1/system01.dbf
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4884 Incr 1 1.93G DISK 00:12:34 22-FEB-10
    BP Key: 4884 Status: AVAILABLE Compressed: YES Tag: TAG20100222T200047
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4939_piece_1_date_20100222_711663601
    List of Datafiles in backup set 4884
    File LV Type Ckp SCN Ckp Time Name
    1 1 Incr 5086111401249 22-FEB-10 /u01/app/oracle/oradata/ORADB1/system01.dbf
    BS Key Type LV Size Device Type Elapsed Time Completion Time
    4894 Incr 1 1.92G DISK 00:13:46 24-FEB-10
    BP Key: 4894 Status: AVAILABLE Compressed: YES Tag: TAG20100224T200037
    Piece Name: /u03/oracle_backups/ORADB1/offline/ORADB1_level1_set_4949_piece_1_date_20100224_711836434
    List of Datafiles in backup set 4894
    File LV Type Ckp SCN Ckp Time Name
    1 1 Incr 5086113791743 24-FEB-10 /u01/app/oracle/oradata/ORADB1/system01.dbf
    RMAN> exit
    $ ls -ltr /u03/oracle_backups/ORADB1/offline
    total 59743688
    -rwx------ 1 oracle oinstall 7677960192 2010-02-25 11:13 ORADB1_level0_set_4927_piece_1_date_20100221_711576046
    -rwx------ 1 oracle oinstall 7980834816 2010-02-25 11:24 ORADB1_level0_set_4928_piece_1_date_20100221_711576046
    -rwx------ 1 oracle oinstall 4691853312 2010-02-25 11:29 ORADB1_level0_set_4929_piece_1_date_20100221_711578185
    -rwx------ 1 oracle oinstall 2847391744 2010-02-25 11:34 ORADB1_level0_set_4930_piece_1_date_20100221_711578189
    -rwx------ 1 oracle oinstall 3530924032 2010-02-25 11:39 ORADB1_level0_set_4931_piece_1_date_20100221_711579392
    -rwx------ 1 oracle oinstall 1566449664 2010-02-25 11:41 ORADB1_level0_set_4932_piece_1_date_20100221_711579570
    -rwx------ 1 oracle oinstall 1459781632 2010-02-25 11:43 ORADB1_level0_set_4933_piece_1_date_20100221_711580122
    -rwx------ 1 oracle oinstall 561774592 2010-02-25 11:44 ORADB1_level0_set_4934_piece_1_date_20100221_711580369
    -rwx------ 1 oracle oinstall 58753024 2010-02-25 11:44 ORADB1_level0_set_4935_piece_1_date_20100221_711580535
    -rwx------ 1 oracle oinstall 4364124160 2010-02-25 11:56 ORADB1_level1_set_4947_piece_1_date_20100224_711835238
    -rwx------ 1 oracle oinstall 2971877376 2010-02-25 12:01 ORADB1_level1_set_4948_piece_1_date_20100224_711835237
    -rwx------ 1 oracle oinstall 2066546688 2010-02-25 12:03 ORADB1_level1_set_4949_piece_1_date_20100224_711836434
    -rwx------ 1 oracle oinstall 2119360512 2010-02-25 12:06 ORADB1_level1_set_4950_piece_1_date_20100224_711836866
    -rwx------ 1 oracle oinstall 1003356160 2010-02-25 12:06 ORADB1_level1_set_4951_piece_1_date_20100224_711837267
    -rwx------ 1 oracle oinstall 1637105664 2010-02-25 12:08 ORADB1_level1_set_4952_piece_1_date_20100224_711837971
    -rwx------ 1 oracle oinstall 993607680 2010-02-25 12:08 ORADB1_level1_set_4953_piece_1_date_20100224_711837989
    -rwx------ 1 oracle oinstall 1130496 2010-02-25 12:09 ORADB1_level1_set_4955_piece_1_date_20100224_711838522
    -rwx------ 1 oracle oinstall 283344896 2010-02-25 12:09 ORADB1_level1_set_4954_piece_1_date_20100224_711838520
    -rwx------ 1 oracle oinstall 4344365056 2010-02-25 16:01 ORADB1_level1_set_4937_piece_1_date_20100222_711662448
    -rwx------ 1 oracle oinstall 2959015936 2010-02-25 16:05 ORADB1_level1_set_4938_piece_1_date_20100222_711662448
    -rwx------ 1 oracle oinstall 2067202048 2010-02-25 16:07 ORADB1_level1_set_4939_piece_1_date_20100222_711663601
    -rwx------ 1 oracle oinstall 2089304064 2010-02-25 16:08 ORADB1_level1_set_4940_piece_1_date_20100222_711663910
    -rwx------ 1 oracle oinstall 955711488 2010-02-25 16:09 ORADB1_level1_set_4941_piece_1_date_20100222_711664370
    -rwx------ 1 oracle oinstall 1623564288 2010-02-25 16:11 ORADB1_level1_set_4942_piece_1_date_20100222_711664872
    -rwx------ 1 oracle oinstall 980238336 2010-02-25 16:12 ORADB1_level1_set_4943_piece_1_date_20100222_711664989
    -rwx------ 1 oracle oinstall 280952832 2010-02-25 16:12 ORADB1_level1_set_4944_piece_1_date_20100222_711665385
    -rwx------ 1 oracle oinstall 1130496 2010-02-25 16:12 ORADB1_level1_set_4945_piece_1_date_20100222_711665521

  • Database restore to test from production

    Hi,
    I am having 500+ GB database running in AIX with ASM. creating disk backups using rman and moving to Test server.. i like to know the commands for restore and recovery from disk to ASM in test server:
    Prod server : ASM on AIX single instance
    rman database backup to disk (SID : PROD)
    ftp to test serverTest server: ASM on AIX single instance
    clean up exiting database (SID : TEST)
    rman restore and recover command from disk The rman command i am using for backup is :
    run
    allocate channel backup_disk1 type disk;
    allocate channel backup_disk2 type disk;
    allocate channel backup_disk3 type disk;
    sql "ALTER SYSTEM ARCHIVE LOG CURRENT";
    backup
    format='<path>/Sml_full_bck_%Y%M%D_%d_%s_%p.dbf'
    database
    plus archivelog
    filesperset=1;
    backup
    format='<path>/Tp_cntl_%Y%M%D_%d_%s_%p.ctl'
    current controlfile;
    #sql "alter system switch logfile";
    release channel backup_disk1;
    release channel backup_disk2;
    release channel backup_disk3;
    What would be ideal command for restore....

    we have some issues with network....need to ftp manually after taking backup..i am looking around for the restore command like
    run
    allocate channel t1 type disk;
    restore database from '/<path>' to '+DATA';
    recover database;
    release channel t1;
    just want some clarifications on syntax especially from disk backup restore to ASM disk groups and recover from there..

Maybe you are looking for

  • Why do we need a connection to the Source DB for RMAN DUPLICATE ?

    Version Info: 11.2.0.3/RHEL 5.8 We want to clone a Production DB to a test DB. Prod DB size: 100gb We are going to take an RMAN full backup (Hot Backup which includes Archivelogs ) and scp the backup pieces to the Test DB server. In the Test server ,

  • Calling the osb service from java

    Hi all, i am trying to invoke osb service at a remote host which is accessed with no proxy settings in the broswer I followed "code 2" in the below link to create the java client in the jdeveloper https://kr.forums.oracle.com/forums/thread.jspa?threa

  • Apple Mail DB with plenty of multiple messages

    Over the last year or so, I have noticed that my Apple Mail DB (currently version 7.3) is increasing in size at an alarming rate. Now it is almost 150 GB (!!!) and as you can imagine, it is almost unmanageable. However, I have noticed that every sing

  • Podcasts missing from Music Playlists

    Front Row playlists used to show the same tracks as iTunes playlists, but in Leopard, Front Row fails to show podcast episodes in playlists. I just installed iTunes 8.0 and Front Row 2.1.6 on OSX 10.5.5, and the problem persists. What is the best wor

  • Using an external editor (e.g., photoshop) with photos for mac

    Hi, I'm just trying out photos for mac. So far it seems to make life a lot easier in terms of syncing libraries. However, I have been using Lightroom 4 and photoshop before and I am missing out on some of their combined functionality (not much I have