summaryrefslogtreecommitdiffstats
path: root/core/modules/run-virt
diff options
context:
space:
mode:
authorJonathan Bauer2019-02-13 11:44:36 +0100
committerJonathan Bauer2019-02-13 11:44:36 +0100
commit76bc7507fa68dd2d7c5d0fd3e29d71f465762031 (patch)
treebd9297891d7ff2b1fe1a2f930fad4b3f18bc3ee9 /core/modules/run-virt
parent[kernel] build ethernet drivers as modules (diff)
downloadmltk-76bc7507fa68dd2d7c5d0fd3e29d71f465762031.tar.gz
mltk-76bc7507fa68dd2d7c5d0fd3e29d71f465762031.tar.xz
mltk-76bc7507fa68dd2d7c5d0fd3e29d71f465762031.zip
[run-virt] respect SLX_DNBD3_COW_DEVICE
instead of hardcoded /dev/mapper/root
Diffstat (limited to 'core/modules/run-virt')
-rw-r--r--core/modules/run-virt/data/opt/openslx/vmchooser/run-virt-includes/vmchooser_runvirt_functions.inc8
1 files changed, 5 insertions, 3 deletions
diff --git a/core/modules/run-virt/data/opt/openslx/vmchooser/run-virt-includes/vmchooser_runvirt_functions.inc b/core/modules/run-virt/data/opt/openslx/vmchooser/run-virt-includes/vmchooser_runvirt_functions.inc
index 7a8dad60..932c4aad 100644
--- a/core/modules/run-virt/data/opt/openslx/vmchooser/run-virt-includes/vmchooser_runvirt_functions.inc
+++ b/core/modules/run-virt/data/opt/openslx/vmchooser/run-virt-includes/vmchooser_runvirt_functions.inc
@@ -483,9 +483,11 @@ dir_on_tmpfs() {
return $?
done
# NG: check if / is fully backed by hard drive
- local dmsetup_conf="/run/openslx/dmsetup.conf"
- if [ -s "$dmsetup_conf" ]; then
- grep -qE '^/dev/mapper/root\s+/\s+type=0' "$dmsetup_conf"
+ local dmsetup_state="/run/openslx/dmsetup.state"
+ if [ -s "$dmsetup_state" ]; then
+ local dnbd3_cow_dev="$SLX_DNBD3_DEVICE_COW"
+ [ -z "$dnbd3_cow_dev" ] && dnbd3_cow_dev="/dev/mapper/root"
+ grep -qE "^${dnbd3_cow_dev}\s+/\s+type=0" "$dmsetup_state"
return $?
fi
# else assume old-gen were / was in RAM