Applies to:
Oracle Server - Enterprise Edition - Version 9.0.1.4 to 10.2.0.4 [Release 9.0.1 to 10.2]Information in this document applies to any platform.
***Checked for relevance on 09-Jan-2013***
Symptoms
A database has been copied from filesystem to ASM storage, using the RMAN COPY command.
The copy was done via RMAN but the renaming of the database files was done via SQLPlus using
'alter database rename file 'X' to 'Y').
Now the following messages are being recorded in the alert.log:
Fri Sep 7 13:28:16 2007
datafilecopy header validation failure for file
+//datafile/system.751.632615407
datafilecopy header validation failure for file
+//datafile/sysaux.758.632615429
datafilecopy header validation failure for file
+//datafile/users.770.632616013
Additionally:
- RMAN LIST COPY command lists all the new ASM files as datafilecopies
- RMAN REPORT OBSOLETE command lists the new ASM files as 'obsolete'
- Incremental Merge Backup scripts believe the new ASM files to be new datafile copies
This problem can occur with or without the use of an rman catalog and affects relocation of any database file to ANY new location where the renaming is done via SQLPlus instead of using the RMAN SWITCH command.
Cause
The renaming of the datafiles was done via SQL Plus and NOT via RMAN with SWITCH command.
When SQLPlus is used to rename the files, only the view v$datafile is updated with the new name.
However, from an RMAN perspective:
When RMAN COPY is executed, new entries in rc_datafile_copy (v$datafile_copy) are inserted for the new files - at this point the new files are considered to be datafilecopies.
The RMAN SWITCH command will switch them round so that the new files are now in rc_datafile
(v$datafile) and the original files now become themselves datafilecopies in rc_datafile_copy
(v$datafile_copy).
If the renaming is done via SQLPlus then this switch doesnt occur: the result is rc_datafile
(v$datafile) and rc_datafile_copy (v$datafile_copy) both pointing to the new datafiles. Now
the LIVE files are considered to be both datafiles AND datafilecopies.
Solution
When using the RMAN COPY command to move datafiles to a new location (ASM or otherwise), do NOT rename the file via SQLPlus but use the RMAN SWITCH command instead (SWITCH DATAFILE ALL).
If SQLPlus has already been used to rename the files the rman metadata can be corrected as follows:
1. Confirm the name of the current datafiles:
RMAN>report schema;
2. Confirm the name of the datafile copies (this will show the SAME list of datafiles):
RMAN>list copy of database;
3. Remove the datafilecopy entries from the rman repository (this will NOT remove the physical
files but simply update the rman repository):
RMAN>change datafilecopy uncatalog;
You can get value from the list copy of database output - do this for every datafile
that is 'duplicated' in the list copy output.
4. Confirm that the copies have been removed:
RMAN>list copy of database;
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/7199859/viewspace-760961/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/7199859/viewspace-760961/