How to do a consistency check of oracle database

oracle

I am looking for a command like fschek or something similar for oracle to make sure that the indexing is proper .
I am doing a HP UX server installation and there was some error while installing some depots , now I force removed that but I want to do a consistency check and then proceed with the installation .

Basically I want to Check Database Integrity of my db and looking for a simple xommand like fscheck !

Best Answer

SHORT EXPLAINATION: The way Oracle works in internal redundancy, IF the database can startup (from nomount to mount to open) without problems, AND all files appear present in v$datafile (none are marked "MISSING") then you should be ok.

STEPS: I have found the easiest way to "full scan" the database for broken objects (bad sectors/blocks, etc) would be a full export (and even further a full import into an empty shell instance). The expdp or exp with the FULL=Y flag, running as SYS should tell Oracle to extract EVERYTHING out of the database into a flat dump file. If you have problems in your extents (tables, indexes, etc) then it should show up then.

Of course all of this is assuming you have already done: select * from dba_objects where status = 'INVALID'; to make sure you don't have anything that it already knows is not right.

FURTHER INFO: With online redo logs, undo management, multiplexed controlfiles and the datafile headers themselves, the Oracle database is pretty good at making sure it is consistent.