Undo tablespace currupt and no clean backup

Hello,
We are facing critical problem with database. We have not any clean backup and database in no archive log mode. Suddenly database is shutdown and when we are trying to open database it is giving error:-
ORA-01172: recovery of thread 1 stuck at block 350230 of file 3
ORA-01151: use media recovery to recover block, restore backup if needed
File 3 is Undo file.
Is there any way to open database?
Thanks in advance and please reply us ASAP.

1) First, follow Howardjr recomendations and allways do a backup first.
2) Open a SR with Metalink to help with your problem
3) If you want to try something here are some options, but never skip the point 1 previously explained.
Well, you have two possible scenarios, one supported other unsupported.
This is an inconsistency issue..
Solution
============
*1]Supported Solution:*
Restore-Incomplete recovery the DB from backup or rebuild the DB using an export dump.
*2]Internal (Not-supported) Solution:*
Update undo$ to change the status$ = 1 (undo segment is dropped) for the corrupted undo segment.
Caution:
This is NOT a supported solution. Therefore ensure that a full database cold backup is taken bbefore doing this data-dictionary patching.
Steps to do the patching:
1) First ensure that a full database backup is taken.
2) Modify/add the following parameters in initSID.ora:
undo_management=manual
job_queue_processes =0
aq_tm_processes=0
systemtrig_enabled=false
3) Shutdown
4) Startup restrict pfile
5) set transaction use rollback segment system;
if set transaction above fails, then not to proceed further.
6) Update undo$ to change the status$ = 1 (undo segment is dropped) for
the corrupt undo segment.
update undo$ set status$ = 1
where us# = <'undo segment id'>
and ts#=<'tablespace id'>
and file#=<'file id'>
and block# = <'block id'>
and status$=2;
or
update undo$ set status$ = 1
where name = <'corrupt undo segment name'>
and status$=2;
This will update only 1 row. Rollback the update if more than 1 row is updated.
7) Commit;
8) Shutdown abort
9) Set back in init.ora parameters modified in Step 2.
Startup restrict
10) Drop the corrupt undo tablespace using command:
drop tablespace <corrupt undo tablespace name> including contents;
11) Create new undo tablespace.
In initSID.ora, set undo_management=auto, undo_tablespace=<'new undo tablespace name'>
Restart the instance.
12) Take a backup.
*Parameter offlinerollback_segments is not useful:*
Trying to drop the corrupt undo segment or the undo tablespace by setting parameters undo management=manual and offline_rollback_segments in initSID.ora will fails with error: ORA-00600 [ktssdrp1].
To see the information about the corrupt block use this query:
select us#, name, ts#, file#, block#,status$ from undo$
where (ts#, file#, block#) not in
(select ts#, file#, block# from seg$ where type# in (1,10)) and status$ > 1;I had the same problem some time ago, and the unsupported solution works great, but never try it without a full backup first.
Cheers,
Francisco Munoz Alvarez
http://oraclenz.wordpress.com
Edited by: F.Munoz Alvarez on Nov 30, 2012 11:03 AM

Similar Messages

  • Cacluation of undo tablespace size and retenion

    How to calaculate the expected size of the undo tablespace and undo retention parameter from the exisitng data.

    The easiest way to calculate undo requirementes is using the undo advisor, it is available in 10g and 9i. This is a graphical tool that lets you know the amount of required undo space according to your generated undo data.
    Regards.

  • Differance between Rollback Segements and Undo Tablespace/segments

    Hi everyone.
    I have some confusion that how Rollback Segements and Undo Tablespace/segments and different? Functionally they seem to be the same but why then Oracle recommends not using Rollback segments?...please explain. Kindly post any links useful in this regard.
    Thanks,
    Mukesh

    1.when does the changed data written to the undo tablespace?It never gets moved to the undo tablespace.
    The ORIGINAL data gets moved to the rollback/undo. Oracle assumes that most of the time the transaction is going to commit, so the change is made to the real block (in memory). At that time, enough information to roll back that change is written into the rollback segment.
    2.which process writes the changed data to the undo tbs?The server process. The one to which the user connects. The one the user gets by contascting the listener.
    3.What are the identifiactions which is used to undo the changes made(like SCN) ? plz...AFAIK, Transaction Id is the only thing used. SCN, a redo log construct, may be used to recreate the transaction ID in the rollback.

  • FLASHBACK OFF FOR UNDO TABLESPACE????

    Hi all
    As my Undo tablespace growing evryday 2 GB & NOW it reached 19,
    Database size is 6GB only
    using Oracle 10g Release 2 without patch Set (release 1002000100) on Hp-Unix OS
    Can i use the Undo tablespace with FLASHBACK OFF option?
    what are the Consequences for Turning off the FLASHBACK,
    Can we use this type of Undo tablespace with Flashback OFF???
    CREATE UNDO TABLESPACE UNDOTBS03 DATAFILE
    '/app/oracle/product/oradata/prod/undotbs03.dbf' SIZE 1000M AUTOEXTEND OFF
    ONLINE
    RETENTION NOGUARANTEE
    BLOCKSIZE 8K
    FLASHBACK OFF;
    THANKS ALOT

    Oracle Flashback Database: feature is similar to conventional point-in-time recovery in its results, allowing you to return a database to its state at a time in the recent past. It is, however, much faster than point-in-time recovery, because it does not require restoration of datafiles from a backup and it requires application of fewer changes from the archived redo logs.
    UNDO  Tablespace: Oracle db save the old value when a process change data in undo tablespace.
    I think that you can change de default UNDO tablespace as NO AUTOEXTEND, and
    Configure
    SET UNDO_MANAGEMENT=AUTO
    SET UNDO_RETENTION= ( second need for logger transaction )
    UNDO_RETENTION specifies (in seconds) the low threshold value of undo retention. For AUTOEXTEND undo tablespaces, the system retains undo for at least the time specified in this parameter, and automatically tunes the undo retention period to satisfy the undo requirements of the queries.
    For fixed- size undo tablespaces, the system automatically tunes for the maximum possible undo retention period, based on undo tablespace size and usage history, and ignores UNDO_RETENTION unless retention guarantee is enabled.

  • Undo tablespace to recover without backup

    hi,
    I offlined one of my datafile containing in undo tablespace. Now my database is in mount stage when I tried to open the database it gives me the following error:
    SQL> alter database open;
    alter database open
    ERROR at line 1:
    ORA-00376: file 17 cannot be read at this time
    ORA-01110: data file 17: '/misc/live_tbs/undotbstest.dbf'
    My database is in noarchive mode plus I dont have a backup.
    Thank you for your cooperation.
    Regards,
    Adnan Hamdus Salam.

    adnan wrote:
    hi,
    I offlined one of my datafile containing in undo tablespace. Now my database is in mount stage when I tried to open the database it gives me the following error:
    SQL> alter database open;
    alter database open
    ERROR at line 1:
    ORA-00376: file 17 cannot be read at this time
    ORA-01110: data file 17: '/misc/live_tbs/undotbstest.dbf'
    My database is in noarchive mode plus I dont have a backup.
    Thank you for your cooperation.
    Regards,
    Adnan Hamdus Salam.If your database`s last shutdown was clean(SHUTDOWN IMMEDIATE) then you can open database as
    1) Backup current database(take cold backup)
    2) if you use pfile then edit it and UNDO_MANAGEMENT=MANUAL also if you use spfile then ALTER SYSTEM SET UNDO_MANAGEMENT=MANUAL SCOPE=SPFILE then
    3)SHUTDOWN IMMEDIATE and STARTUP MOUNT
    4) Now ALTER DATABASE DATAFILE '/misc/live_tbs/undotbstest.dbf' OFFLINE DROP
    5) ALTER DATABASE OPEN
    After that you can create new undo tablespace and set UNDO_MANAGEMENT=AUTO

  • Undo tablespace recovery from RMAN backup

    Hi,
    Lets's assume we have RMAN backup and archivelog backups, and now
    my undo tablespace's disk crashed ,how can i recover?
    Can i recover while database is up?
    Thanks,
    Kumar.

    to recover UNDO tablespace from RMAN backup you must shutdown the database and start it in the MOUNT state to recover the missing files as follows
    rman target /
    RUN
    STARTUP MOUNT;
    ALLOCATE CHANNEL ch3 TYPE Disk;
    RESTORE datafile 'c:\u01\prod3\undo01.dbf';
    RECOVER datafile 'c:\u01\prod3\undo01.dbf';
    ALTER DATABASE OPEN;
    RELEASE CHANNEL ch3;
    hope this will help you

  • Backup/restore of undo tablespace

    Hi,
    from backup basic doc:
    "You should not have to concern yourself with undo segments or manage
    them directly as part of your backup and recovery process. "
    Does this mean that undo tablespaces need not be or should not be backed up? And in the same vein, there is no point in restoring them as well. Right?
    Thanks,
    Raghu.

    Agreed, but what if a user drop a table and you can not live without it, then you need to perform incomplete recovery and it requires you to restore all the datafiles including undo datafile. And if you do not include the undo tablespace in your backup stratigies, then you run out of options. Anyways, In any case , I would strictly include undo tablespace in my backup policy.
    hare krishna
    Alok

  • Recovery lost  undo tablespace and Redo log

    Recovery undo tablespace
    [email protected]> shutdown
    Database closed.
    Database dismounted.
    ORACLE instance shut down.e
    [email protected]> exit
    Disconnected from Oracle9i Enterprise Edition Release 9.2.0.1.0 - Production
    With the Partitioning, OLAP and Oracle Data Mining options
    JServer Release 9.2.0.1.0 - Production
    [ora920@tkyte-pc-isdn ora920]$ ls
    control01.ctl cwmlite01.dbf indx01.dbf redo02.log redo0B.log temp01.dbf
    users01.dbf
    control02.ctl drsys01.dbf odm01.dbf redo03.log redo0C.log tools01.dbf
    xdb01.dbf
    control03.ctl example01.dbf redo01.log redo0A.log system01.dbf undotbs01.dbf
    [ora920@tkyte-pc-isdn ora920]$ mv undotbs01.dbf undotbs01.dbf.xxx
    [ora920@tkyte-pc-isdn ora920]$ sqlplus /nolog
    SQL*Plus: Release 9.2.0.1.0 - Production on Sat Sep 28 08:33:29 2002
    Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
    idle> connect / as sysdba
    Connected to an idle instance.
    idle> startup
    ORACLE instance started.
    Total System Global Area 143725064 bytes
    Fixed Size 451080 bytes
    Variable Size 109051904 bytes
    Database Buffers 33554432 bytes
    Redo Buffers 667648 bytes
    Database mounted.
    ORA-01157: cannot identify/lock data file 2 - see DBWR trace file
    ORA-01110: data file 2: '/usr/oracle/ora920/OraHome1/oradata/ora920/undotbs01.dbf'
    idle> show parameter undo
    NAME TYPE VALUE
    undo_management string AUTO
    undo_retention integer 10800
    undo_suppress_errors boolean FALSE
    undo_tablespace string UNDOTBS1
    idle> alter system set undo_management = manual scope=spfile;
    System altered.
    Note: disabling the undo tablespace here, this'll let us go back to "rollback segments"
    and we'll use the system RBS to get back on our feet
    idle> shutdown
    ORA-01109: database not open
    Database dismounted.
    ORACLE instance shut down.
    idle> exit
    Disconnected from Oracle9i Enterprise Edition Release 9.2.0.1.0 - Production
    With the Partitioning, OLAP and Oracle Data Mining options
    JServer Release 9.2.0.1.0 - Production
    [ora920@tkyte-pc-isdn ora920]$ !sql
    sqlplus /nolog
    SQL*Plus: Release 9.2.0.1.0 - Production on Sat Sep 28 08:35:34 2002
    Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
    idle> connect / as sysdba;
    Connected to an idle instance.
    idle> startup
    ORACLE instance started.
    Total System Global Area 143725064 bytes
    Fixed Size 451080 bytes
    Variable Size 109051904 bytes
    Database Buffers 33554432 bytes
    Redo Buffers 667648 bytes
    Database mounted.
    ORA-01157: cannot identify/lock data file 2 - see DBWR trace file
    ORA-01110: data file 2: '/usr/oracle/ora920/OraHome1/oradata/ora920/undotbs01.dbf'
    Note: we still have to get rid of that thing..
    idle> alter database datafile '/usr/oracle/ora920/OraHome1/oradata/ora920/undotbs01.dbf'
    2 offline drop;
    Database altered.
    idle> alter database open;
    Database altered.
    idle> drop tablespace undotbs1;
    Tablespace dropped.
    idle> create UNDO tablespace undotbs1
    2 datafile '/usr/oracle/ora920/OraHome1/oradata/ora920/undotbs01.dbf' size 25m
    3 autoextend on next 1m maxsize 1024m;
    Tablespace created.
    idle> alter system set undo_management = auto scope=spfile;
    System altered.
    Now, we've put the undo tablespace "back" by creating a new one. Just bounce...
    idle> shutdown
    Database closed.
    Database dismounted.
    ORACLE instance shut down.
    idle> exit
    Disconnected from Oracle9i Enterprise Edition Release 9.2.0.1.0 - Production
    With the Partitioning, OLAP and Oracle Data Mining options
    JServer Release 9.2.0.1.0 - Production
    [ora920@tkyte-pc-isdn ora920]$ !sql
    sqlplus /nolog
    SQL*Plus: Release 9.2.0.1.0 - Production on Sat Sep 28 08:40:51 2002
    Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
    idle> connect / as sysdba;
    Connected to an idle instance.
    idle> startup
    ORACLE instance started.
    Total System Global Area 143725064 bytes
    Fixed Size 451080 bytes
    Variable Size 109051904 bytes
    Database Buffers 33554432 bytes
    Redo Buffers 667648 bytes
    Database mounted.
    Database opened.
    idle> show parameter undo
    NAME TYPE VALUE
    undo_management string AUTO
    undo_retention integer 10800
    undo_suppress_errors boolean FALSE
    undo_tablespace string UNDOTBS1
    idle>
    and we are right back where we started from
    RECOVERY REDO TABLESPACE
    STARTUP MOUNT;
    RESTORE DATABASE;
    RECOVER DATABASE UNTIL SEQUENCE $v_seq THREAD 1;
    ALTER DATABASE OPEN RESETLOGS;

    [email protected] wrote:
    just ignore first one like title
    Alter database open resetlog is not necessary to open database ?
    Regards
    kmphttp://download.oracle.com/docs/cd/B19306_01/backup.102/b14191/osrecov.htm#i1007426
    About Opening with the RESETLOGS Option
    The RESETLOGS option is always required after incomplete media recovery or recovery using a backup control file.
    You did not do an incomplete media recovery nor a recovery using a backup control file.

  • Undo tablespace  and instance recovery

    Is UNDO tablespace is mandatory during instance recovery. ?
    Suppose my undo tablespace has some active transaction and instance crashes making undo tablespace inaccessible.
    Will database search for that undo tablespace during startup or I can simply create a new one and set as new undo tablespace ?
    With Regards
    Amt

    Hi,
    >>I am actually confused
    Keep in mind that If an Oracle instance crashes, any changes that are made in the SGA are not written to the data files. When you restart the instance, the SMON background process automatically performs instance recovery by performing the following tasks:
    • Rolling forward changes that are made in the online redo log files but not in the data files. Since all the committed transactions are written to the online redo log files, these are successfully recovered as result of rolling forward changes from the online redo log files to the data files.
    • Opening the database. After the database is opened, users can log on and access any data that is not locked by un-recovered transaction.
    • Rolling back all the uncommitted transactions.
    In resume, during database recovery, undo records are used to undo any uncommitted changes applied from the redo log to the datafiles.
    But if your UNDO tablespace crashed, then you will need recover it, using steps like
    1) shutdown abort (If the instance yet is up)
    2) cp -a /backup/undo01.dbf /u01/oradata (restore the latest recent backup file)
    3) startup mount
    4) recover database or recover datafile '/u01/oradata/undo01.dbf'
    5) alter database open;
    In some cases, re-create it, also resolve the problem:
    http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:5669213349582
    Missing UNDO tablespace in restore backup
    >>I checked in test setup and it is actually waiting for missing UNDO tablespace.
    Which exactly test you are doing?
    Cheers

  • Is there so call "dedicated" UNDO tablespace in Oracle 9i and higher?

    Since one of our applicaions needs to process large amounts of data, we have been using a dedicated rollback segment in order to avoid the "snapshot too old" problem.
    Recently our DB upgraded to Oracle 9i and DBA asked us to use "undo" tablespace.
    Based the Oracle 9i Doc., it only allows to select ONE undo tablespace at a time.
    If so, DBA has to make the only UNDO as large as our Cash large transactions
    need(adjust the UNDO_RENTION), which inevitably waste lots of space.
    Does Oracle 9i allow to have one dedicated UNDO tablespace for large transactions while another one for regular transactions just like we use the old rollback segments.
    Thanks in advance

    Why have multiple UNDO tablespaces? You can only use one at a time, and when the other one is not being used, it still consumes storage space.
    Spend a little time determining how much undo you need and size undo tablespace and undo retention around those values and you should be able to resolve the problems you are experiencing now.
    http://download-east.oracle.com/docs/cd/B10501_01/server.920/a96521/undo.htm#9505

  • Segment shrinking and UNDO tablespace

    When i issued
    alter table <table_name> shrink space cascade;
    I got the error 'Unable to extend UNDO ...by 8' . Does Segment shrinking consume space from UNDO tablespace?
    Message was edited by:
    for_good_reason

    As Jonathan said, shrinking segment generates redo and undo data.
    But, this phoenomenon of undo shortage is not normal case.
    Shrinking segment might invole continous DML(deleting and re-inserting),
    but it's transaction seems to be committed internally at regular intervals.
    For this reason, shrinking operation should not hold undo area that long.
    But have no knowledge on exact behavior of shrink operation.
    Someone else will shed a light.
    How big your table and indexes?
    Some cases are reorted that shrinkage on big segment generates really large amount of undo data.
    This might be related with your problem. But not sure.
    Visit metalink note# 3888229.

  • Drop undo tablespace but space not release (du and df show different value)

    hi guys,
    i just change my undo and drop the previous 1.
    create undo tablespace UNDOTBS4 DATAFILE '/u03/oradata/starhub/undotbs4.dbf' size 2g;
    Tablespace created.
    SQL> ALTER SYSTEM SET UNDO_TABLESPACE = undotbs4;
    System altered.
    SQL>  drop tablespace undotbs3 including contents and datafiles;
    Tablespace dropped.
    SQL>
    However, when i check my diskspace using df -h , it is still showing. 32 gig is used. where infact, only 30G should be used.
    71G 32G 37G 47% /u03
    when i check using du -h, it is showing only
    30G ./oradata
    I have to bounce the database to get my 2G back, why ?
    Is there anyway to get my 2G back without bouncing the DB ?
    Regards,
    Noob

    Oracle has the file still open, so the i-node of that file is still in use, so the file shows up.
    Learn your Unix!
    Sybrand Bakker
    Senior Oracle DBA

  • UNDO Tablespace backup- RMAN

    Hi Team/champions,
    I am confused in RMAN full DB backup why UNDO tablespce is included even we include the archive logs also.
    in Short ?
    why UNDO tablespace backup is required while taking RMAN backup ?
    Regards,
    Shitesh Shukla

    if I dont want to include the UNDO tablespce in my backup
    what if I took only database files backup excluding TEMP n UNDONOT an option. You have to include UNDO. 11g has optimization for backing up an Undo tablespace.
    In 10gR2 what you could do is
    1. Create a New Undo Tablespace
    2. Switch to the new Undo Tablespace
    3. verify that the Old Undo Tablespace is no longer in use -- confirm that there are no active transactions in undo segments in it
    4. drop the old Undo tablespace
    5. Run your RMAN Backup
    You run the risks of
    a. Waiting a long time at step 3
    b. ORA-1555s for users after you drop the Undo tablespace in step 4.
    Hemant K Chitale
    http://hemantoracledba.blogspot.com

  • ASSM and system, temp, undo tablespaces(10g)

    Hi, all.
    I created a database(10.2.0.2.0) by using DBCA.
    SYSAUX and USERS tablespaces are set to "auto" in
    SEGMENT_SPACE_MANAGEMENT column.
    However, system, temp and temp tablespaces have the value of "Manual" in
    SEGMENT_SPACE_MANAGEMENT column.
    Can I change this Value, "Manual" to "Auto" ??
    (system, temp, undo tablespace)
    Best Regards.

    Hi,
    The document states that there are certain restrictions on Automatic Segment-space Management.
    Firstly, you can specify this clause only for a permanent, locally managed tablespace.Secondly, you cannot specify this clause for the SYSTEM tablespace.
    http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14200/statements_7003.htm
    Adith

  • Undo tablespace full even with no active transaction and undo_retention 10s

    The 9.2.0.4 instance is AUM (auto undo management). The undo table space is 50G and is almost full.
    I have set the undo_retention to 10, previously it was 10800 (3hours). I restart the database. Wait quite long time.
    And search on the dba_undo_extents.
    select sum(bytes/(1024*1024*1024)),status from dba_undo_extents d where d.tablespace_name='UNDOTBS2' group by status;
    SUM(BYTES/(1024*1024*1024)) STATUS
    .574447632 EXPIRED
    45.5358887 UNEXPIRED
    It is hard to explain. 10 seconds already passed, at least all the extents should be expired.
    Why so many 45G is still unexpried.
    Is there a bug for undo tablespace? how to fix it.
    It is a rac instance, I am trouble shooting the undo tablespace issues.
    The UNDOTBS2 is for node2 to use.

    If you start the database in exclusive (one instance) mode then the database instance can have only one undo tablespace so I would not expect Oracle to do anything with the undo tablespace for the non-running instance.
    Run you database as normal and generate undo. See if the status changes. If if does that would imply that Oracle does not expire undo unless the undo segments (rbs segments) are accessed. Please post back with results of what you see.
    Between having batch production running on all my databases that use undo tablespaces and the fact we use uniform extent undo tabllespaces I am not in a position to try to duplicate what you are seeing.
    HTH -- Mark D Powell --

Maybe you are looking for

  • Can't post to YouTube with PrE 4

    Hi again. I searched on the forums and found a Photoshop Elements user who posted a similar issue. But there was no resolution so I am posting here. Thanks for your indulgence. I tried to share my 4.5 minute NTSC DV format (720x480) video to YouTube

  • Outgoing email completely lost (Mail app with Gmail account) - Insanely awkward

    This is gonna be hard to explain as I have no "evidence" but here's what happened for the 3rd time now in the last 2-3 months on Yosemite using a Gmail account from Mail app. I write a mail (either reply or new one), send it and it get's completely l

  • 2-byte error in XML Parser for PL/SQL

    environment: oracle 8.1.5 XML parser for Java 2.0.2.6.0 XML parser for PL/SQL 1.0.1.0.0 we use CLOB as xml data container, but it does not work properly with 2 byte chracter set. I tested same situation except using VARCHAR2 instead of CLOB, it works

  • Importing JSP in WebDynpro perspective

    Is it possible to import JSP/HTML/BSP in WebDynpro perspective?

  • Agent to run 3-rd party tests is stopped

    Hi All, I'm evaluating OATS 9.2 as test case management system what could allow to run 3-rd party tests. But when I'm running bat-file agent stops execution after 30 seconds. Exit code = 0. No errors are reported. Is it some agent setting that includ