f2e7477d21
because another command (echo) is executed between the mount command and the check. Reported by: Sergey Baturov <sergey@toor.org.ru> MFC after: 2 weeks
40 lines
485 B
Bash
40 lines
485 B
Bash
#!/bin/sh
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
# PROVIDE: mountlate
|
|
# REQUIRE: DAEMON
|
|
# BEFORE: LOGIN
|
|
# KEYWORD: nojail
|
|
|
|
. /etc/rc.subr
|
|
|
|
name="mountlate"
|
|
start_cmd="mountlate_start"
|
|
stop_cmd=":"
|
|
|
|
mountlate_start()
|
|
{
|
|
local err
|
|
|
|
# Mount "late" filesystems.
|
|
echo -n 'Mounting late file systems:'
|
|
mount -a -l
|
|
err=$?
|
|
echo '.'
|
|
|
|
case ${err} in
|
|
0)
|
|
;;
|
|
*)
|
|
echo 'Mounting /etc/fstab filesystems failed,' \
|
|
' startup aborted'
|
|
stop_boot true
|
|
;;
|
|
esac
|
|
}
|
|
|
|
load_rc_config $name
|
|
run_rc_command "$1"
|