summaryrefslogtreecommitdiff
path: root/setup-bootable.in
diff options
context:
space:
mode:
authorJeff Bilyk <jbilyk@gmail.com>2011-07-16 22:01:44 -0400
committerJeff Bilyk <jbilyk@gmail.com>2011-07-16 22:01:44 -0400
commita234ec98b8a4be9fa7ebd8e37cce4d58ec1c5473 (patch)
treebe2222efe2e02c32b74da365e525bd57d0d4ca68 /setup-bootable.in
parentc67ff2550962e8857d9a7c3859fc5003324e418a (diff)
downloadalpine-conf-a234ec98b8a4be9fa7ebd8e37cce4d58ec1c5473.zip
setup-bootable: somehow a couple lines for remounting RO/RW got missed
Diffstat (limited to 'setup-bootable.in')
-rw-r--r--setup-bootable.in9
1 files changed, 8 insertions, 1 deletions
diff --git a/setup-bootable.in b/setup-bootable.in
index 8026226..db388a6 100644
--- a/setup-bootable.in
+++ b/setup-bootable.in
@@ -117,7 +117,10 @@ elif [ -b "$dest" ]; then
fi
# Check for RO mounting
-if [ "`grep \"$destdir\" /proc/mount | grep '(ro,'`"
+if [ "`grep \"$destdir\" /proc/mount | grep '(ro,'`" == "ro" ]; then
+ remountneeded="Y"
+ mount -o remount,rw "$destdir"
+fi
[ -n "$verbose" ] && echo "Using $dest as target (mounted on $destdir)"
@@ -258,5 +261,9 @@ else
echo "Warning: Could not find the parent device for $dest"
fi
+if [ "$remountneeded" == "Y" ]; then
+ mount -o remount,ro "$destdir"
+fi
+
cleanup
sync