原来有一套RAC对RAC的dataguard环境、
后来系统迁移、主库被拿掉做其他系统了,
备库一直留存,没有使用
今天心血来潮想打开standby做测试环境
但是遭遇open 需要upgrade 以下是详细过程
[oracle@node5 ~]$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.4.0 - Production on Thu Mar 14 14:49:09 2013
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
Connected to an idle instance.
SQL> startup mount;
ORACLE instance started.
Total System Global Area 8606711808 bytes
Fixed Size 2097696 bytes
Variable Size 1543507424 bytes
Database Buffers 7046430720 bytes
Redo Buffers 14675968 bytes
Database mounted.
SQL>ALTER DATABASE RECOVER MANAGED STANDBY
2 DATABASE DISCONNECT FROM SESSION;
Database altered.
SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE CANCEL;
Database altered.
SQL> alter database open;
alter database open
*
ERROR at line 1:
ORA-01092: ORACLE instance terminated. Disconnection forced
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options
Thu Mar 14 14:52:04 2013
This instance was first to open
Picked broadcast on commit scheme to generate SCNs
Thu Mar 14 14:52:05 2013
SMON: enabling cache recovery
Thu Mar 14 14:52:05 2013
Errors in file /home/oracle/admin/xxx2s/udump/xxx2s1_ora_3710.trc:
ORA-00704: bootstrap process failure
ORA-39700: database must be opened with UPGRADE option
Thu Mar 14 14:52:05 2013
Error 704 happened during db open, shutting down database
USER: terminating instance due to error 704
Instance terminated by USER, pid = 3710
ORA-1092 signalled during: alter database open...
SQL> alter database open upgrade;
alter database open upgrade
*
ERROR at line 1:
ORA-16003: standby database is restricted to read-only access
failover
===============
SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE FINISH FORCE;
Database altered.
SQL> ALTER DATABASE COMMIT TO SWITCHOVER TO PRIMARY;
Database altered.
SQL> alter database open;
alter database open
*
ERROR at line 1:
ORA-01092: ORACLE instance terminated. Disconnection forced
Thu Mar 14 15:44:21 2013
Errors in file /home/oracle/admin/xxx2s/udump/xxx2s1_ora_31378.trc:
ORA-00704: bootstrap process failure
ORA-39700: database must be opened with UPGRADE option
Thu Mar 14 15:44:21 2013
Error 704 happened during db open, shutting down database
USER: terminating instance due to error 704
Thu Mar 14 15:44:21 2013
Errors in file /home/oracle/admin/xxx2s/bdump/xxx2s1_lms1_31213.trc:
ORA-00704: bootstrap process failure
Thu Mar 14 15:44:21 2013
Errors in file /home/oracle/admin/xxx2s/bdump/xxx2s1_lms0_31209.trc:
ORA-00704: bootstrap process failure
Thu Mar 14 15:44:21 2013
Errors in file /home/oracle/admin/xxx2s/bdump/xxx2s1_lmon_31205.trc:
ORA-00704: bootstrap process failure
Instance terminated by USER, pid = 31378
ORA-1092 signalled during: alter database open...
SQL> startup mount;
SQL> SELECT SWITCHOVER_STATUS,DATABASE_ROLE FROM V$DATABASE;
SWITCHOVER_STATUS DATABASE_ROLE
-------------------- ----------------
SESSIONS ACTIVE PRIMARY
=================================
SQL> alter database open upgrade;
alter database open upgrade
*
ERROR at line 1:
ORA-01092: ORACLE instance terminated. Disconnection forced
Thu Mar 14 15:47:38 2013
Thread 3 advanced to log sequence 2 (archiver wakeup)
Thu Mar 14 15:47:38 2013
Thread 4 advanced to log sequence 2 (archiver wakeup)
Thu Mar 14 15:47:38 2013
Thread 2 advanced to log sequence 3 (archiver wakeup)
Thu Mar 14 15:47:38 2013
Successfully onlined Undo Tablespace 1.
Thu Mar 14 15:47:38 2013
SMON: enabling tx recovery
Thu Mar 14 15:47:38 2013
Database Characterset is ZHS16GBK
Updating 10.2.0.3.0 NLS parameters in sys.props$
-- adding 10.2.0.4.0 NLS parameters.
Thu Mar 14 15:47:39 2013
Errors in file /home/oracle/admin/xxx2s/udump/xxx2s1_ora_751.trc:
ORA-39701: database must be mounted EXCLUSIVE for UPGRADE or DOWNGRADE
Error 39701 happened during db open, shutting down database
USER: terminating instance due to error 39701
Thu Mar 14 15:47:39 2013
Errors in file /home/oracle/admin/xxx2s/bdump/xxx2s1_lms1_530.trc:
ORA-39701: database must be mounted EXCLUSIVE for UPGRADE or DOWNGRADE
Thu Mar 14 15:47:39 2013
Errors in file /home/oracle/admin/xxx2s/bdump/xxx2s1_rbal_610.trc:
ORA-39701: database must be mounted EXCLUSIVE for UPGRADE or DOWNGRADE
Thu Mar 14 15:47:39 2013
Errors in file /home/oracle/admin/xxx2s/bdump/xxx2s1_lms0_526.trc:
ORA-39701: database must be mounted EXCLUSIVE for UPGRADE or DOWNGRADE
Instance terminated by USER, pid = 751
ORA-1092 signalled during: alter database open upgrade…
SQL> alter system set cluster_database=false scope=spfile;
System altered.
SQL> alter database open upgrade;
Database altered.
@?/rdbms/admin/catupgrd.sql
shutdown
@?/rdbms/admin/utlrp.sql
select count(1) from dba_objects where status='INVALID';
事后猜想
可能是上一个维护组只升级了主库