mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
PR#254282 reports a problem where nullfs mounts cannot be
exported via mountd for FreeBSD 13.0.
The problem seems to be that, to do the nullfs mounts in
/etc/fstab, they require the "late" mount option, so that the
underlying filesystem is mounted (ZFS for the PR).
Adding "mountlate" to the REQUIRE list in /etc/rc.d/mountd
fixes the problem, but that results in a dependency cycle
because /etc/rc.d/lockd specifies:
REQUIRE: nfsd
BEFORE: DAEMON
--> which forces mountd to preceed DAEMON.
This patch removes "nfsd" from REQUIRE for lockd and statd,
then adds mountlate to REQUIRE for mountd, to fix this
problem. Having lockd REQUIRE nfsd was done in the NetBSD
code when it was pulled into FreeBSD and there does not
seem to be a need for this.
In case this causes problems, a long MFC has been specified.
PR: 254282
(cherry picked from commit f72926eab0)
31 lines
582 B
Bash
Executable file
31 lines
582 B
Bash
Executable file
#!/bin/sh
|
|
#
|
|
# FreeBSD History: src/etc/rc.d/nfslocking,v 1.11 2004/10/07 13:55:26 mtm Exp
|
|
# $FreeBSD$
|
|
#
|
|
|
|
# PROVIDE: statd
|
|
# REQUIRE: nfsclient rpcbind
|
|
# BEFORE: DAEMON
|
|
# KEYWORD: nojail shutdown
|
|
|
|
. /etc/rc.subr
|
|
|
|
name="statd"
|
|
desc="host status monitoring daemon"
|
|
rcvar=rpc_statd_enable
|
|
command="/usr/sbin/rpc.${name}"
|
|
start_precmd='statd_precmd'
|
|
|
|
# Make sure that we are either an NFS client or server, and that we get
|
|
# the correct flags from rc.conf(5).
|
|
#
|
|
statd_precmd()
|
|
{
|
|
force_depend rpcbind || return 1
|
|
|
|
rc_flags=${rpc_statd_flags}
|
|
}
|
|
|
|
load_rc_config $name
|
|
run_rc_command $1
|