[oracle@testrac2 11204]$ sqlplus / as sysdba SQL*Plus: Release 11.2.0.4.0 Production on Wed Jan 16 18:50:03 2019 Copyright (c) 1982, 2013, Oracle. All ...
[oracle@testrac2 11204]$ sqlplus / as sysdba
SQL*Plus: Release 11.2.0.4.0 Production on Wed Jan 16 18:50:03 2019
Copyright (c) 1982, 2013, Oracle. All rights reserved.
Connected to an idle instance.
SQL> startup
ORA-00304: requested INSTANCE_NUMBER is busy
[grid@testrac1 ~]$ crs_stat -t -v
Name Type R/RA F/FT Target State Host
----------------------------------------------------------------------
ora.DATADG.dg ora....up.type 0/5 0/ ONLINE ONLINE testrac1
ora.GRIDDG.dg ora....up.type 0/5 0/ ONLINE ONLINE testrac1
ora....ER.lsnr ora....er.type 0/5 0/ ONLINE ONLINE testrac1
ora....N1.lsnr ora....er.type 0/5 0/0 ONLINE ONLINE testrac1
ora.asm ora.asm.type 0/5 0/ ONLINE ONLINE testrac1
ora.cvu ora.cvu.type 0/5 0/0 ONLINE ONLINE testrac1
ora.gsd ora.gsd.type 0/5 0/ OFFLINE OFFLINE
ora....network ora....rk.type 0/5 0/ ONLINE ONLINE testrac1
ora.oc4j ora.oc4j.type 0/1 0/2 ONLINE ONLINE testrac1
ora.ons ora.ons.type 0/3 0/ ONLINE ONLINE testrac1
ora.scan1.vip ora....ip.type 0/0 0/0 ONLINE ONLINE testrac1
ora.testrac.db ora....se.type 0/2 0/1 ONLINE ONLINE testrac1
ora....SM1.asm application 0/5 0/0 ONLINE ONLINE testrac1
ora....C1.lsnr application 0/5 0/0 ONLINE ONLINE testrac1
ora....ac1.gsd application 0/5 0/0 OFFLINE OFFLINE
ora....ac1.ons application 0/3 0/0 ONLINE ONLINE testrac1
ora....ac1.vip ora....t1.type 0/0 0/0 ONLINE ONLINE testrac1
ora....SM2.asm application 0/5 0/0 ONLINE ONLINE testrac2
ora....C2.lsnr application 0/5 0/0 ONLINE ONLINE testrac2
ora....ac2.gsd application 0/5 0/0 OFFLINE OFFLINE
ora....ac2.ons application 0/3 0/0 ONLINE ONLINE testrac2
ora....ac2.vip ora....t1.type 0/0 0/0 ONLINE ONLINE testrac2
檢查下環境變數,發現不是網上所說的環境變數的問題
[grid@testrac2 ~]$ env | grep ORACLE_SID
ORACLE_SID=+ASM2
[grid@testrac2 ~]$ ps -ef|grep oracle |grep ASM
grid 31099 1 0 2018 ? 00:00:00 oracle+ASM2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
grid 31171 1 0 2018 ? 00:00:00 oracle+ASM2_ocr (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
grid 31175 1 0 2018 ? 00:02:33 oracle+ASM2_asmb_+asm2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
grid 31318 1 0 2018 ? 00:00:09 oracle+ASM2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
[oracle@testrac2 ~]$ echo $ORACLE_SID
testrac2
SQL> select INST_ID ,INSTANCE_NUMBER ,INSTANCE_NAME from gv$instance;
INST_ID INSTANCE_NUMBER INSTANCE_NAME
---------- --------------- ------------------------------------------------
1 1 testrac1
SQL> select GROUP#,THREAD# from v$log;
GROUP# THREAD#
---------- ----------
1 1
2 1
3 1
SQL> select MEMBER from v$logfile;
MEMBER
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
+DATADG/testrac/onlinelog/group_1.257.995827307
+DATADG/testrac/onlinelog/group_2.258.995827307
+DATADG/testrac/onlinelog/group_3.259.995827309
SQL> alter database add logfile thread 2 ('+datadg','+datadg') size 100m;
Database altered.
SQL> alter database add logfile thread 2 ('+datadg','+datadg') size 100m;
Database altered.
SQL> alter database add logfile thread 2 ('+datadg','+datadg') size 100m;
Database altered.
SQL> select GROUP#,THREAD# from v$log;
GROUP# THREAD#
---------- ----------
1 1
2 1
3 1
4 2
5 2
6 2
6 rows selected.
SQL> alter database enable thread 2;
Database altered.
難道安裝時候沒勾選節點2,他說從節點1拷貝了一個參數文件,下麵的3個參數也沒改。。。能啟動才怪
#testrac2.instance_number=1
testrac2.instance_number=2
*.open_cursors=300
*.pga_aggregate_target=1649410048
*.processes=150
*.remote_listener='racscanip:1521'
*.remote_login_passwordfile='exclusive'
*.sga_target=4949278720
#testrac2.thread=1
testrac2.thread=2
#testrac2.undo_tablespace='UNDOTBS1'
testrac2.undo_tablespace='UNDOTBS2'
[oracle@testrac2 dbs]$ sqlplus / as sysdba
SQL*Plus: Release 11.2.0.4.0 Production on Wed Jan 16 19:34:42 2019
Copyright (c) 1982, 2013, Oracle. All rights reserved.
Connected to an idle instance.
SQL> startup pfile='/u01/app/oracle/11204/dbs/inittestrac2.ora';
ORACLE instance started.
Total System Global Area 4927172608 bytes
Fixed Size 2261648 bytes
Variable Size 1090522480 bytes
Database Buffers 3825205248 bytes
Redo Buffers 9183232 bytes
Database mounted.
Database opened.
SQL> select status from v$instance;
STATUS
------------------------------------
OPEN
SQL> select INST_ID ,INSTANCE_NUMBER ,INSTANCE_NAME from gv$instance;
INST_ID INSTANCE_NUMBER INSTANCE_NAME
---------- --------------- ------------------------------------------------
2 2 testrac2
1 1 testrac1
SQL>
可以了正常了。。。