mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-24 11:45:18 +03:00
25 lines
985 B
Diff
25 lines
985 B
Diff
From: Dermot Bradley <dermot_bradley@yahoo.com>
|
|
Date: Thu, 12 Nov 2020 14:05 +0000
|
|
Subject: [PATCH] cloud-utils: Make growpart call to flock work with Busybox
|
|
|
|
Change growpart's to call the flock command using the short option "-x"
|
|
rather than the long option "--exclusive" as the short option works with
|
|
both util-linux's flock as well as Busybox's flock. This means that the
|
|
cloud-utils-growpart package can have the util-linux dependency removed.
|
|
|
|
Submitted upstream as PR #29.
|
|
|
|
---
|
|
|
|
diff -aur a/bin/growpart b/bin/growpart
|
|
--- a/bin/growpart
|
|
+++ b/bin/growpart
|
|
@@ -162,7 +162,7 @@
|
|
# Do not use --nonblock or --timeout as udev may be already processing
|
|
# the disk and we must wait until it has released the disk to
|
|
# proceed. Failure to obtain exclusive lock is fatal to growpart.
|
|
- rq flock flock --exclusive $FLOCK_DISK_FD ||
|
|
+ rq flock flock -x $FLOCK_DISK_FD ||
|
|
fail "Error while obtaining exclusive lock on $DISK"
|
|
debug 1 "FLOCK: $disk: obtained exclusive lock"
|
|
}
|