I must thank my fellow DBA Franky Weber Faust for his publication in his blog.
The goal here is to show that via asmcmd it is also possible to remove a disk group. Let’s briefly see how to do this.
We list the disk groups:
[oracle@london1 ~]$ asmcmd ASMCMD> lsdg State Type Rebal Sector Logical_Sector Block AU Total_MB Free_MB Req_mir_free_MB Usable_file_MB Offline_disks Voting_files Name MOUNTED EXTERN N 512 512 4096 4194304 40960 6900 0 6900 0 Y CONFIG/ MOUNTED EXTERN N 512 512 4096 4194304 12288 12156 0 12156 0 N DATA/
So we tried to delete the diskgroup:
ASMCMD> dropdg DATA ORA-15039: diskgroup not dropped ORA-15073: diskgroup DATA is mounted by another ASM instance (DBD ERROR: OCIStmtExecute)
Note that the message refers to the diskgroup being mounted on another instance.
Let’s then remotely dismount the diskgroup DATA that is also mounted on node 2 of the cluster:
[oracle@london1 ~]$ srvctl stop diskgroup -diskgroup DATA -n london2
Now it is mounted only on node 1:
[oracle@london1 ~]$ srvctl status diskgroup -diskgroup DATA Disk Group DATA is running on london1
We finally managed to remove it:
ASMCMD> dropdg DATA
When listing the diskgroups the DATA is no longer present:
ASMCMD> lsdg State Type Rebal Sector Logical_Sector Block AU Total_MB Free_MB Req_mir_free_MB Usable_file_MB Offline_disks Voting_files Name MOUNTED EXTERN N 512 512 4096 4194304 40960 6900 0 6900 0 Y CONFIG/