6 # PROVIDE: mountcritremote
7 # REQUIRE: NETWORKING FILESYSTEMS cleanvar ipsec
12 name="mountcritremote"
14 start_cmd="mountcritremote_start"
15 start_precmd="mountcritremote_precmd"
17 # Mount NFS filesystems if present in /etc/fstab
19 # XXX When the vfsload() issues with nfsclient support and related sysctls
20 # have been resolved, this block can be removed, and the condition that
21 # skips nfs in the following block (for "other network filesystems") can
24 mountcritremote_precmd()
26 case "`mount -d -a -t nfs 2> /dev/null`" in
28 # Handle absent nfs client support
29 load_kld -m nfs nfsclient || return 1
35 mountcritremote_start()
37 # Mount nfs filesystems.
39 echo -n 'Mounting NFS file systems:'
43 # Mount other network filesystems if present in /etc/fstab.
44 case ${extra_netfs_types} in
48 netfs_types="${netfs_types} ${extra_netfs_types}"
52 for i in ${netfs_types}; do
56 [ "${fstype}" = "nfs" ] && continue
58 case "`mount -d -a -t ${fstype}`" in
60 echo -n "Mounting ${fsdecr} file systems:"
67 # Cleanup /var again just in case it's a network mount.
68 /etc/rc.d/cleanvar reload
69 rm -f /var/run/clean_var /var/spool/lock/clean_var