mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
blkdeactivate: fix endless loop if device(s) given and unable to umount/deactivate
The blkdeactivate script iterates over the list of devices if they're given as an argument and it tries to umount/deactivate them one by one. This iteration failed to proceed if any of the umount/deactivation was unsuccessful - there was a missing "shift" call to move to the next argument (device) for processing. As a result of this, the same device was tried again and again, causing an endless loop, never proceeding to the next device given.
This commit is contained in:
parent
c3f44a0c66
commit
b109bfc1ef
@ -1,5 +1,6 @@
|
|||||||
Version 2.02.104
|
Version 2.02.104
|
||||||
===================================
|
===================================
|
||||||
|
Fix endless loop for blkdeactivte <device>... if unable to umount/deactivate.
|
||||||
Add dev-block-<major>:<minor>.device systemd alias for complete PV tracking.
|
Add dev-block-<major>:<minor>.device systemd alias for complete PV tracking.
|
||||||
Use major:minor as short form of --major and --minor arg for pvscan --cache.
|
Use major:minor as short form of --major and --minor arg for pvscan --cache.
|
||||||
Remove 2>/dev/null from three lvm commands executed by vgimportclone.
|
Remove 2>/dev/null from three lvm commands executed by vgimportclone.
|
||||||
|
@ -323,7 +323,10 @@ deactivate_all() {
|
|||||||
$LSBLK_READ <<< "`$LSBLK --nodeps $1`"
|
$LSBLK_READ <<< "`$LSBLK --nodeps $1`"
|
||||||
|
|
||||||
# check if the device is not on the skip list already
|
# check if the device is not on the skip list already
|
||||||
test -z ${SKIP_DEVICE_LIST["$kname"]} || continue
|
test -z ${SKIP_DEVICE_LIST["$kname"]} || {
|
||||||
|
shift
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
deactivate
|
deactivate
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user