Drop 'Zombie' diskgroup


View all mounted asm_diskgroups in the ASM instance
SYS@+ASM>select NAME,STATE from v$asm_diskgroup
2 /

NAME STATE
------------------------------ -----------
DATA2 MOUNTED
DATA3 MOUNTED
DATADG MOUNTED
View all defined asm_diskgroups in the current ASM instance
SYS@+ASM>show parameter disk

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
asm_diskgroups string BBXDG, DATADG, BBXDG3, BBXDG2,
BBXL7, BBXL7REDO, BBXL7ARCHIV
E
, DATA2, BBXL7512, BBXL74096,
BBXSTORAGE, L7BBX4096, BBXL7S
B, BBXL7RAWDG, TEST, BBX7ONLIN
ELOG, BBX7CONTROLFILE, BBXL7RA
WASM
, DATA3, BBXL7ASM512, BBX_
SP03, BBX_FDB

asm_diskstring string /dev/raw/raw*
Change spfile only to the mounted diskgroups
SYS@+ASM>alter system set asm_diskgroups='DATA2','DATA3','DATADG';

System altered.
Verify the change
SYS@+ASM>show parameter disk

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
asm_diskgroups string DATA2, DATA3, DATADG
asm_diskstring string /dev/raw/raw*
View all defined asm_diskgroups in the spfile
SYS@+ASM>show spparameter disk

SID NAME TYPE VALUE
-------- ----------------------------- ----------- ----------------------------
+ASM asm_diskgroups string BBX7CONTROLFILE
+ASM asm_diskgroups string BBX7ONLINELOG
+ASM asm_diskgroups string BBXDG
+ASM asm_diskgroups string BBXDG2
+ASM asm_diskgroups string BBXDG3
+ASM asm_diskgroups string BBXL7
+ASM asm_diskgroups string BBXL74096
+ASM asm_diskgroups string BBXL7512
+ASM asm_diskgroups string BBXL7ARCHIVE
+ASM asm_diskgroups string BBXL7ASM512
+ASM asm_diskgroups string BBXL7RAWASM
+ASM asm_diskgroups string BBXL7RAWDG
+ASM asm_diskgroups string BBXL7REDO
+ASM asm_diskgroups string BBXL7SB
+ASM asm_diskgroups string BBXSTORAGE
+ASM asm_diskgroups string BBX_FDB
+ASM asm_diskgroups string BBX_SP03
* asm_diskgroups string DATA2
+ASM asm_diskgroups string DATA2
+ASM asm_diskgroups string DATA3
* asm_diskgroups string DATA3
+ASM asm_diskgroups string DATADG
* asm_diskgroups string DATADG
+ASM asm_diskgroups string L7BBX4096
+ASM asm_diskgroups string TEST
* asm_diskstring string /dev/raw/raw*
Change spfile to the mounted diskgroups for the specific +ASM instance
SYS@+ASM>alter system set asm_diskgroups='DATA2','DATA3','DATADG' scope=spfile sid='+ASM';

System altered.
Verify the change
SYS@+ASM>show spparameter disk

SID NAME TYPE VALUE
-------- ----------------------------- ----------- ----------------------------
+ASM asm_diskgroups string DATA2
* asm_diskgroups string DATA2
* asm_diskgroups string DATA3
+ASM asm_diskgroups string DATA3
+ASM asm_diskgroups string DATADG
* asm_diskgroups string DATADG
* asm_diskstring string /dev/raw/raw*
View all defined asm_diskgroups in the Grid Infrastructure
[12:05:12 oracle@e11lora7:~/scripts +ASM ] $ crsctl stat res -t
--------------------------------------------------------------------------------
NAME TARGET STATE SERVER STATE_DETAILS
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.BBX7CONTROLFILE.dg
ONLINE OFFLINE e11lora7
ora.BBXDG3.dg
ONLINE OFFLINE e11lora7
ora.BBXL7.dg
ONLINE OFFLINE e11lora7
ora.BBXL7512.dg
ONLINE OFFLINE e11lora7
ora.BBXL7ARCHIVE.dg
ONLINE OFFLINE e11lora7
ora.BBXL7ASM512.dg
ONLINE OFFLINE e11lora7
ora.BBXL7REDO.dg
ONLINE OFFLINE e11lora7
ora.BBXL7SB.dg
ONLINE OFFLINE e11lora7
ora.BBXSTORAGE.dg
ONLINE OFFLINE e11lora7
ora.BBX_FDB.dg
ONLINE OFFLINE e11lora7
ora.BBX_SP03.dg
ONLINE OFFLINE e11lora7
ora.DATA2.dg
ONLINE ONLINE e11lora7
ora.DATA3.dg
ONLINE ONLINE e11lora7
ora.DATADG.dg
ONLINE ONLINE e11lora7
ora.L7BBX4096.dg
ONLINE OFFLINE e11lora7
ora.LISTENER.lsnr
ONLINE ONLINE e11lora7
ora.asm
ONLINE ONLINE e11lora7 Started
ora.ons
OFFLINE OFFLINE e11lora7
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.bdb.db
1 ONLINE OFFLINE Instance Shutdown
ora.cssd
1 ONLINE ONLINE e11lora7
ora.diskmon
1 OFFLINE OFFLINE
ora.evmd
1 ONLINE ONLINE e11lora7
ora.fdb.db
1 ONLINE OFFLINE
ora.hdb.db
1 ONLINE OFFLINE Instance Shutdown
ora.rpadb.db
1 ONLINE OFFLINE
Trying to remove unnecessary diskgroup diskgroup
[12:06:39 oracle@e11lora7:~/scripts +ASM ] $ srvctl remove diskgroup -g BBX_FDB
PRCA-1002 : Failed to remove CRS resource ora.BBX_FDB.dg for ASM Disk Group BBX_FDB
PRCR-1028 : Failed to remove resource ora.BBX_FDB.dg
PRCR-1072 : Failed to unregister resource ora.BBX_FDB.dg
CRS-0222: Resource 'ora.BBX_FDB.dg' has dependency error.
Checking which database is configured to depend on the diskgroup
[12:08:20 oracle@e11lora7:~/scripts +ASM ] $ srvctl config database -d hdb
Database unique name: hdb
Database name: hdb
Oracle home: /oracle/app/product/11.2.0/dbhome
Oracle user: oracle
Spfile: +DATA3/hdb/spfilehdb.ora
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Database instance: hdb
Disk Groups: DATA3,BBX_FDB
Services:
Removing the unnecessary diskgroup from the database (by omitting it)
[12:12:01 oracle@e11lora7:~/scripts +ASM ] $ srvctl modify database -d hdb -a "DATA3"
Verify the change
[12:12:07 oracle@e11lora7:~/scripts +ASM ] $ srvctl config database -d hdb
Database unique name: hdb
Database name: hdb
Oracle home: /oracle/app/product/11.2.0/dbhome
Oracle user: oracle
Spfile: +DATA3/hdb/spfilehdb.ora
Domain:
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Database instance: hdb
Disk Groups: DATA3
Services:
Trying again to remove unnecessary diskgroup diskgroup
[12:12:18 oracle@e11lora7:~/scripts +ASM ] $ srvctl remove diskgroup -g BBX_FDB
PRCA-1002 : Failed to remove CRS resource ora.BBX_FDB.dg for ASM Disk Group BBX_FDB
PRCR-1028 : Failed to remove resource ora.BBX_FDB.dg
PRCR-1072 : Failed to unregister resource ora.BBX_FDB.dg
CRS-0222: Resource 'ora.BBX_FDB.dg' has dependency error.
Trying again to remove but now with crsctl, maybe we will have a clue for this new dependency
[12:12:43 oracle@e11lora7:~/scripts +ASM ] $ crsctl delete resource 'ora.BBX_FDB.dg'
CRS-2730: Resource 'ora.fdb.db' depends on resource 'ora.BBX_FDB.dg'
CRS-4000: Command Delete failed, or completed with errors.
Checking if this database is also configured to use this diskgroup
[12:13:34 oracle@e11lora7:~/scripts +ASM ] $ srvctl config database -d fdb
Database unique name: fdb
Database name: fdb
Oracle home: /oracle/app/product/11.2.0/dbhome
Oracle user: oracle
Spfile:
Domain: axxana.local
Start options: open
Stop options: immediate
Database role: PRIMARY
Management policy: AUTOMATIC
Database instance: fdb
Disk Groups: DATA2,BBX_SP03,BBX_FDB
Services:
Removing the unnecessary diskgroup from the database (by omitting it)
[12:13:52 oracle@e11lora7:~/scripts +ASM ] $ srvctl modify database -d fdb -a "DATA2"
Trying to remove unnecessary diskgroup
[12:14:07 oracle@e11lora7:~/scripts +ASM ] $ srvctl remove diskgroup -g BBX_FDB
Verify the change
[12:14:21 oracle@e11lora7:~/scripts +ASM ] $ crsctl stat res -t
--------------------------------------------------------------------------------
NAME TARGET STATE SERVER STATE_DETAILS
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.BBX7CONTROLFILE.dg
ONLINE OFFLINE e11lora7
ora.BBXDG3.dg
ONLINE OFFLINE e11lora7
ora.BBXL7.dg
ONLINE OFFLINE e11lora7
ora.BBXL7512.dg
ONLINE OFFLINE e11lora7
ora.BBXL7ARCHIVE.dg
ONLINE OFFLINE e11lora7
ora.BBXL7ASM512.dg
ONLINE OFFLINE e11lora7
ora.BBXL7REDO.dg
ONLINE OFFLINE e11lora7
ora.BBXL7SB.dg
ONLINE OFFLINE e11lora7
ora.BBXSTORAGE.dg
ONLINE OFFLINE e11lora7
ora.BBX_SP03.dg
ONLINE OFFLINE e11lora7
ora.DATA2.dg
ONLINE ONLINE e11lora7
ora.DATA3.dg
ONLINE ONLINE e11lora7
ora.DATADG.dg
ONLINE ONLINE e11lora7
ora.L7BBX4096.dg
ONLINE OFFLINE e11lora7
ora.LISTENER.lsnr
ONLINE ONLINE e11lora7
ora.asm
ONLINE ONLINE e11lora7 Started
ora.ons
OFFLINE OFFLINE e11lora7
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.bdb.db
1 ONLINE OFFLINE Instance Shutdown
ora.cssd
1 ONLINE ONLINE e11lora7
ora.diskmon
1 OFFLINE OFFLINE
ora.evmd
1 ONLINE ONLINE e11lora7
ora.fdb.db
1 ONLINE OFFLINE
ora.hdb.db
1 ONLINE OFFLINE Instance Shutdown
ora.rpadb.db
1 ONLINE OFFLINE

Yehh.... :)

Comments

Popular posts from this blog

Data Guard - Changing IP Addresses

Install Oracle Internet Directory (OID) in Standalone mode

Fixing & Registering ORACLE_HOMES in Central Inventory