You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
915 B
27 lines
915 B
From 1175816c301dfc88f6ef4ecc009e1475a0d5362d Mon Sep 17 00:00:00 2001 |
|
From: Harald Hoyer <harald@redhat.com> |
|
Date: Fri, 16 May 2014 13:33:33 +0200 |
|
Subject: [PATCH] nbd/nbdroot.sh: call nbd-client with "--systemd-mark" |
|
|
|
otherwise nbd-client will get killed by systemd |
|
|
|
(cherry picked from commit 056a3f2427b6747d83fc48c5d1e3f85b4058c18f) |
|
--- |
|
modules.d/95nbd/nbdroot.sh | 4 ++++ |
|
1 file changed, 4 insertions(+) |
|
|
|
diff --git a/modules.d/95nbd/nbdroot.sh b/modules.d/95nbd/nbdroot.sh |
|
index 2e9d9174..ddb38192 100755 |
|
--- a/modules.d/95nbd/nbdroot.sh |
|
+++ b/modules.d/95nbd/nbdroot.sh |
|
@@ -111,6 +111,10 @@ if [ "$root" = "block:/dev/root" -o "$root" = "dhcp" ]; then |
|
fi |
|
fi |
|
|
|
+if strstr "$(nbd-client --help 2>&1)" "systemd-mark"; then |
|
+ preopts="--systemd-mark $preopts" |
|
+fi |
|
+ |
|
nbd-client $preopts "$nbdserver" $nbdport /dev/nbd0 $opts || exit 1 |
|
|
|
# NBD doesn't emit uevents when it gets connected, so kick it
|
|
|