fix md stopping

This commit is contained in:
Tobias Powalowski 2022-01-26 21:51:14 +01:00
parent 5a267097c5
commit c86adb31c9

View file

@ -565,7 +565,7 @@ _stopmd()
if [[ "${DISABLEMD}" = "1" ]]; then if [[ "${DISABLEMD}" = "1" ]]; then
DIALOG --infobox "Disabling all software raid devices..." 0 0 DIALOG --infobox "Disabling all software raid devices..." 0 0
while read -r i; do while read -r i; do
mdadm --manage --stop "/dev/$(grep -q ^md "${i}" | sed -e 's# :.*##g')" > ${LOG} mdadm --manage --stop "/dev/$(grep ^md "${i}" | sed -e 's# :.*##g')" > ${LOG}
done < /proc/mdstat done < /proc/mdstat
DIALOG --infobox "Cleaning superblocks of all software raid devices..." 0 0 DIALOG --infobox "Cleaning superblocks of all software raid devices..." 0 0
for i in $(${_LSBLK} NAME,FSTYPE | grep "linux_raid_member$" | cut -d' ' -f 1); do for i in $(${_LSBLK} NAME,FSTYPE | grep "linux_raid_member$" | cut -d' ' -f 1); do