summaryrefslogtreecommitdiffstats
path: root/etc/rc
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2010-08-15 14:02:29 -0400
committerScott Ullrich <sullrich@pfsense.org>2010-08-15 14:02:29 -0400
commit87db1017ee146c86d50177fd0a67c0ddf7d68cd6 (patch)
tree0f893ee2516f9d9442949e17c2fcbe46a98d54ad /etc/rc
parent9d869ea397ffc0dd44cfdfe17ebaf7b1dba6cd14 (diff)
downloadpfsense-87db1017ee146c86d50177fd0a67c0ddf7d68cd6.zip
pfsense-87db1017ee146c86d50177fd0a67c0ddf7d68cd6.tar.gz
Handle ZFS root partition read-only cases
Diffstat (limited to 'etc/rc')
-rwxr-xr-xetc/rc6
1 files changed, 6 insertions, 0 deletions
diff --git a/etc/rc b/etc/rc
index 67bd1e3..6e894db 100755
--- a/etc/rc
+++ b/etc/rc
@@ -28,6 +28,12 @@ version=`cat /etc/version`
# Mount memory file system if it exists
echo "Mounting filesystems..."
+# Handle ZFS read-only case
+WHEREISROOT=`/sbin/mount | /usr/bin/grep " / " | /usr/bin/grep "tank" | /usr/bin/cut -d' ' -f1`
+if [ "$WHEREISROOT" != "" ]; then
+ /sbin/zfs set readonly=off $WHEREISROOT
+fi
+
if [ "$PLATFORM" = "cdrom" ]; then
/etc/rc.cdrom
fi
OpenPOWER on IntegriCloud