860523 wrote:If you are using ASM 11.2, I recommend you use the utility ASMCA to drop DISKGROUP.
I would like to drop a asm diskgroup in RAC? what is the correct procedure?
1.do I have to unmount the diskgroup first in the 2 nodes?
2. alter diskgroup xxx drop command to be run in the 2 nodes or just 1 node?Execute command only one ASM instance
3. after droping command, is there any other procdures to do?No.
any doc to follow?How To Add a New Disk(s) to An Existing Diskgroup on RAC (Best Practices). [ID 557348.1]
860523 wrote:You MUST remove (using DBCA) or move (using RMAN) all database stored on this diskgroup (if exists) before dropping DISKGROUP.
thank you very much. oracle 10.2, if I unmount the diskgroup, do I have to offline something or what is the procedure before alter disgroup xxx unmount?
If query above return rows you must shutdown all instance first and remove or move database to another DISKGROUP.
SQL> SELECT D.NAME,C.INSTANCE_NAME,C.DB_NAME,C.STATUS FROM GV$ASM_DISKGROUP D , GV$ASM_CLIENT C WHERE D.GROUP_NUMBER=C.GROUP_NUMBER AND D.NAME = '<DISKGROUP_NAME>'; no rows selected
3)Drop diskgroup from the ASM instance, which the diskgroup is still mounted
ALTER DISKGROUP <DISKGROUP_NAME> DISMOUNT;
DROP DISKGROUP <DISKGROUP_NAME>; -- If no files on DISKGROUP DROP DISKGROUP <DISKGROUP_NAME> INCLUDING CONTENTS; - If exits files on DISKGROUP
860523 wrote:I recommend you first of all check files on DISKGROUP. Indentify if this files is used by any databases. So I recommended you delete or move database (i.e: all files) before dropping Diskgroup. If no files on DISKGROUP then none databases use this DISKGROUP.
- if I unmount diskgroup on node1 and then after serveral hours I dismount this diskgroup in node 2 - just to make sure no errors and nothing is pointed to this diskgroup.
set linesize 200 col FULL_ALIAS_PATH for A70 select concat('+'||gname, sys_connect_by_path(aname, '/')) full_alias_path, system_created, alias_directory, file_type from ( select b.name gname, a.parent_index pindex, a.name aname, a.reference_index rindex , a.system_created, a.alias_directory, c.type file_type from v$asm_alias a, v$asm_diskgroup b, v$asm_file c where a.group_number = b.group_number and a.group_number = c.group_number(+) and a.file_number = c.file_number(+) and a.file_incarnation = c.incarnation(+) ) start with (mod(pindex, power(2, 24))) = 0 and rindex in ( select a.reference_index from v$asm_alias a, v$asm_diskgroup b where a.group_number = b.group_number and (mod(a.parent_index, power(2, 24))) = 0 and b.name = UPPER('&DG_NAME') ) connect by prior rindex = pindex;
- will there be error if I mount this diskgroup back to node 2 before I can drop it, (may be not in sync since the diskgroup is dismounted from 2 nodes at different times)?Does not matter which time or order that diskgroup was dismounted. It's mandatory the diskgroup be mounted in only one Instance before DROP.
860523 wrote:Of course yes.
since the diskgroup contains FRA, there is no datafile. so I just want to make sure.
If I dismount disks on 2 nodes are different times, will I be able to mount it back without error?