[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#610377: [PATCH] Allow mounting a logical volume as /boot



tags 610377 + patch
thanks

The current code allows you to boot from a logical volume, but only if
/boot is on the / filesystem. This change permits having /boot on its own
logical volume.

Signed-off-by: dann frazier <dannf@debian.org>
---
 lib/auto-lvm.sh |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/lib/auto-lvm.sh b/lib/auto-lvm.sh
index 80856ba..7e357df 100644
--- a/lib/auto-lvm.sh
+++ b/lib/auto-lvm.sh
@@ -166,9 +166,13 @@ auto_lvm_prepare() {
 		bail_out unusable_recipe
 	fi
 
-	# Make sure a boot partition isn't marked as lvmok
+	# Make sure a boot partition isn't marked as lvmok, unless the user
+	# has told us it is ok for /boot to reside on a logical volume
 	if echo "$scheme" | grep lvmok | grep -q "[[:space:]]/boot[[:space:]]"; then
-		bail_out unusable_recipe
+		db_input critical partman-auto-lvm/no_boot || true
+		db_go || return 255
+		db_get partman-auto-lvm/no_boot || true
+		[ "$RET" = true ] || bail_out unusable_recipe
 	fi
 
 	# This variable will be used to store the partitions that will be LVM
-- 
1.7.9.1




Reply to: