summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Thursfield <sam.thursfield@codethink.co.uk>2014-06-11 17:33:53 +0100
committerSam Thursfield <sam.thursfield@codethink.co.uk>2014-06-11 17:33:53 +0100
commite83ee0e46b11ac08706044388c6990fa048cfdc2 (patch)
tree8dce61de615479d0c6bc693a339cab38370bf7a3
parent0fbcc80442b42b7a785e4cbb1fabea044094441f (diff)
parent525ba822dcbaf125e30a58cd0af5747d660ff3fa (diff)
downloadbaserock-chroot-e83ee0e46b11ac08706044388c6990fa048cfdc2.tar.gz
Merge branch 'sam/btrfs-on-load'
Reviewed-By: Lars Wirzenius <lars.wirzenius@codethink.co.uk>
-rwxr-xr-xenter-baserock8
1 files changed, 8 insertions, 0 deletions
diff --git a/enter-baserock b/enter-baserock
index 4ce2b52..b4b73ff 100755
--- a/enter-baserock
+++ b/enter-baserock
@@ -39,6 +39,14 @@ fi
cd /
+if ! grep -q btrfs /proc/filesystems; then
+ echo "No btrfs support detected in kernel, attempting to load btrfs module"
+ if ! sudo -p "Password (to run 'modprobe -v btrfs'): " modprobe -v btrfs; then
+ echo "Loading module failed, looks like your kernel doesn't support Btrfs."
+ echo "Deploying systems to Btrfs disk images will not work correctly."
+ fi
+fi
+
if test "x$SSH_AUTH_SOCK" != "x"; then
echo "Forwarding SSH agent into chroot"
TDIR=$(mktemp --tmpdir=/tmp -d)