Work around LVM related race condition when using --force with LVM
If an "lvremove" is immediately followed by an "lvcreate" for an LV with the same name, "mkswap" (and maybe other commands) occasionally fail with "Device or resource busy". Work around it by using sync and sleep.
This commit is contained in:
@@ -23,6 +23,11 @@ Bug Fixes
|
||||
Thanks Santiago Vila for the bug report and patch! (Closes Debian
|
||||
bug report #764625)
|
||||
* Fixes typo found by Lintian.
|
||||
* Work around LVM related race condition when using --force with LVM:
|
||||
If an "lvremove" is immediately followed by an "lvcreate" for an LV
|
||||
with the same name, "mkswap" (and maybe other commands) occasionally
|
||||
fail with "Device or resource busy". Work around it by using sync
|
||||
and sleep.
|
||||
|
||||
Distribution Releases Changes
|
||||
-----------------------------
|
||||
|
||||
@@ -3066,6 +3066,10 @@ sub createLVMBits
|
||||
logprint(
|
||||
"Removing $lvm_disk - since we're forcing the install\n");
|
||||
runCommand("lvremove --force $lvm_disk", \%CONFIG);
|
||||
runCommand("sync", \%CONFIG);
|
||||
logprint(
|
||||
"Sleeping a few seconds to avoid LVM race conditions...\n");
|
||||
sleep(3);
|
||||
} else {
|
||||
fail("ERROR: Xen guest $CONFIG{'hostname'} appears to be running.\nAborting.\n");
|
||||
}
|
||||
|
||||
1
debian/changelog
vendored
1
debian/changelog
vendored
@@ -21,6 +21,7 @@ xen-tools (4.6.3~dev-1) UNRELEASED; urgency=medium
|
||||
+ Support situations where distributions (e.g. Squeeze) might be EoL,
|
||||
but its archive signing key is still not removed from the default
|
||||
keyring.
|
||||
+ Workaround LVM related race condition when using --force with LVM.
|
||||
* Declare compliance with Debian Policy 3.9.8. (No changes needed.)
|
||||
* Use NEWS.markdown as upstream changelog, don't install it as docs.
|
||||
* Switch many URLs (upstream and in packaging) to https:// and update
|
||||
|
||||
Reference in New Issue
Block a user