I have a Dell server connected to a Dell Unisphere storage, which provides a number of multipath devices.
It runs Oracle Linux 7, with UEK kernel
5.4.17-2136.304.4.1.el7uek.x86_64
.
This map isn't needed anymore, so I want to delete it:
mpathr (360060160982053009641546615b605b4) dm-17 DGC ,VRAID
size=6.0T features='2 queue_if_no_path retain_attached_hw_handler' hwhandler='1 alua' wp=rw
|-+- policy='service-time 0' prio=50 status=active
| |- 15:0:0:11 sdfv 131:16 active ready running
| |- 15:0:3:11 sdfy 131:64 active ready running
| |- 16:0:0:11 sdfz 131:80 active ready running
| |- 16:0:2:11 sdgb 131:112 active ready running
| |- 17:0:0:11 sdgd 131:144 active ready running
| |- 17:0:1:11 sdge 131:160 active ready running
| |- 18:0:2:11 sdgj 131:240 active ready running
| `- 18:0:3:11 sdgk 132:0 active ready running
`-+- policy='service-time 0' prio=10 status=enabled
|- 15:0:1:11 sdfw 131:32 active ready running
|- 15:0:2:11 sdfx 131:48 active ready running
|- 16:0:1:11 sdga 131:96 active ready running
|- 16:0:3:11 sdgc 131:128 active ready running
|- 17:0:2:11 sdgf 131:176 active ready running
|- 17:0:3:11 sdgg 131:192 active ready running
|- 18:0:0:11 sdgh 131:208 active ready running
`- 18:0:1:11 sdgi 131:224 active ready running
The hard requirement is that it should be done **online** (no reboot), it should have **no impact** on the services running on the server and there should be **no dangling remains** in the system. It should be made clean as if this device never existed.
The device was used with a file system which was served over NFS. I removed the /etc/exports
entry, reloaded NFS and unmounted the file system. lsblk
doesn't show it mounted anymore (mountpoint is empty):
root@bccdb:dev# lsblk /dev/mapper/mpathr
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
mpathr 252:17 0 6T 0 mpath
Next steps I was going to take is: delete multipath map, flush buffers on component devices, remove (unregister) these SCSI devices and remove the presentation on the storage. However, deleting the map fails:
root@bccdb:dev# multipathd del map 360060160982053009641546615b605b4
fail
I was even able to unload the filesystem driver (rmmod ext4
and rmmod jbd2
; the other filesystems on this server are XFS), so I am sure it is not filesystem which is still holding it.
There are no holders:
root@bccdb:dev# ls -la /sys/block/dm-17/holders/
итого 0
drwxr-xr-x 2 root root 0 май 27 12:20 .
drwxr-xr-x 10 root root 0 май 27 12:19 ..
dmsetup info shows zero open:
root@bccdb:dev# dmsetup info /dev/mapper/mpathr
Name: mpathr
State: ACTIVE
Read Ahead: 256
Tables present: LIVE
Open count: 0
Event number: 0
Major, minor: 252, 17
Number of targets: 1
UUID: mpath-360060160982053009641546615b605b4
I was already doing this previously on the very same server and two of its siblings, including that it was the same filesystem was on similar multipath disks from the same storage, and it went without such problem.
Why is it failing? How do I properly release it this time?
Asked by Nikita Kipriyanov
(1779 rep)
Jul 2, 2024, 08:32 AM
Last activity: Jul 2, 2024, 11:53 AM
Last activity: Jul 2, 2024, 11:53 AM