Question

Block corruption in oracle table

Asked by: Don_Rafael

How to fix block corruption in oracle Table of SAP system

This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.

Subscribe now for full access to Experts Exchange and get

Instant Access to this Solution

  • Plus...
  • 30 Day FREE access, no risk, no obligation
  • Collaborate with the world's top tech experts
  • Unlimited access to our exclusive solution database
  • Never be left without tech help again

Subscribe Now

Asked On
2009-05-27 at 01:16:37ID24440642
Tags

SAP ORACLE Block corruption table

Topics

SAP ERP

,

Oracle 10.x

Participating Experts
1
Points
500
Comments
7

Trusted by hundreds of thousands everyday for fast, accurate and reliable tech support.

  • "The time we save is the biggest benefit of Experts Exchange to Warner Bros. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange." Mike Kapnisakis, Warner Bros.
  • "Our team likes having a resource that is more secure than just using Google and most experts using this service really know their stuff. It's nice to look here first versus using Google." Dayna Sellner, Lockheed Martin
  • "Anytime that I've been stumped with a problem, 9 out of 10 times Experts Exchange has either the accepted solution or an open discussion of the potential solution to the problem." Kenny Red, eBay Inc.

See what Experts Exchange can do for you.

Got a question?

We've got the answer.

Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.

Screenshot of Experts Exchange Knowledgebase

Need individual assistance?

Our experts are ready to help.

If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.

Screenshot of Experts Exchange Knowledgebase

Want to learn from the best?

Read articles from industry experts.

Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.

Screenshot of an Article

Working on a long term project?

Store your work and research.

Save solutions to your questions, answers you’ve discovered through searching plus helpful articles in your personal knowledgebase for easy future access.

Screenshot of Experts Exchange Knowledgebase

Access the answers to your technology questions today.

Subscribe Now

30-day free trial. Register in 60 seconds.

What Makes Experts Exchange Unique?

Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Trusted by the world's most respected brands.

image of each brand's logo

Faithfully serving IT professionals since 1996.

Experts Exchange Logo

Try it out and discover for yourself.

Subscribe Now

30-day free trial. Register in 60 seconds.

Related Solutions

  1. Exporting Tablens to check for block corruption
    I have a SAP system (31H) on Sun with an Oracle 8.0.6 DB. I am doing an export to check for block corruption on tables. My goal is to have the export command as part of a shell script to be ran on a block of tables. This is the export command: exp / log=/tmp/export.log di...
  2. ORA-01578: ORACLE data block corrupted
    Hi, When I selected against the tables gets the ora-1578, I have tried recovering datafiles using archivelogs. Still gets the ora-1578. I did ANALYZE TABLE. Here is result I got: ORA-01578: ORACLE data block corrupted (file #12, block#1635) ORA-01110: data file 12: 'G:\ORA...
  3. data block corrupted
    Hi! I have a problem. I have this message in my in -SID-ALRT.LOG Tue Jan 08 18:51:20 2002 Errors in file c:\users\trace\m300SMON.TRC: ORA-01578: ORACLE data block corrupted (file # 16, block # 187830) ORA-01110: data file 4: 'D:\DATABASE\RBS1T211.ORA' in m300MON.TRC *** ...
  4. Corrupt block found
    we have oracle 8i on linux (2 database on same server) error: Corrupt block relative dba : 0*03400353 file=13 blocknum=915 Fractured block found during buffer read data in bad block type : 0. format : 0 rdba :0*00000000
  5. ora-01578: oracle data block corrupted (file # 3, …
    We are getting following error on our oracle(Release 8.1.5.0.0) based application. Could somebody advise, how we can recover from this. ora-01578: oracle data block corrupted (file # 3, block # 15031) ORA-01110: data file 3: 'E:\ORACLE\ORADATA\OASYSEGC\USERS01.DBF' DBVERIF...
  6. oracle: data block corruption
    Dear Friends, I am trying to drop a view in oracle 8i, It giving me error: ORA-08102: index key not found, obj# 38004, dba 25175635 (2). I think my data base block has been corrupted. I don't require this view no more even i do n't require tables of this view. If i will not...

Free Tech Articles

  1. WARNING: 5 Reasons why you should NEVER fix a computer for free.
    It is in our nature to love the puzzle. We are obsessed. The lot of us. We love puzzles. We love the challenge. We thrive on finding the answer. We hate disarray. It bothers us deep in our soul. W...
  2. SCCM OSD Basic troubleshooting
    SCCM 2007 OSD is a fantastic way to deploy operating systems, however, like most things SCCM issues can sometimes be difficult to resolve due to the sheer volume of logs to sift through and the dispe...
  3. Migrate Small Business Server 2003 to Exchange 2010 and Windows 2008 R2
    This guide is intended to provide step by step instructions on how to migrate from Small Business Server 2003 to Windows 2008 R2 with Exchange 2010. For this migration to work you will need the fo...
  4. Create a Win7 Gadget
    This article shows you how to create a simple "Gadget" -- a sort of mini-application supported by Windows 7 and Vista. Gadgets can be dropped anywhere on the desktop to provide instant information, ...
  5. Outlook continually prompting for username and password
    There have been a lot of questions recently regarding Outlook prompting for a username and password whilst using Exchange 2007. There are a few reasons why this would happen and I will try to cover t...
  6. Backup Exchange 2010 Information Store using Windows Backup
    There seems to be quite a lot of confusion around the ability to backup Exchange 2010 using the built in Windows Backup feature. This stems from the omission of this feature prior to Exchange 2007 s...

Cloud Class Webinars

  1. Avoiding Bugs in Microsoft Access
    Alison Balter takes and in-depth look at avoiding bugs in Access. In this webinar you will learn about using the immediate window to debug your applications, invoking the debugger, using breakpoints to troubleshoot, stepping through code, setting the next statement to execute, ...
  2. Top 10 Best New Features in Visio 2010
    Scott Helmers gives live demonstrations of the top 10 new features in Visio 2010. This webinar will teach you how to create compelling diagrams by adding shapes to the page with a single click, linking the shapes in a diagram to data in Excel (or SQL Server, or SharePoint), ...
  3. IT Consultant Business Secrets Revealed
    Michael Munger, Experts Exchange tech pro and IT consultant, pulls back the curtain on his very successful businesses and answers question on every IT consultant and business owner should know about. He shares secrets on what he did to solve the 5 most common problems in IT, ...
  4. Disaster Recovery and Business Continuity
    Quest CTO, Mike Billon, gives an overview of the steps involved in building a dunamic disaster recovery plan. Through case studies and an examination of software/hardware tooles for monitoring and testing, you'll gain a better understandin of where you are, where you want ...
  5. Organize Your Visio Diagrams with Containers and Lists
    Scott Helmers uses cross functional flowcharts, wireframe diagrams, data graphic legends and seating charts to teach you: how to ustilize all three new structured diagram components in Visio 2010, the best practices for organizeing shapes in previous version of Visio, how to organize ...
  6. How to Us Objects, Properties, Events and Methods in Microsoft Access
    Alison Dalter gives an in-depbth look at objects, properties, events and methods in Microsoft Access. In this webinar you will learn about using the object browser, referring to objects, working with properties and methods, working with object variables, understanding the ...

Join the Community

Give a Little. Get a Lot.

Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.

Join the Community

Answers

 

by: mrjoltcolaPosted on 2009-05-27 at 15:31:34ID: 24488215

Sorry I did not see this earlier, it was back in my email queue.

Is it an error due to a media corruption? Is it a single block? View the trace file to see.

I would start with dbverify to determine the scope of the corruption. Rarely do I see a single block, it is usually wider scope and or due to disk problem.

Run: dbv file=/ora/oradata/ORA1/file.dbf


If the block is in a table and has data you want to recover, you will need a backup as well as archive logs to recover from. You must go to backups to fully recover.

Have you a configured backup procedure? Using RMAN? etc.?

I would personally choose to restore and recover the whole datafile, but if it is large, you can isolate and do block level. Provide more info on your backups and I will help.

 

by: Don_RafaelPosted on 2009-05-27 at 21:32:16ID: 24489743

Thanks for the Reply,

below is the error

BR0301E SQL error -1578 at location stats_tab_collect-20, SQL statement:
'BEGIN DBMS_STATS.GATHER_TABLE_STATS (OWNNAME => '"SAPBIW"', TABNAME => '"/BIC/B0001223000"', ESTIMATE_PERCENT => 10, METHOD_OPT => 'FOR ALL COLUMNS SIZE 1', DEGREE => NULL, CASC
ORA-01578: ORACLE data block corrupted (file # 6, block # 225333)
ORA-01110: data file 6: '/oracle/BD5/sapdata5/biw_5/biw.data5'
ORA-06512: at "SYS.DBMS_STATS", line 13159
ORA-06512: at "SYS.DBMS_STATS", line 13179
ORA-06512: at line 1
BR0886E Checking/collecting statistics failed for table SAPBIW./BIC/B0001223000

unfortunately we do not have good backups to restore.

I would like to know the procedure to fix the block corruptions if we do not have the backup..
like what options we have? also i head we can mark the corrupted block  so the table scan will not fail.
coz if do select * on the table ... it comes to point and errors out.

Also appreciate if you can point some instructions, doco to fix these errors if the corruption is in table.

Regards,
Rafael

 

by: mrjoltcolaPosted on 2009-05-27 at 22:11:57ID: 24489876

1) Backup your database right now! Before we start doing any sort of repairs. Do you know how to do this? I advise using RMAN.
2) Are you running in archivelog mode?

Below is how to run RMAN from the Oracle user, do a backup, then also validate the database. RMAN will then mark blocks that are corrupt into a corruption list that you can work with. You may have a tiny problem or a very large problem.

-- First do the backup. It MAY fail if you have media problems, we will see.
rman target /
RMAN> configure controlfile autobackup on;
RMAN> backup database;

-- If it fails

-- And then this step doesn't really create a backup, but validates blocks and populates the V$DATABASE_BLOCK_CORRUPTION view
RMAN> backup validate database;

-- Then login via sqlplus and check how many blocks are bad

sqlplus / as sysdba
select * from V$DATABASE_BLOCK_CORRUPTION;


3) You have no options to _recover_ blocks, since you have no backups. The only option is to mark blocks or rebuild the table while skipping them. You can play around with some SQL and try to select subsets of data from the table to see if certain ranges succeed. If, for example, the block corruption is in a given primary key range, if you query using a divide and conquer approach, you can narrow down where the problem is.

select * from table where id < 1000;
-- block error
select * from table where id < 500;
-- succeeds
select * from table where id >= 500 and id < 750;
-- etc. until you narrow down


You can also use DBMS_REPAIR to do all of the analysis, and mark the bad blocks.

http://download.oracle.com/docs/cd/B19306_01/server.102/b14231/repair.htm#i1006401

First, see how bad the problem is, then let me know.

 

by: Don_RafaelPosted on 2009-05-28 at 04:47:39ID: 24491875

Thanks for the update.

- I have backed it up using BRBACKUP successfully ( no media issues :) )
- also archive logs are turned on.
currently we are evaluating the possibility of rebuilding the table or use one of options as per ur update.

can you please also point me to or suggest steps to fix block corruptions in tables if i had successful backups.

thanks in advance.

 

by: mrjoltcolaPosted on 2009-05-28 at 05:04:00ID: 24491996

If you have archive logs, you can use Oracle LogMiner to recover all of the DML statements for all of the log history you have. So it depends on how far back you can / need to go.

If you had a successful RMAN backup, you could follow the steps above I listed

1) If you know the block # that is corrupt (assuming it is a single block)
RMAN> recover datafile 7 block 123444;

2) If there are many blocks, use:
RMAN> backup validate database;
RMAN> recover corruption list;

In some cases you might have to specify an until clause because even the most recent backup may still have block errors. This is why a good retention policy is important. It may take days, weeks or months to notice a block error. However, if using RMAN in the first place, you'll know about it fast. This is one reason why RMAN is preferred over user-managed backups.

 

by: Don_RafaelPosted on 2009-05-28 at 05:41:22ID: 31585672

I appreciate your help, was good starting point for us to look into possible solutions. We use SAP ORACLE tools such as BRtools.and TSM (tivoli) via backint to backup SAP ORACLE databases. RMan will be more advantages but we have to support what our client had already setup.  Thanks for your comments.

 

by: mrjoltcolaPosted on 2009-05-28 at 05:57:39ID: 24492425

I know Tivoli all too well, as I am ex-IBM.

RMAN is Oracle. SAP tools is not a replacement, RMAN is a core technology and is the preferred Oracle backup procedure. Most current 3rd party backup tools make use of RMAN, under the covers. Tivoli / TSM and RMAN do work together via the TSM API routines, so if your client's system is not using RMAN, TSM is not configured as well as it could be. If they were, you would not be in this situation.

As for the B grade, I believe I answered every question you asked, so that is disappointing. Good luck.

20120131-EE-VQP-002

3 Ways to Join

30-Day Free Trial

The Experts

98% positive feedback on 31,087 answers since March 2000. angeliii is a Microsoft Most Valuable Professional for his work with MS SQL Server & Develoment.

He has also proven his knowledge of Visual Basic Programming, PHP Scripting and Oracle Databases.

The Experts

97% positive feedback on 10,752 answers since July 2000. lrmoore has more than 18 years experience in the networking industry.

The six-time Mircosoft MVPs specialties include firewalls, virtual private networking, and network management.

Testimonials

"...and excellent source for support... Kind of like having your very own IT dept." Electriciansnet

Testimonials

"I was apprehensive at signing up at first. However... it has already made my life as an IT administrator much easier." JaCrews

Testimonials

"WOW! You guys have great, active, and knowledgeable people on here." moore50

Business Clients

Business Clients

In the Press

"If you’ve got a question... Experts Exchange can supply an answer.”

In the Press

"...an invaluable aid for both IT professionals and those who require tech support."

In the Press

"where IT professionals provide quick answers on just about any topic"

Business Account Plans

Loading Advertisement...