Fix firstboot fs mount logic

The firstboot logic has an error which causes the filesystem to be
mounted readonly even though root_rw_mount=YES. This fixes the error to
ensure that the root filesystem is mounted rw as expected after the run
of the firstboot scripts.

Reviewed by:	imp
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D14226
This commit is contained in:
Mark Felder 2018-02-06 20:12:05 +00:00
parent 6b9159b96b
commit 1ce07411fa
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=328949

4
etc/rc
View File

@ -141,10 +141,10 @@ if [ -e ${firstboot_sentinel} ]; then
if [ -e ${firstboot_sentinel}-reboot ]; then
chflags -R 0 ${firstboot_sentinel}-reboot
rm -rf ${firstboot_sentinel}-reboot
checkyesno root_rw_mount && mount -ur /
checkyesno root_rw_mount || mount -ur /
kill -INT 1
fi
checkyesno root_rw_mount && mount -ur /
checkyesno root_rw_mount || mount -ur /
fi
echo ''