首页 > 数据库 > Oracle > 修复受损的SYSAUX表空间
In this Document
| Goal |
| Solution |
| 1- RMAN Block Recovery |
| 2 - Restore and Recover the Corrupted Datafile(s) |
| 3 - Recreate the Corrupted Object |
| 4 - Export |
| References |
| This document is being delivered to you via Oracle Support's Rapid Visibility (RaV) process and therefore has not been subject to an independent technical review. |
How to fix/work-around a corrupted SYSAUX tablespace
SYSAUX was introduced in 10g to store all auxiliary database metadata related to Oracle options and features. This is a mandatory tablespace and cannot be dropped. Therefore it is important to have all objects in this tablespace accessible at all times.
To find out what is stored in this tablespace, look at V$SYSAUX_OCCUPANTS:
Throughout this document, we are assuming that the datafile 3, belonging to the SYSAUX tablespace, is corrupted.
RMAN block recovery is only possible if you have a backup and all archivelogs from prior to the time of the corruption. Further, block recovery is only available for Oracle Enterprise Edition.
a) check for corruption
RMAN> backup validate check logical tablespace SYSAUX;
or
b) Once the above RMAN validate is completed, all corruptions found will be written to this view:
c) If V$DATABASE_BLOCK_CORRUPTION returns more than one corrupted block, recover them
If you have a backup of the corrupted file(s), then restore and recover the datafile(s) from backup.
eg:
To identify the corrupted objects, please see Note 472231.1. Most indexes can be recreated but only certain tables in the SYSAUX tablespace can be recreated. Please contact Oracle Support if you wish to explore this path.
If all of the above options are exhausted, the last resort is to export the database, schema(s) or table(s), create a new database and import.
As long as the export views are accessible you should be able to perform either a database or schema level export.
If a tablespace level export works you might also consider using Transportable Tablespaces for recreating the database as documented in
Note:733824.1 HowTo Recreate a database using TTS (TransportableTableSpace)
Note: If all datafiles belonging to the SYSAUX are inaccessible then you can only perform export at the table level. Full and schema level export will not work as the export views in SYSAUX are no longer available. You will need to use traditional exp rather than expdp as expdp relies on objects in the SYSAUX tablespace.
eg:
Once exported, you can import this dump into a new database.
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/27661381/viewspace-1064130/ ,如需转载,请注明出处,否则将追究法律责任。