APPLIES TO: Oracle Database - Enterprise Edition - Version 11.1.0.7 and later Information in this document applies to any platform. ***Checked for relevance on 27-NOV-2015 *** SYMPTOMS NOTE: In the images and/or the document content below, the user information and environment data used represents fictitious data from the Oracle sample schema(s), Public Documentation delivered with an Oracle database product or other training material. Any similarity to actual environments, actual persons, living or dead, is purely coincidental and not intended in any manner. For the purposes of this document, the following fictitious environment is used as an example to describe the procedure: Database Name: PROD,V11P Disk Group Names: +BACKUP Directory Names: C:\ORA11G, C:\APP and all sub-directories Catalog Schema: RMAN ********** Possible Symptoms:
o Database was upgraded to 11.1.0.7.2
The database shows its in read write mode. ( open ) RMAN Resync catalog failing with errors:
o This problem can be caused by a recreate of the controlfile with resetlogs, and subsequent failure during the open resetlogs. That is, if recreating a controlfile with resetlogs option, but if there are any issues during the open resetlogs, leaving the database in this state reporting . ORA-16433: The database has not been opened in read-write mode . $ rman catalog rman/<password>@<catalog service> target sys/<password>@<target service>
Recovery Manager: Release 11.1.0.7.0 - Production on Mon Mar 15 10:58:49 2010
Copyright (c) 1982, 2007, Oracle. All rights reserved.
connected to target database: PROD (DBID=1078444404) connected to recovery catalog database
RMAN> resync catalog;
RMAN-00571: =========================================================== RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS =============== RMAN-00571: =========================================================== RMAN-03009: failure of resync command on default channel at 03/15/2010 10:58:56 ORA-16433: The database has not been opened in read-write mode
-Tried to open the database in read only then change it to read write. Same error
-Tried sql> 'alter database backup controlfile to trace' from sqlplus failed with the same error SQL> alter database backup controlfile to trace; alter database backup controlfile to trace * ERROR at line 1: ORA-16433: The database has not been opened in read-write mode CAUSE Bug 8422605 BACKUP CONTROLFILE TO TRACE GENERATES ORA-16433 AFTER 11.1.0.7 UPGRADE V1110: Status: 31,Could Not Reproduce. SOLUTION
1) Recreate the controlfile with NORESETLOGS option.
2) Recover database using this command:
SQL> recover database;
3) Open the database as follows:
SQL> alter database open;
# This will get you out of the read/write problem and allow the database to open Note: Since the 'alter database backup controlfile to trace' fail, then the controlfile need to be created from start if you don't have one already.
The following queries can be used to collect the information needed to recreate the controlfile while database is mounted: SQL> select name from v$datafile order by file#; SQL> select group#, member from v$logfile; SQL> select name, bytes from v$tempfile order by file#; Example of modified controlfile script:
-- -- Set #1. NORESETLOGS case -- -- The following commands will create a new control file and use it -- to open the database. -- Data used by Recovery Manager will be lost. -- Additional logs may be required for media recovery of offline -- Use this only if the current versions of all online logs are -- available. -- After mounting the created controlfile, the following SQL -- statement will place the database in the appropriate -- protection mode: -- ALTER DATABASE SET STANDBY DATABASE TO MAXIMIZE PERFORMANCE STARTUP NOMOUNT CREATE CONTROLFILE REUSE DATABASE "V11P" NORESETLOGS FORCE LOGGING ARCHIVELOG MAXLOGFILES 16 MAXLOGMEMBERS 3 MAXDATAFILES 100 MAXINSTANCES 8 MAXLOGHISTORY 292 LOGFILE
*** 2010-03-15 13:12:56.641 GROUP 1 'C:\APP\ORADATA\V11P\REDO01.LOG' SIZE 50M, GROUP 2 'C:\APP\ORADATA\V11P\REDO02.LOG' SIZE 50M, GROUP 3 'C:\APP\ORADATA\V11P\REDO03.LOG' SIZE 50M -- STANDBY LOGFILE DATAFILE 'C:\APP\ORADATA\V11P\SYSTEM01.DBF', 'C:\APP\ORADATA\V11P\SYSAUX01.DBF', 'C:\APP\ORADATA\V11P\UNDOTBS01.DBF', 'C:\APP\ORADATA\V11P\USERS01.DBF' CHARACTER SET WE8MSWIN1252 ; -- Commands to re-create incarnation table -- Below log names MUST be changed to existing filenames on -- disk. Any one log file from each branch can be used to -- re-create incarnation records. -- ALTER DATABASE REGISTER LOGFILE 'C:\ORA11G\ARCHIVE\V11P\1_1_708426060.ARC'; -- Recovery is required if any of the datafiles are restored backups, -- or if the last shutdown was not normal or immediate. RECOVER DATABASE -- All logs need archiving and a log switch is needed. ALTER SYSTEM ARCHIVE LOG ALL; -- Database can now be opened normally. ALTER DATABASE OPEN; -- Commands to add tempfiles to temporary tablespaces. -- Online tempfiles have complete space information. -- Other tempfiles may require adjustment. ALTER TABLESPACE TEMP ADD TEMPFILE 'C:\APP\ORADATA\V11P\TEMP01.DBF' REUSE; -- End of tempfile additions. |