summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2013-03-12 13:59:40 -0400
committerjim-p <jimp@pfsense.org>2013-03-12 13:59:40 -0400
commitefc0e29abc068b41f52a2d5d6ac89cb6c4791662 (patch)
tree150b6929573c9863190dcfb3127a3f99afe70106 /etc
parenta1f735b31c8f7f0cca0ebc5a7153cd06cdf4482e (diff)
downloadpfsense-efc0e29abc068b41f52a2d5d6ac89cb6c4791662.zip
pfsense-efc0e29abc068b41f52a2d5d6ac89cb6c4791662.tar.gz
Move tmp/var init to just after mount of /cf so that the sizing works properly on NanoBSD. Fix input validation for sizes. Add note about needing a reboot to apply the settings.
Diffstat (limited to 'etc')
-rwxr-xr-xetc/rc30
1 files changed, 15 insertions, 15 deletions
diff --git a/etc/rc b/etc/rc
index 9b049f1..a2f8cf3 100755
--- a/etc/rc
+++ b/etc/rc
@@ -84,11 +84,6 @@ else
/sbin/mount -a || (/sbin/fsck -fy; /sbin/mount -a)
fi
- USE_MFS_TMPVAR=`/usr/bin/grep -c use_mfs_tmpvar /cf/conf/config.xml`
- if [ "${PLATFORM}" = "nanobsd" ] || [ "${PLATFORM}" = "embedded" ] || [ ${USE_MFS_TMPVAR} -gt 0 ]; then
- /etc/rc.embedded
- fi
-
# If /conf is a directory, convert it to a symlink to /cf/conf
if [ -d "/conf" ]; then
# If item is not a symlink then rm and recreate
@@ -98,6 +93,21 @@ else
/bin/ln -s /cf/conf /conf
fi
fi
+
+ if [ ! "$PLATFORM" = "jail" ]; then
+ # Check to see if a compact flash mountpoint exists
+ # If it fails to mount then run a fsck -fy
+ if grep -q cf /etc/fstab; then
+ /sbin/mount -w /cf 2>/dev/null
+ /sbin/mount -uw /cf || \
+ (/sbin/umount /cf; /sbin/fsck -fy /cf; /sbin/mount -w /cf)
+ fi
+ fi
+
+ USE_MFS_TMPVAR=`/usr/bin/grep -c use_mfs_tmpvar /cf/conf/config.xml`
+ if [ "${PLATFORM}" = "nanobsd" ] || [ "${PLATFORM}" = "embedded" ] || [ ${USE_MFS_TMPVAR} -gt 0 ]; then
+ /etc/rc.embedded
+ fi
fi
/bin/rm -f /root/force_fsck
@@ -116,16 +126,6 @@ if [ "$CDDEVICE" != "" ]; then
cdcontrol -f /dev/"$CDDEVICE" eject
fi
-if [ ! "$PLATFORM" = "jail" ]; then
- # Check to see if a compact flash mountpoint exists
- # If it fails to mount then run a fsck -fy
- if grep -q cf /etc/fstab; then
- /sbin/mount -w /cf 2>/dev/null
- /sbin/mount -uw /cf || \
- (/sbin/umount /cf; /sbin/fsck -fy /cf; /sbin/mount -w /cf)
- fi
-fi
-
# sync pw database after mount.
rm -f /etc/spwd.db.tmp
/usr/sbin/pwd_mkdb -d /etc/ /etc/master.passwd
OpenPOWER on IntegriCloud