Newbie ? - Recoverying Database

Hello-
I'm new to Oracle (using 9i) and am running into an issue that I'm hoping someone with more experience can take mercy on me and help me out with. =)
I'm been trying to clone and a production database for a test system and have finally been able to create and (I think) recover the test db.. now I need some assistance on moving forward. I shutdown the production db and copied the necessary files over to the test area; I start the Test db the following script (in a file named 'clone.sql'):
STARTUP NOMOUNT
CREATE CONTROLFILE SET DATABASE "DPRTEST" RESETLOGS NOARCHIVELOG
MAXLOGFILES 32
MAXLOGMEMBERS 2
MAXDATAFILES 254
MAXINSTANCES 8
MAXLOGHISTORY 907
LOGFILE
GROUP 1 (
'/ubc/test/redo/redo01.log'
) SIZE 500M,
GROUP 2 (
'/ubc/test/redo/redo02.log'
) SIZE 500M,
GROUP 3 (
'/ubc/test/redo/redo03.log'
) SIZE 500M
DATAFILE
'/ubc/test/other_sysadmin/xdb01.dbf',
'/ubc/test/other_sysadmin/users01.dbf',
'/ubc/test/other_sysadmin/tools01.dbf',
'/ubc/test/other_sysadmin/drsys01.dbf',
'/ubc/test/other_sysadmin/system01.dbf',
'/ubc/test/data/OLTP.dbf',
'/ubc/test/data/STAGING.DBF',
'/ubc/test/other_notused/SPOTLIGHT.DBF',
'/ubc/test/other_notused/DATACAPTURE.DBF',
'/ubc/test/other_notused/ARCHIVE.DBF',
'/ubc/test/other_notused/STATSPACK.DBF',
'/ubc/test/other_notused/DATACAPTUREINDEX.DBF',
'/ubc/test/indexes/OLTPINDEX.DBF',
'/ubc/test/indexes/STAGINGINDEX.DBF',
'/ubc/test/indexes/indx01.dbf'
CHARACTER SET US7ASCII
I then run the following 'RECOVER' command, that tells me that the 'RECOVER' succeeded:
SQL> @/ubc/test/clone.sql
ORACLE instance started.
Total System Global Area 1502242576 bytes
Fixed Size 743184 bytes
Variable Size 452984832 bytes
Database Buffers 1048207360 bytes
Redo Buffers 307200 bytes
Control file created.
SQL> recover database using backup controlfile until cancel;
ORA-00279: change 1406125902 generated at 04/27/2007 07:48:24 needed for thread 1
ORA-00289: suggestion : /ubc/oracle/OraHome1/dbs/arch1_1.dbf
ORA-00280: change 1406125902 for thread 1 is in sequence #1
Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
/ubc/test/other_notused/ARCHIVE.DBF
ORA-00317: file type 8192 in header is not log file
ORA-00334: archived log: '/ubc/test/other_notused/ARCHIVE.DBF'
ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below
ORA-01194: file 1 needs more recovery to be consistent
ORA-01110: data file 1: '/ubc/test/other_sysadmin/system01.dbf'
SQL>
Question 1: Do I need to address following message? And if yes, how?: ORA-00317: file type 8192 in header is not log file
Question 2: How should I address the following?: My next command would be 'ALTER DATABASE OPEN RESETLOGS;', however, the warning output above tells me:
'ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below
ORA-01194: file 1 needs more recovery to be consistent
ORA-01110: data file 1: '/ubc/test/other_sysadmin/system01.dbf''
Thanks in advance for your help and assistance. It is VERY much appreciated!
-JG

Yes, they are. I started this just before noon today, and when I look at the timestamps on the files, they are all May 01 11:49 (like I said, I copied them this weekend, so I know that the timestamp is correct).
When I made that statement about being in sync, I was referring to our production and test db's - sorry for the confusion.
When I run the RESETLOGS statement I get the following:
SQL> ALTER DATABASE OPEN RESETLOGS;
ALTER DATABASE OPEN RESETLOGS
ERROR at line 1:
ORA-01194: file 1 needs more recovery to be consistent
ORA-01110: data file 1: '/ubc/test/other_sysadmin/system01.dbf'
SQL>
Thanks for your time and help!
-JG

Similar Messages

  • How to replicate CDC on Disaster Recovery Database.

    I have a scenario here.
    In Case you have CDC installed on your main database. The changes are getting captured and you get the changes in the subscriber views.
    In case your main database goes down due to some reasons. You cannot access even a single table of the database now you are to take an export dump to be taken to a different database.
    In this case there is a disaster recovery database, wherein the tables and the number of records is same as the main database, since it is refreshed every now and then.
    Is it possible to replicate the change tables with the archived log files present??
    The mode of operation of CDC is Asynchronous Hotlog mode.
    Please suggest the alternative for replicating CDC on a separate database, if one database is gone, without any miss in the changes.
    Regards,
    Uravesh Vora

    moz44 wrote:
    Hi guys, happy thanksgiving day to you all.
    Some people say that it is possible to replicate a derby database running on one host to mysql running on another host. Has any of you have experience with that?That wouldn't be quite the same as for example replication on Oracle to Oracle.
    But the following claims that it does what you want. No reason to suppose it doesn't. Look at the license carefully (I didn't look at it at all.) It basically supports any jdbc driver (two one for each source.)
    [http://enterprise.replicator.daffodilsw.com/]
    I would expect more problems with more complicated databases. But that is true with databases that have built in replication as well.

  • Get folders in a mailbox in recovery database

    Hi,
    I want to get a list of folders in a mailbox in the recovery database without restoring the mailbox.
    How can I achieve that?
    Thanks,
    Gagan
    Gagan

    Old thread, but relevant to what I need to do right now.
    FYI, Get-MailboxFolderStatistics does not have a
    -database parameter in Exchange 2010 or 2013. 
    Get-Mailbox -database returns no results from a recovery database.
    I'm still working on trying to figure this out, but I'm thinking it may not be possible.

  • Recovery data using Exchange Management Shell From Recovery Database

    Recently Some of our employees had been requesting a restore of some deleted emails from earlier in the year. Through our Backup Exec 2012 the recovery of the emails were not working. After 2 weeks on the phone with Symantec we determined that theyre Granular
    Recovery Technology was not functioning properly for whatever reasons. As a last resort we recovered the backup set to a recovery database and now need to use the management shell in Exchange in order to recover the emails. I am having trouble with the
    syntax and wanted to see if anyone out there could help me with the necessary commands in order to recover emails. forgive me if i have left out any required information. i am still a student trying to learn

    If you are interested in 3rd party products check out Lucid8's DigiScope
    http://www.lucid8.com/product/digiscope.asp
    which will allow you to open any offline Exchange Database within a familiar Outlook type GUI.  Once opened you can Browse, Search, Export Mailboxes, Folders and Individual Items to PST & MSG or Recover data directly to any Production Exchange
    server or mailbox.
    Regarding the RDB commands, here is a good article
    http://technet.microsoft.com/en-us/library/ee332351.aspx and also here are a couple of Examples
    NOTE:  The examples below assume that you have recovered the DB in question to the RDB and that a copy of the mailbox belonging to John_Doe is within the Recovery Database.
    A:  The command below will recover the mailbox called John_Doe from the Recovery Database called
    RecoveryDatabase1 to the John_Doe mailbox in the live database.  NOTE: This method relies on the original mailbox still being intact on the Production Server.
    Use the Exchange Management Shell and run the following command:
    Restore-Mailbox -Identity John_Doe -Recovery Database RecoveryDatabase1
    B:  You can also recover the John_Doe mailbox from the Recovery Database and place it into
    a folder called "John_Doe Recovery" within a mailbox called BobTheManager.
    Use the Exchange Management Shell and run the following command:
    Restore-Mailbox -Identity BobTheManager -RecoveryDatabase RecoveryDatabase1 -RecoveryMailbox John_Doe -TargetFolder “John_Doe Recovery"
    C: There is also the ability to search the mailbox content for keywords.  In this example we
    search for any messages containing the word “SecretStuff” and restore those items to a folder called “John_Doe recovery with SuperSecret text” within a mailbox called JaneSupervisor. 
    Use the Exchange Management Shell and run the following command:
    Restore-Mailbox -Identity JaneSupervisor -RecoveryDatabase RecoveryDatabase1 -RecoveryMailbox John_Doe -SubjectKeywords "SecretStuff"
    –TargetFolder “John_Doe recovery with SecretStuff"
    Troy Werelius
    www.Lucid8.com
    Search, Recover, & Extract Mailboxes, Folders, & Email Items from Offline EDB's and Live Exchange Servers with Lucid8's DigiScope

  • How the transactional replication work for simple recovery database (looking for some internal concept)

    How the transactional replication work for simple recovery database (looking for some internal concept)
    Rahul

    There seems to be a new myth going around recently. I’ve had at least three people tell me, in the last month, that SQL’s transactional replication requires the database to be in full recovery.
    This is complete fabrication. Replication (SQL native replication, that is) can work with the databases in any of the recovery models.
    Transactional replication does involve the transaction log, as that’s where it picks up changes from. The log reader scans over the transaction log looking for log records marked for replication, copies those to the distribution database and then marks them
    as replicated. When the checkpoint (for simple recovery) or log backup (for full or bulk logged) occur, the log will only be truncated up to the oldest inactive, replicated transaction.
    Because transactional replication has its own way of ensuring log records aren’t discarded before been picked up by the log reader, there’s no requirement for a specific recovery model.
    Refer this link
    http://sqlinthewild.co.za/index.php/2008/12/05/a-new-sql-myth/
    --Prashanth

  • How to recovery database

    Please help me in this:
    - database is oracle 9.2, arc log is off;
    - i have full copy of database 7.05.2009;
    - i have full dump of database 10.05.2009;
    - database is crash 10.05.2009;
    - i recovery database from full copy 7.05.2009;
    - What parametres of imp I should apply to restore base as of 10.05.2009 from full dump?
    full=y, ignore=y???

    To restore a database with imp/exp, you need first that he database is up and running.
    Try to restart instance with STARTUP command. If this does not work, you need to either restore database
    as described in my previous message or to recreate it (with DBCA or with the scripts that have been used at creation time).
    Then you can restore the database using the export full with imp command and the following options full=Y and ignore=Y (you will likely get some errors for SYSTEM objects that already exist and possibly with already existing tablespaces).
    Please post you Oracle version 4 digits and command used with Oracle output including error messages.
    Edited by: P. Forstmann on May 11, 2009 11:06 AM
    Edited by: P. Forstmann on May 11, 2009 11:07 AM

  • Issues with a recovery database

    Hello everyone,
    I am trying to restore a mailbox from a backed up copy of a db. The backup copy was restored into a recovery db. Everything looks fine, database is mounted, no issues are being reported. When I run the New-MailboxRestoreRequest to restore the mailbox, I
    get the following error message in the Event Viewer and it fails.
    FYI - I am using Exchange 2010.
    The Microsoft Exchange Mailbox Replication service was unable to process jobs in a mailbox database.
    Database: TEMPORARY
    Error: MapiExceptionRecoveryMDBMismatch: Unable to open message store. (hr=0x80004005, ec=1165)
    Diagnostic context:
        Lid: 55847   EMSMDBPOOL.EcPoolSessionDoRpc called [length=242]
        Lid: 43559   EMSMDBPOOL.EcPoolSessionDoRpc returned [ec=0x0][length=184][latency=0]
        Lid: 23226   --- ROP Parse Start ---
        Lid: 27962   ROP: ropLogon [254]
        Lid: 17082   ROP Error: 0x48D    
        Lid: 26937 
        Lid: 21921   StoreEc: 0x48D    
        Lid: 27962   ROP: ropExtendedError [250]
        Lid: 1494    ---- Remote Context Beg ----
        Lid: 26426   ROP: ropLogon [254]
        Lid: 45151 
        Lid: 33887   StoreEc: 0x48D    
        Lid: 17097   StoreEc: 0x48D    
        Lid: 8620    StoreEc: 0x48D    
        Lid: 1750    ---- Remote Context End ----
        Lid: 26849 
        Lid: 21817   ROP Failure: 0x48D    
        Lid: 26297 
        Lid: 16585   StoreEc: 0x48D    
        Lid: 32441 
        Lid: 1706    StoreEc: 0x48D    
        Lid: 24761 
        Lid: 20665   StoreEc: 0x48D    
        Lid: 25785 
        Lid: 29881   StoreEc: 0x48D    
    Can someone help me fix this issue? At first I thought it might have been the backup copy that was bad so I used a previous one but got the same result.
    Thanks
    Francois
    Francois S. at FMD

    Hi Francois,
    From the error description, I recommend you check the following things for troubleshooting:
    1. Please make sure that the Microsoft Exchange Mailbox Replication service is started. If no, please start it.
    2. Microsoft Exchange Mailbox Replication service is dependent upon the Microsoft Exchange Active Directory Topology and Net.Tcp Port Sharing service. Ensure that these two services are started.
    Hope my clarification is helpful.
    Best regards,
    Amy
    Amy Wang
    TechNet Community Support

  • Applying archivelogs to test disaster recovery database

    Database: 10.2.0.2
    OS: RHEL
    Goal: (1) To test the ability to rebuild a database using backupset and archivelogs.
    (2) To roll forward the test DR database by applying archivelogs from the production database.
    I am using rman but not a catalog.
    I restored and recovered the production database to a new, separate server, making a second database with the same DBID. I felt proud of myself for a moment.
    The production database now has archivelogs past the time of the backup that was restored and recovered to the test DR database. In a simulated production database failure, I want to apply those archivelogs to the DR database in order to roll forward the DR database to the point of failure in the production database. Everyone except me seems to know how to do this. I feel a lot less proud now.
    Yes I have read the rman manuals, all of them, and several times - yes, I have read through the forums and read asktom and metalink. I must be unintentionally overlooking some crucial info and concepts.
    My production database has generated archivelogs passed the last sequence known to my DR database. I don't know how to tell the DR database to recover these new archivelogs.
    Another post on this form directs one to use the command: "recover database until cancel". I get a syntax error. So I tried recover until time, which runs, but does not apply the new archivelogs. Must I update the DR database controlfile with a post-last-backup copy from the production database in order to apply these archivelogs? Must a catalog be used?
    Thank you for any assistance.

    What seems to work is:
    1) to restore the database using the controlfile from the backup,
    2) to issue the command 'alter database recover until cancel using backup control file' from sqlplus,
    3) to respond to each ORA-00279 with 'alter database recover continue default' also from sqlplus and until all the archivelogs have been applied, including archivelogs with sequences subsequent to the backup, then 'alter database recover cancel'.
    4) to issue the command 'alter database open resetlogs'.
    The above steps allow the available archivelogs to roll the database forward beyond the point in time recorded at the time of the hot backup.
    Metalink Note:161742.1 was helpful determining this information, yet it seems to conflict with Tom Kyte's statement that one should avoid using the backup controlfile whenever possible: http://asktom.oracle.com/pls/ask/f?p=4950:8:::::F4950_P8_DISPLAYID:894628342039#29824708782039
    Perhaps the conflict is due to the difference between a restore/recovery and a restore/recovery to a new server?
    Do the above steps seem to be the best practice for restoring/recovering a database to a new server?
    Thank you.

  • How to get folder list of mailbox that is in Recovery database.

    Hello ,
    We have done recovery of one database to RDB. This RDB has resource mailbox f size 80 GB. We need to perform restore of one fodler only. I need to confirm whter that folder is present in this RDB.
    How can i checked that. I ran get-mailfolderstatistics on output of get-mailboxstatistics, but it resilt in to error.
    Any one has expreince ,how can view folders of that RES MBX on that RDB. Belive me there are ore than 800 Folders. I am not aware of the path of that folder. And i donrt want to restore complete mailbox .
    Thanks,
    Hasin Choudhary.

    Great information from Martin and if you want a GUI to view the existing folders check out Lucid8's DigiScope using a DEMO license and you will have instant access to all  information
    Search, Recover, & Extract Mailboxes, Folders, & Email Items from Offline Exchange Mailbox and Public Folder EDB's and Live Exchange Servers or Import/Migrate direct from Offline EDB to Any Production Exchange Server, even cross version i.e. 2003 -->
    2007 --> 2010 --> 2013 with Lucid8's
    DigiScope

  • Recovery database

    Hi..
    I am new to Oracle RMAN Backup and Recovery. I created a table and backup the entire database. now i dropped the table. when i restore and recover the database by
    RMAN> RESTORE DATABASE;
    RMAN> RECOVER DATABASE;
    the table is not recovered but if i am doing the point in time recovery by
    RMAN> RESTORE DATABASE UNTIL TIME "SYSDATE-1/24";
    RMAN> RECOVER DATABASE UNTIL TIME "SYSDATE-1/24";
    the table is recovered. I want to recover normally. what should i do?

    you've to perform recovery upto specific time when the table was available that why cmd "RESTORE DATABASE UNTIL TIME "SYSDATE-1/24";" is working in your case.
    however if you perform complete recovery by recover database then database come back to same stage when the table was dropped and its not available in database.
    so you have to perform incomplete recovery.
    Thanks
    Kuljeet Pal Singh

  • !!!Urgent !!!!!Cannot recovery database without log files (SQL 2008)

    I only have single mdf file, the transaction log file was corrupted. When I was trying to attatch the mdf file, I received the following error message. Can someone give me a help..... it's really urgent!
    TITLE: Microsoft SQL Server Management Studio
    Attach database failed for Server 'DEV8\sqlexpress2008'.  (Microsoft.SqlServer.Smo)
    For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=10.0.1600.22+((SQL_PreRelease).080709-1414+)&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Attach+database+Server&LinkId=20476
    ADDITIONAL INFORMATION:
    An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
    Could not open new database 'Smartadmin'. CREATE DATABASE is aborted.
    File activation failure. The physical file name "C:\MSSQL\Smartadmin_log.ldf" may be incorrect.
    The log cannot be rebuilt because there were open transactions/users when the database was shutdown, no checkpoint occurred to the database, or the database was read-only. This error could occur if the transaction log file was manually deleted or lost due to a hardware or environment failure. (Microsoft SQL Server, Error: 1813)
    For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=10.00.1600&EvtSrc=MSSQLServer&EvtID=1813&LinkId=20476
    BUTTONS:
    OK
    Javafun

    I killed a dev db by accident (moved it between folders while it had an open transaction) and out of curiosity attempted to fix it as though it were a super-urgent client db. The above link fixed it, but I'll cut to the chase since it's a lot simpler than
    most of the article:
    1) Set aside the database mdf and ldf you're trying to recover.
    2) Create a database in the location you wanted, of the same name as the problem DB.
    3) Stop the SQL Server service.
    4) Copy the mdf and ldf files in, overwriting the dummy db you created.
    5) Start the SQL Server service.
    Done. Fixed.
    Surely you're doing something SQL Server does not like, but it is unfortunate you have to shut down the entire service to perform this trick. All of the other methods in that linked article and sp_attach_single_file_db failed, but this worked like a charm.
    In my dev database I was left with a db that was good as new - no missing data no problems. It seems odd this works so well and yet all these other approaches get errors about an open transaction. To be fair though, my dev database is essentially a single-user
    file that isn't heavily used, I assume a production DB on a busy server would be more problematic.

  • Hi i am newbie to Database connectting technology

    Hi i am using SQL server instead of Oracle,but i have lack of experience in making database connection to SQL Server from Java.Could you anybody please help me,and give me a best example with code.

    There are some examples in the help files that come with the jdbc driver: [http://msdn.microsoft.com/data/jdbc/]

  • Newbie to databases: mysql, sql and jdbc?

    hi,
    am new to databases and java-database access and was wondering if the following is correct
    1) sql is a standard
    2) mysql is an implementation of sql
    3) there is a jdbc sql driver that can access any sql database (including mysql)
    any help appreciated,
    asjf

    Pretty much yes that's true.ah, so its a defacto standard? I should've said "specification" above - in the same way that j2ee is a specification, and different vendors offer different implementations?
    it sounds like SQL is not like j2ee in that way?
    Most of the SQL compliant databases provide a JDBC driver that you can use. You can even write your own if you have an urge to do so.does JDBC provide a backend independent way of accessing databases? ie you can swap the drivers around fairly freely?
    also, i'm having trouble locating a high-level overview of jdbc - i've found the "Basic tutorial" but this is more of a low-level step-by-step guide to starting out
    http://java.sun.com/docs/books/tutorial/jdbc/basics/index.html
    thanks,
    asjf

  • A confused newbie: SQLServer database vs. ORACLE Tablespace

    Guys, excuse me for asking some surely stupid questions, but I'm really confused.
    In SQLServer, I can simply create a new database and it has it's own physical files. This means that - for example - it is really trivial to have multiple releases of the same database setup concurrently.
    In Oracle, I'm simply blown away at the complexity of this seemingly simple requirement. Here are some of the problems I have doing this with Orcale:
    - I can create a second tablespace but then my sequences clash with sequences already in place for tables in the other table space
    - I can't simply drop a tablespace and the sequences drop too
    - I don't know how to connect to a new database (somehow I seem to have to create a listener too)
    OK, I doubt that Oracle is so useless, I'm far more convinced that the "useless" attribute is better suited to my Oracle skills. That is why I can't wait to get some pointers to how I can achieve what I want to achieve useing Oracle.
    Pete
    Message was edited by:
    petehug

    A tablespace is just a logical collection of objects that happen to reside in the data file, so there is technically no reason that you would need separate tablespaces here. Probably a good idea for organizational purposes, but not strictly necessary.
    If we're going to set up version 5.12 of the database...
    1) Create the tablespace (optional). Note that the exact syntax will depend on how you've configured your database (i.e. whether you're using Oracle Managed Files, ASM, etc).
    CREATE TABLESPACE ts_lima_512_md
      DATAFILE 'ts_lima_512_md.dbf' SIZE 100M;2) Create the user/ schema
    CREATE USER lima_512_md
      IDENTIFEID BY <<password>>
      DEFAULT TABLESPACE ts_lima_512_md;3) Log in as the user you just created and create whatever objects you need to create. Assuming you don't specify a tablespace in your DDL, the default tablespace for the user will be used. Otherwise, it would be perfectly valid to have different users/ schemas own objects of the same name in the same tablespace.
    4) Create a role that gives other users whatever permissions they'll need on objects and grant the role those privileges, i.e. for read-only access to tables
    CREATE ROLE lima_512_md_read_only;
    FOR x IN (SELECT * FROM user_tables)
    LOOP
      EXECUTE IMMEDIATE 'GRANT SELECT ON lima_512_md.' ||
                                    x.table_name ||
                                    ' TO lima_512_md_read_only';
    END LOOP;5) Grant this role to whatever other users you'd like
    GRANT lima_512_md_read_only TO scott;6) Now, you can log in as scott, set the current_schema in the session, and query any of the tables in the LIMA_512_MD schema.
    Justin

  • Read Only, Disaster Recovery Database

    I currently have an 8i standby database that I need to open for read only access 24 hours a day. Using the Oracle facilities, I have to close the database to users to apply the arch redo logs from Live. Is there any tools out there that would allow me to get around this?

    Usually you can open a standby db only for query purposes.
    Bear in mind that doing this you would stop the log apply process.
    Once finished your query activities, you should close again the standby db and apply the log "paused".
    This is unnecessary only in version 11g.
    Hope this helps.
    Regs,
    Acr

Maybe you are looking for