mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-13 16:14:40 +00:00
rc: prevent /var MFS transition on install media after import
This commit is contained in:
parent
56517b529a
commit
eaffc0edc4
@ -135,7 +135,7 @@ fi
|
||||
/etc/rc.d/dmesg onestart
|
||||
|
||||
# XXX pre-17.1 compat: avoid matching use_mfs_tmpvar
|
||||
USE_MFS_TMP=`/usr/bin/grep -c 'use_mfs_tmp[^_]' /conf/config.xml`
|
||||
USE_MFS_TMP=$(/usr/bin/grep -c 'use_mfs_tmp[^_]' /conf/config.xml)
|
||||
|
||||
if [ ${USE_MFS_TMP} -ne 0 ]; then
|
||||
mount -t tmpfs -o mode=01777 tmpfs /tmp
|
||||
|
||||
@ -111,7 +111,17 @@ for RC_FILE in ${RC_FILES}; do
|
||||
done
|
||||
|
||||
# XXX pre-17.1 compat: use_mfs_tmpvar matches both patterns
|
||||
USE_MFS_VAR=`/usr/bin/grep -c 'use_mfs_.*var[^_]' /conf/config.xml`
|
||||
USE_MFS_VAR=$(/usr/bin/grep -c 'use_mfs_.*var[^_]' /conf/config.xml)
|
||||
|
||||
# see if / is writable (aka. non-LiveCD boot)
|
||||
if _tmpdir=$(mktemp -d -q /.diskless.XXXXXX); then
|
||||
# only remove the directory
|
||||
rmdir ${_tmpdir}
|
||||
else
|
||||
# config restore for install media does not support
|
||||
# this as neither /var nor /root are persistent
|
||||
USE_MFS_VAR=0
|
||||
fi
|
||||
|
||||
if [ ${USE_MFS_VAR} -ne 0 ]; then
|
||||
echo -n "Setting up memory disks..."
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user