System block corrupted

Hi,
Database version: 10.2.0
OS: Linux 5.4
in my test databae One of the system datafile block is corrupted.
I dont have rman backup for that test db.
EXP-00008: ORACLE error 1578 encountered
ORA-01578: ORACLE data block corrupted (file # 1, block # 50305)
ORA-01110: data file 1: '/u01/app/oracle/oradata/rmct/system01.dbf'
EXP-00000: Export terminated unsuccessfully
I cannot recover that block. At least I want to take export of the schema which resides in non
system tablespace.
regards,

What is the mode of your database.
SQL> select log_mode from v$database ;
If it is running in ARCHIVELOG, then you should be able to recover the corrupted block using RMAN
Guide on how to do that using RMAN can be found at ..
http://download.oracle.com/docs/cd/B12037_01/server.101/b10734/rcmconc2.htm#1006446
You can also read the forum
block level recovery
If the database is running in NOARCH. then I am not sure but you have to repair the block before you can run import. You can use the DBMS_REPAIR package
Refer the link for DBMS_REPAIR package details:
http://download.oracle.com/docs/cd/B19306_01/server.102/b14231/repair.htm

Similar Messages

  • System datafile block corruption - no backups and database in NOARCHIVELOG mode

    Dear All,
    Database version - oracle 11.1 Enterprise
    OS - RHELinux 5.8
    What are the options of recovering from physical block corruption when there are no backup available to perform block media recovery?
    V$DATABASE_BLOCK_CORRUPTION reports two segments corrupted (please see attached image for details).
    1 table in system datafile - sys_fba_barrierscn
    1 index - (applicaiton index)
    What are my options?
    I know there is a possibility that the database will not restart after a shutdown due to corruption in system tablespace.
    Database is in noarchivelog mode. So online backups are not possible and there aren't any full backups either.
    I am thinking of below,
    1. Run dbms_repair with fix_block_corruption. - Still database startup might fail?
    2. Shutdown the database and take offline full backup with RMAN MAXCorrupt option.
    Appreciate your suggestions and advises.
    Thanks
    Stefan

    Thanks Sybrand,
    Agree with your first two suggestions .
    Also scheduled a expdp job tonight. (Only backup like thing they had was a expdp cron, but until today all the large tables were failing due to small undo_retention).
    Yes. Flashback is not used. So hopefully it will not affect the a database restart i guess?
    Related to dbms_repair, I was referring to - http://askdba.org/weblog/2010/08/physical-corruption-ora-1578-part-3/.
    Where DBMS_REPAIR.FIX_CORRUPT_BLOCKS and DBMS_REPAIR.SKIP_CORRUPT_BLOCKS used.
    Which i think will not use any redo.
    Thanks
    Stefan

  • System and sysaux file block corruption

    Errors in file /u01/app/oracle/diag/rdbms/pdent/pdent/trace/pdent_smon_3135.trc:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-01578: ORACLE data block corrupted (file # 1, block # 91607)
    ORA-01110: data file 1: '/u01/app/oracle/oradata/pdent/system01.dbf'
    I am unable to take r man backup, as well as export using datapump. i tried to recover it using rman blockrecover but still same. here is detail
    SQL> SELECT * FROM V$DATABASE_BLOCK_CORRUPTION;
    FILE# BLOCK# BLOCKS CORRUPTION_CHANGE# CORRUPTIO
    1 91607 1 0 CHECKSUM
    2 58710 1 0 CHECKSUM
    5 1202316 1 0 CHECKSUM
    SQL> SELECT
    tablespace_name,
    segment_type,
    owner,
    segment_name
    FROM dba_extents
    WHERE file_id = 1
    AND BETWEEN block_id AND block_id + blocks - 1; 2 3 4 5 6 7 8
    TABLESPACE_NAME SEGMENT_TYPE OWNER
    SEGMENT_NAME
    SYSTEM INDEX SYS
    I_OBJ2
    alter system dump datafile 1 block 344;
    SQL> SELECT
    tablespace_name,
    segment_type,
    owner,
    segment_name
    FROM dba_extents
    WHERE file_id = 2
    AND 58710 BETWEEN block_id AND block_id + blocks - 1; 2 3 4 5 6 7 8
    TABLESPACE_NAME SEGMENT_TYPE OWNER
    SEGMENT_NAME
    SYSAUX INDEX PARTITION SYS
    WRH$_OSSTAT_PK
    SQL> ALTER INDEX I_OBJ2 REBUILD ONLINE;
    ALTER INDEX I_OBJ2 REBUILD ONLINE
    ERROR at line 1:
    ORA-00701: object necessary for warmstarting database cannot be altered
    need immediate help.
    thanks in advance

    user11914238 wrote:
    Errors in file /u01/app/oracle/diag/rdbms/pdent/pdent/trace/pdent_smon_3135.trc:
    ORA-00604: error occurred at recursive SQL level 1
    ORA-01578: ORACLE data block corrupted (file # 1, block # 91607)
    ORA-01110: data file 1: '/u01/app/oracle/oradata/pdent/system01.dbf'
    I am unable to take r man backup, as well as export using datapump. i tried to recover it using rman blockrecover but still same. here is detail
    SQL> SELECT * FROM V$DATABASE_BLOCK_CORRUPTION;
    FILE# BLOCK# BLOCKS CORRUPTION_CHANGE# CORRUPTIO
    1 91607 1 0 CHECKSUM
    2 58710 1 0 CHECKSUM
    5 1202316 1 0 CHECKSUM
    SQL> SELECT
    tablespace_name,
    segment_type,
    owner,
    segment_name
    FROM dba_extents
    WHERE file_id = 1
    AND BETWEEN block_id AND block_id + blocks - 1; 2 3 4 5 6 7 8
    TABLESPACE_NAME SEGMENT_TYPE OWNER
    SEGMENT_NAME
    SYSTEM INDEX SYS
    I_OBJ2
    alter system dump datafile 1 block 344;
    SQL> SELECT
    tablespace_name,
    segment_type,
    owner,
    segment_name
    FROM dba_extents
    WHERE file_id = 2
    AND 58710 BETWEEN block_id AND block_id + blocks - 1; 2 3 4 5 6 7 8
    TABLESPACE_NAME SEGMENT_TYPE OWNER
    SEGMENT_NAME
    SYSAUX INDEX PARTITION SYS
    WRH$_OSSTAT_PK
    SQL> ALTER INDEX I_OBJ2 REBUILD ONLINE;
    ALTER INDEX I_OBJ2 REBUILD ONLINE
    ERROR at line 1:
    ORA-00701: object necessary for warmstarting database cannot be altered
    need immediate help.
    Immediate help can be only provided by Oracle Support Services. So if you need that, please raise a Sev1 SR . For your issue, as others have suggested already, if you have a valid backup and you are in the archive log mode, using RMAN's BMR(Block Media Recovery) , the issue can be resolved provided there is nothing wrong with the hardware of yours. If that's the case, recovery wouldn't yield any benefits.
    Aman....

  • Block Corruption in SYSTEM Tablespace

    Hi,
    well it´s just a test database without a backup, but i would like to repair it anyway :-)
    Here are the facts:
    Errors in file c:\oracle\admin\o10g\bdump\o10g_smon_1404.trc:
    ORA-01578: ORACLE data block corrupted (file # 1, block # 50187)
    ORA-01110: data file 1: 'C:\ORACLE\ORADATA\O10G\SYSTEM01.DBF'
    1. I found the object: It´s a Cluster named SYS.C_TOID_VERSION#
    containing a lot of table stuff (type$,parameter$, ...)
    i tried to repair it with dbms_repair:
    BEGIN SYS.DBMS_REPAIR.SKIP_CORRUPT_BLOCKS (
    SCHEMA_NAME => 'SYS',
    OBJECT_NAME => 'C_TOID_VERSION#',
    OBJECT_TYPE => dbms_repair.cluster_object,
    FLAGS => dbms_repair.skip_flag);
    END;
    No error, but the same block corruption message in the alert.log 1 minute later.
    i can select the tables in the cluster.
    Has anyboby another trick to repair a cluster?
    Thanks
    Marco

    Hi,
    if you have rman backup then this problem become resolved by only one command.
    BLOCKRECOVER DATAFILE 1 BLOCK 3 DATAFILE 50187;
    otherwise restore system tablespace from backup and recover it.
    and one more thing
    **Don't fix the block in system tablespace it may create problem if that block contain some useful information of oracle(internal information).
    Thanks
    Kuljeet Pal Singh

  • SYSTEM Tablespace corrupt blocks !!!!!!!!!

    Hi,
    Oracle version 10gR2 - 10.2.0.1.0
    The database which i am running in 10g is having few corrupt data blocks in system data files. I have no backup of full database and neither the database is in archive log mode. I know the situation of my development database has very less chance of getting to open mode.
    I have checked in metalink in for any hidden parameters, But my funny questions do u think there is any hidden parameter to get out of this issue. please suggest any metalink doc or any parameter to overcome this issue :-)
    Thanks
    Edited by: user11981262 on Dec 15, 2011 8:41 AM

    I don't know any helping secret parameter for you. As I see this your data is lost.
    What you can do is documented in [url https://support.oracle.com/CSP/main/article?cmd=show&type=NOT&doctype=BULLETIN&id=28814.1]Handling Oracle Block Corruptions in Oracle7/8/8i/9i/10g/11g ID 28814.1 Read carefully and try database recovery (from online logs)... submit your results here.

  • System datafile block corrupted

    hi there,
    i have got a serious problem, my database is in mount state, but when i try to start it up, it gives error datafile block corrupted file 'd:\path\system01.dbf'. these are backup file from last database, afer which os has been formated and reinstalled.
    these are files from oracle 9i R1 and i want to install it intom oracle 9i R2.is it ok or i have to install oracle 9i R1 for making database up?
    plz help what should i do???
    thanks and regards
    VD

    ya its true,
    its not consistent backup.its not RMAN backup.i just have files >DBF,controlfiles and redo log files.
    now i am asked to retrieve data from these files.i have rebuild the database, and mounted it.but it is not getting opened.
    if i use 'ALTER DATABASE OPEN RESETLOGS' it takes too much time but dosent open.
    thats the issue.
    SQL> ALTER DATABASE OPEN RESETLOGS;
    ALTER DATABASE OPEN RESETLOGS
    ERROR at line 1:
    ORA-01190: controlfile or data file 2 is from before the last RESETLOGS
    ORA-01110: data file 2: 'D:\ORACLE\ORADATA\ORACLE\UNDOTBS01.DBF'
    alert log file entry:-
    Mon Nov 17 15:59:49 2008
    ORA-1589 signalled during: ALTER DATABASE OPEN..
    Mon Nov 17 16:00:06 2008
    RESETLOGS after incomplete recovery UNTIL CHANGE 81553193
    Resetting resetlogs activation ID 0 (0x0)
    Mon Nov 17 16:00:21 2008
    Errors in file D:\ORACLE\admin\ORACLE\udump\ORA02204.TRC:
    ORA-01110: data file 2: 'D:\ORACLE\ORADATA\ORACLE\UNDOTBS01.DBF'
    ORA-01114: IO error writing block to file 2 (block # 1)
    ORA-27041: unable to open file
    OSD-04002: unable to open file
    O/S-Error: (OS 5) Access is denied.
    Mon Nov 17 16:00:22 2008
    now tell me what should i do??
    thanks and regards
    VD

  • Oracle 11g: Block Corruption in SYSAUX File

    Hello All,
    I am facing Data corruption issue in the SYSAUX file.
    We are using Oracle 11G (Microsoft 32 bit) and our system is running in noarchivelog mode.
    Following are the errors in the alert log.
    e:\sc\sc15.2\databases\oracleconfig\diag\rdbms\enmscsdb\nm45\trace\nm45_p000_5944.trc
    Corrupt block relative dba: 0x0088a9f8 (file 2, block 567800)
    Fractured block found during buffer read
    Data in bad block:
    type: 6 format: 2 rdba: 0x0088a9f8
    last change scn: 0x0000.0b3bb7c7 seq: 0x1 flg: 0x04
    spare1: 0x0 spare2: 0x0 spare3: 0x0
    consistency value in tail: 0xc7000601
    check value in block header: 0xee6b
    computed block checksum: 0x72c6
    Reread of rdba: 0x0088a9f8 (file 2, block 567800) found same corrupted data
    Thu Jan 22 16:46:44 2009
    SMON: Restarting fast_start parallel rollback
    SMON: ignoring slave err,downgrading to serial rollback
    ORACLE Instance nm45 (pid = 12) - Error 1578 encountered while recovering transaction (9, 11) on object 458.
    Errors in file e:\sc\sc15.2\databases\oracleconfig\diag\rdbms\enmscsdb\nm45\trace\nm45_smon_6492.trc:
    ORA-01578: ORACLE data block corrupted (file # 2, block # 567800)
    ORA-01110: data file 2: 'E:\SC\SC15.2\DATABASES\ORACLECONFIG\SYSAUXNM45.ORA'
    Thu Jan 22 16:46:45 2009
    Trace dumping is performing id=[cdmp_20090122164645]
    Corrupt Block Found
    TSN = 1, TSNAME = SYSAUX
    RFN = 2, BLK = 567800, RDBA = 8956408
    OBJN = 458, OBJD = 458, OBJECT = I_WRI$_OPTSTAT_HH_OBJ_ICOL_ST, SUBOBJECT =
    SEGMENT OWNER = SYS, SEGMENT TYPE = Index Segment
    Following query indicates the corruption is in index.
    SQL> SELECT tablespace_name, segment_type, owner, segment_name FROM dba_extents
    WHERE file_id = 2 and 567800 between block_id AND block_id + blocks - 1;
    TABLESPACE_NAME SEGMENT_TYPE OWNER
    SEGMENT_NAME
    SYSAUX INDEX SYS
    I_WRI$_OPTSTAT_HH_OBJ_ICOL_ST
    ==============
    DBverify output:
    ==============
    E:\SC\SC15.2\Databases\OracleConfig>dbv file=SYSAUXNM45.ORA blocksize=8192
    DBVERIFY: Release 11.1.0.7.0 - Production on Thu Jan 22 16:59:11 2009
    Copyright (c) 1982, 2007, Oracle. All rights reserved.
    DBVERIFY - Verification starting : FILE = E:\SC\SC15.2\Databases\OracleConfig/SY
    SAUXNM45.ORA
    DBV-00200: Block, DBA 8956312, already marked corrupt
    Page 567800 is influx - most likely media corrupt
    Corrupt block relative dba: 0x0088a9f8 (file 2, block 567800)
    Fractured block found during dbv:
    Data in bad block:
    type: 6 format: 2 rdba: 0x0088a9f8
    last change scn: 0x0000.0b3bb7c7 seq: 0x1 flg: 0x04
    spare1: 0x0 spare2: 0x0 spare3: 0x0
    consistency value in tail: 0xc7000601
    check value in block header: 0xee6b
    computed block checksum: 0x72c6
    DBVERIFY - Verification complete
    Total Pages Examined : 1623864
    Total Pages Processed (Data) : 540984
    Total Pages Failing (Data) : 0
    Total Pages Processed (Index): 964944
    Total Pages Failing (Index): 0
    Total Pages Processed (Other): 17849
    Total Pages Processed (Seg) : 0
    Total Pages Failing (Seg) : 0
    Total Pages Empty : 100086
    Total Pages Marked Corrupt : 2
    Total Pages Influx : 1
    Total Pages Encrypted : 0
    Highest block SCN : 190789648 (0.190789648)
    SQL> select * from v$database_block_corruption;
    FILE# BLOCK# BLOCKS CORRUPTION_CHANGE# CORRUPTIO
    2 567800 1 0 FRACTURED
    2 567704 1 0 FRACTURED
    How to resolve this issue.
    Thanks
    With Regards
    Hemant Joshi.

    Drop and re-creating the index would be better than re-building the index.
    Check the metalink note: Identify the corruption extension using RMAN/DBV/ANALYZE etc - 836658.1
    Note 28814.1 - Handling Oracle Block Corruptions in Oracle7/8/8i/9i/10g
    Note 472231.1 - How to identify all the Corrupted Objects in the Database reported by RMAN
    ORA-1578 Main Reference Index for Solutions -830997.1

  • BLOCK CORRUPTION (ORA-1578) 처리 (ORACLE 8I NEW FEATURE)

    제품 : ORACLE SERVER
    작성날짜 : 2002-05-31
    BLOCK CORRUPTION (ORA-1578) 처리 (ORACLE 8I NEW FEATURE)
    ========================================================
    PURPOSE
    Block Corruption의 처리 방안에 대해 알아본다.
    Problem Description
    block corruption 시 10210, 10211,10231 의 event 를 사용해서
    해당 block 을 skip 할 수도 있지만 V8.1 이상에서는
    dbms_repair.fix_corrupt_blocks ,
    dbms_repair.skip_corrupt_block 를 이용하여
    corrupt가 발생한 block을 detect하고 skip, 또는 repair해주는 방안이
    제시되고 있다.
    Workaround
    Solution Description
    - 먼저 detecting 을 위해 db_block_checking =true 를 init.ora 에 set
    - dbms_repair 의 package 를 사용하는데 이 package 는 dbmsrpr.sql,
    prvtrpr.plb를 수행한다 .
    - sys 로 접속하여 package 를 실행한다.
    다음의 예제를 살펴보자
    T1 테이블에 corrupt 된 block 이 있다고 가정한다.
    SQL> desc t1
    Name Null? Type
    COL1 NOT NULL NUMBER(38)
    COL2 CHAR(512)
    SQL> analyze table t1 validate structure;
    analyze table t1 validate structure
    ERROR at line 1:
    ORA-01498: block check failure - see trace file
    이때 ANALYZE로 부터 발생된 trace file 에 corrupt 된 block 에 3 row 의
    (nrows = 3) data 가 있음을 알수 있다고 가정하자.
    DBMS_REPAIR.ADMIN_TABLES (repair and orphan key)
    ================================================
    ADMIN_TABLES 은 table 을 위한 repair table과,인덱스를 위한 orphan key
    tables을 제공한다.
    SQL> @adminCreate
    SQL> connect sys/change_on_install
    Connected.
    SQL>
    SQL> -- Repair Table
    SQL>
    SQL> declare
    2 begin
    3 -- Create repair table
    4 dbms_repair.admin_tables (
    5 -- table_name => 'REPAIR_TABLE',
    6 table_type => dbms_repair.repair_table,
    7 action => dbms_repair.create_action,
    8 tablespace => 'USERS'); -- default TS of SYS if not specified
    9 end;
    10 /
    PL/SQL procedure successfully completed.
    SQL> select owner, object_name, object_type
    2 from dba_objects
    3 where object_name like '%REPAIR_TABLE';
    OWNER OBJECT_NAME OBJECT_TYPE
    SYS DBA_REPAIR_TABLE VIEW
    SYS REPAIR_TABLE TABLE
    SQL>
    SQL> -- Orphan Key Table
    SQL>
    SQL> declare
    2 begin
    3 -- Create orphan key table
    4 dbms_repair.admin_tables (
    5 table_type => dbms_repair.orphan_table,
    6 action => dbms_repair.create_action,
    7 tablespace => 'USERS'); -- default TS of SYS if not specified
    8 end;
    9 /
    PL/SQL procedure successfully completed.
    SQL> select owner, object_name, object_type
    2 from dba_objects
    3 where object_name like '%ORPHAN_KEY_TABLE';
    OWNER OBJECT_NAME OBJECT_TYPE
    SYS DBA_ORPHAN_KEY_TABLE VIEW
    SYS ORPHAN_KEY_TABLE TABLE
    DBMS_REPAIR.CHECK_OBJECT
    =========================
    CHECK_OBJECT procedure 는 기술된 object를 check 하고, repair 를 위한 정보를 수집하기 위함이다.
    SQL> @checkObject
    SQL> set serveroutput on
    SQL>
    SQL> declare
    2 rpr_count int;
    3 begin
    4 rpr_count := 0;
    5 dbms_repair.check_object (
    6 schema_name => 'SYSTEM',
    7 object_name => 'T1',
    8 repair_table_name => 'REPAIR_TABLE',
    9 corrupt_count => rpr_count);
    10 dbms_output.put_line('repair count: ' || to_char(rpr_count));
    11 end;
    12 /
    repair count: 1
    PL/SQL procedure successfully completed.
    SQL> desc repair_table
    Name Null? Type
    OBJECT_ID NOT NULL NUMBER
    TABLESPACE_ID NOT NULL NUMBER
    RELATIVE_FILE_ID NOT NULL NUMBER
    BLOCK_ID NOT NULL NUMBER
    CORRUPT_TYPE NOT NULL NUMBER
    SCHEMA_NAME NOT NULL VARCHAR2(30)
    OBJECT_NAME NOT NULL VARCHAR2(30)
    BASEOBJECT_NAME VARCHAR2(30)
    PARTITION_NAME VARCHAR2(30)
    CORRUPT_DESCRIPTION VARCHAR2(2000)
    REPAIR_DESCRIPTION VARCHAR2(200)
    MARKED_CORRUPT NOT NULL VARCHAR2(10)
    CHECK_TIMESTAMP NOT NULL DATE
    FIX_TIMESTAMP DATE
    REFORMAT_TIMESTAMP DATE
    SQL> select object_name, block_id, corrupt_type, marked_corrupt,
    2 corrupt_description, repair_description
    3 from repair_table;
    OBJECT_NAME BLOCK_ID CORRUPT_TYPE MARKED_COR
    CORRUPT_DESCRIPTION
    REPAIR_DESCRIPTION
    T1 3 1 FALSE
    kdbchk: row locked by non-existent transaction
    table=0 slot=0
    lockid=32 ktbbhitc=1
    mark block software corrupt
    Data Extraction
    ===============
    repair table에 의하면 file 6 ,block 3 에 corrupt 이 났음을 알수 있다
    그러나 아직 이 block 은 corrupt 로 mark 되어 있지 않으므로 필요 data 를
    추출하여야 한다.
    1. ALTER SYSTEM DUMP (nrows = 3) 에 의해 block안에 있는 row수를 결정한다.
    2. corrupt object를 select 하여 가능한 정보를 추출한다.
    SQL> -- The following query can be used to salvage data from a corrupt block.
    SQL> -- Creating a temporary table facilitates data insertion.
    SQL> create table temp_t1 as
    2 select * from system.t1
    3 where dbms_rowid.rowid_block_number(rowid) = 3
    4 and dbms_rowid.rowid_to_absolute_fno (rowid, 'SYSTEM','T1') = 6;
    Table created.
    SQL> select col1 from temp_t1;
    COL1
    2
    3
    DBMS_REPAIR.FIX_CORRUPT_BLOCKS (ORA-1578)
    ============================================
    FIX_CORRUPT_BLOCKS procedure는 repair table 의 정보를 이용하여 corrupt
    blocks 을 fix 한다
    그러나 아직 full table scan 시 여전히 error 가 발생한다
    SQL> declare
    2 fix_count int;
    3 begin
    4 fix_count := 0;
    5 dbms_repair.fix_corrupt_blocks (
    6 schema_name => 'SYSTEM',
    7 object_name => 'T1',
    8 object_type => dbms_repair.table_object,
    9 repair_table_name => 'REPAIR_TABLE',
    10 fix_count => fix_count);
    11 dbms_output.put_line('fix count: ' || to_char(fix_count));
    12 end;
    13 /
    fix count: 1
    PL/SQL procedure successfully completed.
    SQL> select object_name, block_id, marked_corrupt
    2 from repair_table;
    OBJECT_NAME BLOCK_ID MARKED_COR
    T1 3 TRUE
    SQL> select * from system.t1;
    select * from system.t1
    ERROR at line 1:
    ORA-01578: ORACLE data block corrupted (file # 6, block # 3)
    ORA-01110: data file 6: '/tmp/ts_corrupt.dbf'
    DBMS_REPAIR.DUMP_ORPHAN_KEYS
    ==============================
    DUMP_ORPHAN_KEYS는 corrupt data 에 해당하는 index 를 나타내 준다
    SQL> select index_name from dba_indexes
    2 where table_name in (select distinct object_name from repair_table);
    INDEX_NAME
    T1_PK
    SQL> @dumpOrphanKeys
    SQL> set serveroutput on
    SQL>
    SQL> declare
    2 key_count int;
    3 begin
    4 key_count := 0;
    5 dbms_repair.dump_orphan_keys (
    6 schema_name => 'SYSTEM',
    7 object_name => 'T1_PK',
    8 object_type => dbms_repair.index_object,
    9 repair_table_name => 'REPAIR_TABLE',
    10 orphan_table_name => 'ORPHAN_KEY_TABLE',
    11 key_count => key_count);
    12 dbms_output.put_line('orphan key count: ' || to_char(key_count));
    13 end;
    14 /
    orphan key count: 3
    PL/SQL procedure successfully completed.
    SQL> desc orphan_key_table
    Name Null? Type
    SCHEMA_NAME NOT NULL VARCHAR2(30)
    INDEX_NAME NOT NULL VARCHAR2(30)
    IPART_NAME VARCHAR2(30)
    INDEX_ID NOT NULL NUMBER
    TABLE_NAME NOT NULL VARCHAR2(30)
    PART_NAME VARCHAR2(30)
    TABLE_ID NOT NULL NUMBER
    KEYROWID NOT NULL ROWID
    KEY NOT NULL ROWID
    DUMP_TIMESTAMP NOT NULL DATE
    SQL> select index_name, count(*) from orphan_key_table
    2 group by index_name;
    INDEX_NAME COUNT(*)
    T1_PK 3
    Note: orphan key table의 index 는 다시 rebuild 되어야 한다.
    DBMS_REPAIR.SKIP_CORRUPT_BLOCKS
    ===============================
    SKIP_CORRUPT_BLOCKS 은 table 과 index 의 corrupt block 을 skip 하는 것을 enable/disable 을 실시한다.
    Suggestion: SKIP_CORRUPT_BLOCKS 가 enabled되면 orphan key table의 모든
    index 는 모두 rebuild 되어야 한다. ( all index associated with object
    if DUMP_ORPHAN_KEYS was omitted).
    SQL> @skipCorruptBlocks
    SQL> declare
    2 begin
    3 dbms_repair.skip_corrupt_blocks (
    4 schema_name => 'SYSTEM',
    5 object_name => 'T1',
    6 object_type => dbms_repair.table_object,
    7 flags => dbms_repair.skip_flag);
    8 end;
    9 /
    PL/SQL procedure successfully completed.
    SQL> select table_name, skip_corrupt from dba_tables
    2 where table_name = 'T1';
    TABLE_NAME SKIP_COR
    T1 ENABLED
    SQL> -- rows in corrupt block skipped, no errors on full table scan
    SQL> select * from system.t1;
    COL1 COL2
    4 dddd
    5 eeee
    --> Notice the pk index has not yet been corrected.
    SQL> insert into system.t1 values (1,'aaaa');
    insert into system.t1 values (1,'aaaa')
    SQL> select * from system.t1 where col1 = 1;
    no rows selected
    DBMS_REPAIR.REBUILD_FREELISTS
    ===============================
    REBUILD_FREELISTS rebuilds freelists for the specified object.
    SQL> declare
    2 begin
    3 dbms_repair.rebuild_freelists (
    4 schema_name => 'SYSTEM',
    5 object_name => 'T1',
    6 object_type => dbms_repair.table_object);
    7 end;
    8 /
    PL/SQL procedure successfully completed.
    Rebuild Index
    =============
    Note: Every index identified in the orphan key table should be rebuilt to
    ensure consistent results.
    SQL> alter index system.t1_pk rebuild online;
    Index altered.
    SQL> insert into system.t1 values (1, 'aaaa');
    1 row created.
    SQL> select * from system.t1;
    COL1 COL2
    4 dddd
    5 eeee
    1 aaaa
    Reference Document
    ------------------

    Try look to alert<SID>.log file for full error report (you could paste it here).
    Also from alert log you could get real values for db_block_buffers and shared_pool_size parameters that used during instance startup.

  • Oracle V11.2.0.3 ORA-01578: ORACLE data block corrupted - OBJECT = IDL_UB1$

    Hi,
    I am running into a data corruption issue.
    My database is:
    SQL> select banner from v$version;
    BANNER
    Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production
    PL/SQL Release 11.2.0.3.0 - Production
    CORE 11.2.0.3.0 Production
    TNS for Linux: Version 11.2.0.3.0 - Production
    NLSRTL Version 11.2.0.3.0 - Production
    The following information is written to the alert.log File
    alert.log File
    Mon Nov 07 17:24:12 2011
    Starting ORACLE instance (normal)
    LICENSE_MAX_SESSION = 0
    LICENSE_SESSIONS_WARNING = 0
    Picked latch-free SCN scheme 2
    Using LOG_ARCHIVE_DEST_1 parameter default value as USE_DB_RECOVERY_FILE_DEST
    Autotune of undo retention is turned on.
    IMODE=BR
    ILAT =27
    LICENSE_MAX_USERS = 0
    SYS auditing is disabled
    Starting up:
    Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - Production.
    ORACLE_HOME = /home/oracle/dbhome
    System name: Linux
    Node name: dbl-ora
    Release: 2.6.18-274.3.1.el5 (This is rhel5.7 or CentOs5.7)
    Version: #1 SMP Tue Sep 6 20:14:03 EDT 2011
    Machine: i686 / vm
    Mon Nov 07 19:42:14 2011
    Corrupt Block Found
    TSN = 0, TSNAME = SYSTEM
    RFN = 1, BLK = 52346, RDBA = 4246650
    OBJN = 225, OBJD = 225, OBJECT = IDL_UB1$, SUBOBJECT =
    SEGMENT OWNER = SYS, SEGMENT TYPE = Table Segment
    Errors in file /home/oracle/diag/rdbms/ora11/K/trace/K_ora_5425.trc (incident=11053):
    ORA-01578: ORACLE data block corrupted (file # 1, block # 52346)
    ORA-01110: data file 1: '/home/oracle/oradata/ora11/system01.dbf'
    Incident details in: /home/oracle/diag/rdbms/ora11/K/incident/incdir_11053/K_ora_5425_i11053.trc
    I was even able to detect the row that is generating the issue.
    In my case the obj# 33573 until 33577 are causing the issue,
    though I have no idea what sort of objects are affected.
    SQL> select * from idl_ub1$ where obj#=33572;
    OBJ# PART VERSION PIECE# LENGTH P
    33572 1 0 0 9032 F
    SQL> select * from idl_ub1$ where obj#=33573;
    ERROR:
    ORA-01578: ORACLE data block corrupted (file # 1, block # 52346)
    ORA-01110: data file 1: '/home/oracle/oradata/ora11/system01.dbf'
    no rows selected
    SQL> select * from idl_ub1$ where obj#=33577;
    ERROR:
    ORA-01578: ORACLE data block corrupted (file # 1, block # 52358)
    ORA-01110: data file 1: '/home/oracle/oradata/ora11/system01.dbf'
    no rows selected
    SQL> select * from idl_ub1$ where obj#=33578;
    OBJ# PART VERSION PIECE# LENGTH P
    33578 1 0 0 9032 F
    Any idea, how to fix this problem without recreating the whole database?
    Thanks in advance.
    wmager
    Edited by: magerxr on Nov 7, 2011 8:27 AM

    magerxr wrote:
    Thanks again for your quick advise.
    Here comes the result of dbv against my system tablespace.
    [oracle@dbl-ora ~]$ dbv FILE=/home/oracle/oradata/ora11/system01.dbf
    DBVERIFY: Release 11.2.0.3.0 - Production on Mon Nov 7 22:39:11 2011
    Copyright (c) 1982, 2011, Oracle and/or its affiliates. All rights reserved.
    DBVERIFY - Verification starting : FILE = /home/oracle/oradata/ora11/system01.dbf
    Page 52346 is influx - most likely media corrupt
    Corrupt block relative dba: 0x0040cc7a (file 1, block 52346)
    Fractured block found during dbv:
    Data in bad block:
    type: 6 format: 2 rdba: 0x0040cc7a
    last change scn: 0x0000.0010acfa seq: 0x1 flg: 0x04
    spare1: 0x0 spare2: 0x0 spare3: 0x0
    consistency value in tail: 0x00000000
    check value in block header: 0x8fda
    computed block checksum: 0xaafbselect owner, segment_type, segment_name from dba_extents
    where file_id = 1 and 52346 between block_id and block_id+blocks-1;
    >
    Page 52347 is marked corrupt
    Corrupt block relative dba: 0x0040cc7b (file 1, block 52347)
    Bad header found during dbv:
    Data in bad block:
    type: 1 format: 6 rdba: 0x0000a206
    last change scn: 0xacfa.0040cc7b seq: 0x10 flg: 0x00
    spare1: 0xfa spare2: 0xac spare3: 0x401
    consistency value in tail: 0x00000000
    check value in block header: 0x0
    block checksum disabled
    select owner, segment_type, segment_name from dba_extents
    where file_id = 1 and 52347 between block_id and block_id+blocks-1;
    Page 52361 is marked corrupt
    Corrupt block relative dba: 0x0040cc89 (file 1, block 52361)
    Bad header found during dbv:
    Data in bad block:
    type: 1 format: 6 rdba: 0x0000a206
    last change scn: 0xacfb.0040cc89 seq: 0x10 flg: 0x00
    spare1: 0xfb spare2: 0xac spare3: 0x401
    consistency value in tail: 0x32298500
    check value in block header: 0x0
    block checksum disabled
    select owner, segment_type, segment_name from dba_extents
    where file_id = 1 and 52361 between block_id and block_id+blocks-1;
    >
    >
    DBVERIFY - Verification complete
    Total Pages Examined : 122880
    Total Pages Processed (Data) : 81298
    Total Pages Failing (Data) : 0
    Total Pages Processed (Index): 22307
    Total Pages Failing (Index): 0
    Total Pages Processed (Other): 3349
    Total Pages Processed (Seg) : 1
    Total Pages Failing (Seg) : 0
    Total Pages Empty : 15910
    Total Pages Marked Corrupt : 16
    Total Pages Influx : 1
    Total Pages Encrypted : 0
    Highest block SCN : 4064615 (0.4064615)post results from 3 SQL above

  • Help on block corruption (URGENT ...!)

    Hi all.
    I have a Oracle 10g Rel1 database on a linux box who is presenting block corruption at the system tablespace level.
    This database IS NOT in archive mode.
    Message says:
    ORA-01578: bloque de datos ORACLE corrupto (archivo numero 1, bloque numero *47132*)
    ORA-01110: archivo de datos *1: '/u01/oradata/BADAN1/BADAN1/system01.dbf'*
    This script is suppose to tell me which is the segment holding corrupted block:
    SQL> SELECT e.file_id,
    2 e.block_id,
    3 e.owner,
    4 e.segment_name,
    5 e.segment_type
    6 FROM dba_extents e
    7 WHERE
    8 file_id=1 and 47132 BETWEEN 47132 AND 47132 + blocks - 1
    9 /
    FROM dba_extents e
    ERROR at line 6:
    ORA-01578: ORACLE data block corrupted (file # 1, block # 47132)
    ORA-01110: data file 1: '/u01/oradata/BADAN1/BADAN1/system01.dbf'
    It seems base tables associated with dba_extents view are related in this case:
    select ds.owner, ds.segment_name, ds.partition_name, ds.segment_type,
    ds.tablespace_name,
    e.ext#, f.file#, e.block#, e.length * ds.blocksize, e.length, e.file#
    from sys.uet$ e, sys.sys_dba_segs ds, sys.file$ f
    where e.segfile# = ds.relative_fno
    and e.segblock# = ds.header_block
    and e.ts# = ds.tablespace_id
    and e.ts# = f.ts#
    and e.file# = f.relfile#
    and bitand(NVL(ds.segment_flags,0), 1) = 0
    and bitand(NVL(ds.segment_flags,0), 65536) = 0
    union all
    select /*+ ordered use_nl(e) use_nl(f) */
    ds.owner, ds.segment_name, ds.partition_name, ds.segment_type,
    ds.tablespace_name,
    e.ktfbueextno, f.file#, e.ktfbuebno,
    e.ktfbueblks * ds.blocksize, e.ktfbueblks, e.ktfbuefno
    from sys.sys_dba_segs ds, sys.x$ktfbue e, sys.file$ f
    where e.ktfbuesegfno = ds.relative_fno
    and e.ktfbuesegbno = ds.header_block
    and e.ktfbuesegtsn = ds.tablespace_id
    and e.ktfbuesegtsn = f.ts#
    and e.ktfbuefno = f.relfile#
    and bitand(NVL(ds.segment_flags, 0), 1) = 1
    and bitand(NVL(ds.segment_flags,0), 65536) = 0
    Please anybody advise on what to do ...!
    Regards, Luis ...!

    myluism wrote:
    Hi all.
    I have a Oracle 10g Rel1 database on a linux box who is presenting block corruption at the system tablespace level.
    This database IS NOT in archive mode.
    Message says:
    ORA-01578: bloque de datos ORACLE corrupto (archivo numero 1, bloque numero *47132*)
    ORA-01110: archivo de datos *1: '/u01/oradata/BADAN1/BADAN1/system01.dbf'*
    This script is suppose to tell me which is the segment holding corrupted block:
    SQL> SELECT e.file_id,
    2 e.block_id,
    3 e.owner,
    4 e.segment_name,
    5 e.segment_type
    6 FROM dba_extents e
    7 WHERE
    8 file_id=1 and 47132 BETWEEN 47132 AND 47132 + blocks - 1
    9 /
    FROM dba_extents e
    ERROR at line 6:
    ORA-01578: ORACLE data block corrupted (file # 1, block # 47132)
    ORA-01110: data file 1: '/u01/oradata/BADAN1/BADAN1/system01.dbf'That query doesn't look right to me. Try this:
    SELECT e.file_id,
    e.block_id,
    e.owner,
    e.segment_name,
    e.segment_type
    FROM dba_extents e
    WHERE
    file_id=1  and 47132 BETWEEN block_id  AND block_id + blocks - 1
    /Let us know the result of that query.
    -Mark

  • (oracle) block corruption

    Hi Everybody,
    Recently, my site has a development database that encountered block corruption in the system tablespace. I have verified this by using Oracle utility DBVERIFY on the system datafile.
    We have no backup at all for this development database. So database recovery from backup is impossible for us.
    I understand that there's a package called DBMS_REPAIR that can be used to repair corrupted blocks. I tried using this, but the process failed because it could not access the system tablespace (which is corrupted) to create a table used by the package.
    Does anyone know if I could overcome this problem and repair the corrupted blocks on the system tablespace?
    Also, I would like to understand what are the possible causes of block corruption. My site's Oracle Server and databases are installed on Windows 2000 platform.
    Please help answer my queries if you can. Thank you!
    null

    Iam sorry that I have not seen this posting until today .
    When there is a block corruption export will fail with error.
    The best method is to replace this file with a backup file and roll forward.
    null

  • Checking block corruption, why in alert it is saying Error in trace file

    Hi,
    I am using Oracle 10g 10.2.0.1 with linux 32 bit
    I wanted to check block corruption using RMAN by following statement
    backup validate check logical database;
    when i executed the statement, following was the output
    Starting backup at 09-MAY-08
    allocated channel: ORA_DISK_1
    channel ORA_DISK_1: sid=91 devtype=DISK
    channel ORA_DISK_1: starting full datafile backupset
    channel ORA_DISK_1: specifying datafile(s) in backupset
    input datafile fno=00004 name=/u01/app/oracle/oradata/test/users01.dbf
    input datafile fno=00008 name=/u01/app/oracle/oradata/test/workflowuser
    input datafile fno=00001 name=/u01/app/oracle/oradata/test/system01.dbf
    input datafile fno=00003 name=/u01/app/oracle/oradata/test/sysaux01.dbf
    input datafile fno=00010 name=/u01/app/oracle/oradata/test/ifan
    input datafile fno=00002 name=/u01/app/oracle/oradata/test/undotbs01.dbf
    input datafile fno=00007 name=/u01/app/oracle/oradata/test/taker
    input datafile fno=00009 name=/u01/app/oracle/oradata/test/testing1
    input datafile fno=00005 name=/u01/app/oracle/oradata/test/brokerdb
    input datafile fno=00006 name=/u01/app/oracle/oradata/test/moneio
    input datafile fno=00011 name=/u01/app/oracle/oradata/test/web1
    input datafile fno=00012 name=/u01/app/oracle/oradata/test/e1
    input datafile fno=00013 name=/u01/app/oracle/oradata/test/ind1
    channel ORA_DISK_1: backup set complete, elapsed time: 00:06:57
    channel ORA_DISK_1: starting full datafile backupset
    channel ORA_DISK_1: specifying datafile(s) in backupset
    including current control file in backupset
    including current SPFILE in backupset
    channel ORA_DISK_1: backup set complete, elapsed time: 00:00:02
    Finished backup at 09-MAY-08
    and when i do the following query
    select * from v$database_block_corruption in sqlplus
    then there was no row
    so it means there is no logical corruption, but when i am looking at alert log file it is giving following lines
    Fri May 9 10:14:04 2008
    Errors in file /u01/app/oracle/admin/test/udump/test_ora_6606.trc:
    Fri May 9 10:14:04 2008
    Errors in file /u01/app/oracle/admin/test/udump/test_ora_6606.trc:
    Fri May 9 10:14:04 2008
    Errors in file /u01/app/oracle/admin/test/udump/test_ora_6606.trc
    and in above trace file following contents
    /u01/app/oracle/admin/test4/udump/test_ora_6606.trc
    Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
    With the Partitioning, OLAP and Data Mining options
    ORACLE_HOME = /u01/app/oracle/product/10.2.0/db_1
    System name: Linux
    Node name: test
    Release: 2.6.18-5-686
    Version: #1 SMP Wed Oct 3 00:12:50 UTC 2007
    Machine: i686
    Instance name: test
    Redo thread mounted by this instance: 1
    Oracle process number: 61
    Unix process pid: 6606, image: oracle@test (TNS V1-V3)
    *** 2008-05-09 10:14:04.093
    *** ACTION NAME:(0000040 STARTED19) 2008-05-09 10:14:04.071
    *** MODULE NAME:(backup full datafile) 2008-05-09 10:14:04.071
    *** SERVICE NAME:(SYS$USERS) 2008-05-09 10:14:04.071
    *** SESSION ID:(91.40318) 2008-05-09 10:14:04.071
    Is it normal, why the in alert file it is saying that Error in.
    And it did not create any backupset in folder of flash recovery but in Enterprise manager it is showing last backup on 09-may-2008, why ?
    Regards,

    See logical corruption is normally termed as the internal inconsistancy within the block which is not caused by Oracle but by the user.So if you find internal inconsistancy than the best option is to look at the user and ask him to get the values sorted out.If the internal inconsistancy is some thig like index fragmentation sort of things or index entry pointing to a null rowid than they are termed as the logical corruption and they should not impact your normal as he data is already there and there is no issue in reading the block as such.
    The term "corrupted blocks" I would call both in the tables and backup for those data blocks which are unreadable by Oracle which actualy is Physical corruption.
    If i am doing the checking at 2:00 am, does it take more than two hours.I didnt understand this.
    what can we do for Physical corruptionThis will need the block to be recovered with the Block Recover command of RMAN and a good backup.Read about it here,
    http://download.oracle.com/docs/cd/B19306_01/backup.102/b14194/rcmsynta010.htm
    About the Logical and Physical corruption checks , check here
    http://download-west.oracle.com/docs/cd/B19306_01/backup.102/b14191/rcmconc1012.htm
    Aman....

  • BLOCK CORRUPTION (ORACLE8 에서 ORA-1578 조치방법)

    제품 : ORACLE SERVER
    작성날짜 : 2002-04-26
    BLOCK CORRUPTION (ORACLE8 에서 ORA-1578 조치방법)
    ================================================
    PURPOSE
    본 bulletin 에서는 Oracle8 에서의 data block corruption error
    (ORA-1578) 에 대해서 조치방법을 알아본다.
    BACKGROUND
    ORA-1578 은 data block 에 corruption 이 생긴 경우에 발생한다.
    이 error 는 corruption 이 발생한 곳의 file number 와 block
    number 를 알려준다.
    본 bulletin 에서는 file number 를 'f', block number 를 'b' 로
    지칭하기로 한다. ORA-1578 과 함께 return 되는 file number는
    relative file number 가 아닌 absolute file number 를 의미한다.
    (Oracle8 에서 새롭게 소개된 relative file number 에 대해서는 본
    bulletin 의 6번 항목에서 다루도록 한다.)
    RESOLUTION
    1. 최선의 해결책은 backup 받아둔 file 을 restore 한 후
    recover 작업을 하는 것이다. 이 작업을 위해서는 archive
    log mode 로 운영 중이어야 한다.
    dba_data_files 또는 v$datafile 과 ORA-1578 error 에서
    return 된 absolute file number 를 이용하여 corruption이
    발생한 datafile 의 이름을 알아낼 수 있다.
    Oracle8 에서는, dba_data_files 에 absolute file number
    (file_id) 와 함께 relative file number (relative_fno) 를
    가지고 있다.
    v$datafile 에는 아직 absolute file number (file#) 만을 가진다.
    backup 을 restore 하기 전에 hardware 의 문제를 fix 해야 할
    필요가 있을 수 있다. 만약 corruption 이 disk 불량에 의해
    발생하였다면, backup 받아둔 datafile 을 문제가 없는 disk 에
    restore 하고, startup mount 한 후, 새로운 위치로 datafile
    rename 을 하고 recover 한다.
    만약 해당 datafile 이 system tablespace 에 속하지 않는다면
    offline tablespace recovery 도 가능하다.
    2. backup datafile 을 restore 하고 recover 하지 않을 것이라면
    우선, 어떤 object 에서 corruption 이 발생하였는지 확인해야
    한다.
    다음의 SQL 문을 이용한다.
    SELECT owner, segment_name, segment_type, relative_fno
    FROM dba_extents
    WHERE file_id = f
    AND b BETWEEN block_id AND block_id + blocks - 1 ;
    3. 해당 segment 가 non-data dictionary index라면, 해당 index를
    drop 한 후 재생성한다.
    4. 해당 segment 가 table 이라면, corruption 이 발생한 block 의
    data 는 소실된 것이다.
    5. 만약 해당 table 에 대한 최근의 export dump file이 존재한다면,
    해당 table 을 drop 한 후 import 함으로써 복구할 수 있다.
    최근의 export dump file 이 없거나 이를 export 받을 수 있는
    최근의 backup 이 없다면 다음과 같은 방법을 이용할 수 있다.
    6. corruption 이 발생한 non-clustered table 에서 corrupted
    block 을 access 하지 않고 나머지 data 들을 select 할 수
    있도록 ROWID 를 이용할 수 있다. non-clustered table의 모든
    row 들은 해당 row 의 물리적인 주소를 가리키는 고유한 ROWID를
    갖는다(해당 row가 여러 block에 조각이 나 있다면 첫번째 조각에
    대한 주소). clustered table 인 경우에는 서로 다른 table 의
    data 들이 같은 block 에 존재할 수 있으며, 같은 ROWID 를 가질
    수 있다.
    Oracle 은 index 를 구성하기 위하여 내부적으로 ROWID 를 사용한다.
    따라서 where 절에 ROWID 를 사용하여 select 하면 강제로 range
    scan 를 할 수 있다.
    Oracle8 에서는 이를 위하여 ROWID hint 를 사용할 필요가
    없어졌다.
    ROWID 를 이용하여 table 로부터 data 를 추출하기
    예제로써 ACCT_NO, PERSON, WEEKNO 등의 column 으로 구성된
    SCOTT user의 EXAMPLE 이라는 table 이 있다고 가정한다.
    이때, ORA-1578 "ORACLE data block corrupted (file # 5,
    block # 2) 가
    발생하였다고 가정하자.
    ROWID in Oracle8 :
    Oracle8 에서의 ROWID 는 'OOOOOOFFFBBBBBBSSS' format 을 가진다.
    OOOOOO = data object number
    Oracle7 의 object_id 와는 별도로 segment 의 id 를 갖는다.
    dba_objects 의 data_object_id 에서 확인가능
    FFF = relative file number
    BBBBBB = block number
    SSS = row number
    Oracle8에서의 ROWID 는 absolute file number 가 아닌 relative
    file number 를 갖는다는 점에 주목해야 한다.
    relative file number 는 tablespace 에 대해 상대적이며
    (tablespace마다 첫번째, 두번째, 세번째 datafile 을 가질 수
    있음을 의미) absolute file number 는 전체 database 내에서
    고유하다. 두개의 서로다른 file 들이 동일한 relative file
    number를 가질 수 있다.
    만약 EXAMPLE table 에서 ACCT_NO, ROWID 를 select하면 다음과
    같은 결과가 나올 수 있다.
    ACCT_NO ROWID
    12345 AAAAh3AAGAAACJAAAA
    19283 AAAAh3AAGAAACJAAAB
    22345 AAAAh4AAFAAAAADAAA
    60372 AAAAh4AAFAAAAADAAB
    33456 AAAAh5AAEAAAAIuAAA
    29473 AAAAh5AAEAAAAIuAAB
    이러한 format 을 extended ROWID character format 이라고
    지칭한다.
    extended ROWID 는 number 이므로 substr 함수를 이용하여
    extended ROWID 로부터 일부를 떼어낼 수 없다.
    ROWID 를 생성하기 위해서는 모든 component 를 알아야 한다.
    그런다음, DBMS_ROWID package 의 function 을 이용하여 ROWID 를
    생성할 수 있다.
    function rowid_create(rowid_type IN number,
    object_number IN number,
    relative_fno IN number,
    block_number IN number,
    row_number IN number)
    return rowid;
    pragma RESTRICT_REFERENCES(rowid_create,WNDS,RNDS,WNPS,RNPS);
    -- rowid_type - type (restricted=0/extended=1)
    -- object_number - data object number
    (rowid_object_undefined for )
    -- restricted
    -- relative_fno - relative file number
    -- block_number - block number in this file
    -- file_number - file number in this block
    corruption 이 발생한 block 의 data object number 를 알기
    위해서는 dba_objects 를 조회한다.
    SELECT data_object_id FROM dba_objects
    WHERE owner = 'SCOTT'
    AND object_name = 'EXAMPLE' ;
    DATA_OBJECT_ID
    2168
    우리는 이미, 위에서 사용한 다음의 SQL 에 의해서 relative file
    number 를 알고 있다.
    SELECT owner, segment_name, segment_type, relative_fno
    FROM dba_extents
    WHERE file_id = 5
    AND 2 BETWEEN block_id AND block_id + blocks - 1 ;
    OWNER SEGMENT_NAME SEGMENT_TYPE RELATIVE_F
    SCOTT EXAMPLE TABLE 5
    corruption 이 발생한 block 이 2이므로, block# 2 이전의 access
    가능한 마지막 ROWID 는 block# 1 에 존재한다. 그리고 block# 2
    이후의 access 가능한 첫 ROWID 는 block# 3에 존재한다. block
    안에 몇개의 row number 가 존재할 지 모르므로 row number 0 을
    이용한다.
    이제 corrupted block 이전의 ROWID 와 이후의 ROWID 를 생성할
    준비가 끝났다.
    corrupted block 이전의 ROWID :
    SELECT DBMS_ROWID.ROWID_CREATE(1,2168,5,1,0) FROM example ;
    DBMS_ROWID.ROWID_C
    AAAAh4AAFAAAAABAAA
    corrupted block 이후의 ROWID :
    SELECT DBMS_ROWID.ROWID_CREATE(1,2168,5,3,0) FROM example ;
    DBMS_ROWID.ROWID_C
    AAAAh4AAFAAAAADAAA
    다음으로, EXAMPLE table 과 같은 spec 으로 table 을 하나 만든다.
    CREATE TABLE temp AS SELECT * FROM example WHERE 1=2;
    그리고 corrupted block 이외의 block 에서 data 를 추출하여
    insert 한다.
    INSERT INTO temp SELECT * FROM example
    WHERE ROWID <= 'AAAAh4AAFAAAAABAAA';
    INSERT INTO temp SELECT * FROM example
    WHERE ROWID >= 'AAAAh4AAFAAAAADAAA';
    이후 원본 table 을 drop 하고, TEMP 를 rename 한다.
    7. 만약 data dictionary 에 속하는 table, index 또는 rollback
    segment에 corrupted block 이 발생하였다면 Oracle Support 의
    지원을 받는다.
    8. 일반적으로, ORA-1578 은 hardware 의 문제때문에 유발된다.
    하지만 만약에 ORA-600[3374] 가 발생한다면 memory 상에서
    corruption 이 발생한 경우이다.
    이 경우 database 를 restartup 하면 문제가 해결될 수 있다.
    Reference Documents
    --------------------

    Hello,
    Please check the link i posted.
    Example: Detecting Corruption
    The CHECK_OBJECT procedure checks the specified object, and populates the repair table with information about corruptions and repair directives. You can optionally specify a range, partition name, or subpartition name when you want to check a portion of an object.
    Validation consists of checking all blocks in the object that have not previously been marked corrupt. For each block, the transaction and data layer portions are checked for self consistency. During CHECK_OBJECT, if a block is encountered that has a corrupt buffer cache header, then that block is skipped.
    The following is an example of executing the CHECK_OBJECT procedure for the scott.dept table.
    SET SERVEROUTPUT ON
    DECLARE num_corrupt INT;
    BEGIN
    num_corrupt := 0;
    DBMS_REPAIR.CHECK_OBJECT (
    SCHEMA_NAME => 'SCOTT',
    OBJECT_NAME => 'DEPT',
    REPAIR_TABLE_NAME => 'REPAIR_TABLE',
    CORRUPT_COUNT => num_corrupt);
    DBMS_OUTPUT.PUT_LINE('number corrupt: ' || TO_CHAR (num_corrupt));
    END;
    SQL*Plus outputs the following line, indicating one corruption:
    number corrupt: 1

  • Block corruption error

    Hi,
    We are facing block corruption error file system file. I rtied to identify the corrupted object using dba_extents but that query is also giving the block corruption error for the same block. we are running the database in noarchivelog mode and we don't have backup.
    please suggest the way how can i solve this corruption error?
    Thanks in advance.
    Regards
    Chirag

    you can use dbverify to check which blocks are corrputed and see below to know how to solve it http://www.google.co.in/search?hl=en&q=how+to+resolve+block+corruption%2Boracle&btnG=Search&aq=f&aqi=&aql=&oq=&gs_rfai=

  • Database Block Corruption

    Dear Experts,
    In our BW system, from the alert log we have found that one oracle block was corrupted.
    > ORA-01578: ORACLE data block corrupted (file # 137, block #
    > 516877)#ORA-01110: data file 137:
    > '/oracle/PBP/sapdata1/sr3_121/sr3.data121'#ORA-26040: Data
    > block was loaded using the NOLOGGING option
    Database error 1578
    Database error 1578 at FET
    > ORA-01578: ORACLE data block corrupted (file # 137, block #
    > 516877)#ORA-01110: data file 137:
    > '/oracle/PBP/sapdata1/sr3_121/sr3.data121'#ORA-26040: Data
    > block was loaded using the NOLOGGING option
    Database error 1578
    From the SAP Market place we have found one KBA (1812719 - Avoid NOLOGGING during the index creation) which says that it was not really a corruption and it can be cleared by rebuilding the index.
    Can any one please help us how to find the index present in that block. I have tried with below command which returns no rows.
    SQL> select segment_name, partition_name, segment_type, block_id, blocks from dba_extents where (516877 between block_id and (block_id + blocks - 1)) and file_id = 137 and rownum < 2;
    no rows selected
    SQL>
    Please suggest how to find the index for rebuilding the same for clearing the corruption.
    Thanks
    Suresh

    Hi Suresh,
    Kindly check SAP Notes  365481 - Block corruptions
    1559652 - How to deal with block corruptions on Oracle
    923919 - Advanced Oracle block checking features
    Regards,
    Gaurav

Maybe you are looking for

  • Multiple users/devices on one PC

    We have three devices in our household, all identified by the same apple user id and password. (probably the first mistake.) The PC recognizes the three separate devices, but I cannot sync my device (iphone 4s) without getting all of my husband's app

  • Cost Element Group Delete

    Dear Buddy Please can any one tell me the procedure to delete the Cost Element Group Thanks In advance rgds BV

  • Product line

    Hi  all, Can any one suggest me  which table and field i have to check for product line ? If any have  softcopy regarding product line . please forward it to me.

  • Hi My photoshop CS6 is not supporting Photomerge

    Hi my photoshop cs6 is not supporting for photomerge, while i am trying with it its showing error 46

  • ASM candidate disks not found

    Hi all, I am trying to install 2-node 11gR2 RAC on CentOS 5.6 using VMWare Fusion. I'm in the middle of Grid Infrastructure installation and while choosing the ASM diskgroups I don't see any candidate disks but when I click on all disks i can see the