You’ve unmounted the ASM diskgroup, disabled it, removed the volumes from the masking view and you’ve rescanned the SCSI bus.. yet Powerpath still will not remove the paths…
Sometimes ASM has trouble letting go…
This can be a frustration to DBAs looking to remove unneeded ASM diskgroups from a host.
Trying to use powermt check dev=all let’s us know the path is dead, but that is cannot remove it, because it is in use. Oh, and its also unknown. Helpful!
[root@racn1 ~]# powermt check dev=all
Warning: symm device path unknown is currently dead.
Do you want to remove it (y/n/a/q)? a
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
ERROR: Cannot remove device that is in use: unknown
If we connect to the ASM instance and check our disks and diskgroups, we find that there numerous CLOSED disks. In this example we migrated the diskgroups to new volumes from a different array and the older disks are no longer used by ASM.
select vad.name as disk_name, vag.name as diskgroup_name, vad.mount_status, vad.path from v$asm_disk vad, v$asm_diskgroup vag where vad.group_number = vag.group_number(+);
DISK_NAME DISKGROUP_NAME MOUNT_STAUS PATH
------------------- -------------------- ----------- ---------------------------
CLOSED AFD:REDO2
CLOSED AFD:DATA3
CLOSED AFD:REDO4
CLOSED AFD:OCR2
CLOSED AFD:OCR1
CLOSED AFD:OCR3
CLOSED AFD:REDO1
CLOSED AFD:DATA2
CLOSED AFD:DATA1
CLOSED AFD:DATA5
CLOSED AFD:REDO3
CLOSED AFD:DATA6
CLOSED AFD:DATA4
In order to prompt ASM to drop these dead disks, we need to invoke the following command:
[root@racn1 ~]$ asmcmd afd_refresh
Now if we check ASM we should find that all CLOSED disks are gone. We can now tell Powerpath to clean up:
[root@racn1 ~]# powermt check dev=all
Warning: symm device path unknown is currently dead.
Do you want to remove it (y/n/a/q)? a
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
Warning: symm device path unknown is currently dead.
[root@racn1 ~]# powermt check dev=all
[root@racn1 ~]#
