]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - etc/rc.d/mountcritlocal
Remove $NetBSD$ CVS tags. We no longer attempt to synch our rc.d files
[FreeBSD/FreeBSD.git] / etc / rc.d / mountcritlocal
1 #!/bin/sh
2 #
3 # $FreeBSD$
4 #
5
6 # PROVIDE: mountcritlocal
7 # REQUIRE: root
8 # KEYWORD: nojail
9
10 . /etc/rc.subr
11
12 name="mountcritlocal"
13 start_cmd="mountcritlocal_start"
14 stop_cmd=":"
15
16 mountcritlocal_start()
17 {
18         # Set up the list of network filesystem types for which mounting
19         # should be delayed until after network initialization.
20         case ${extra_netfs_types} in
21         [Nn][Oo])
22                 ;;
23         *)
24                 netfs_types="${netfs_types} ${extra_netfs_types}"
25                 ;;
26         esac
27
28         # Mount everything except nfs filesystems.
29         echo -n 'Mounting local file systems:'
30         mount_excludes='no'
31         for i in ${netfs_types}; do
32                 fstype=${i%:*}
33                 mount_excludes="${mount_excludes}${fstype},"
34         done
35         mount_excludes=${mount_excludes%,}
36         mount -a -t ${mount_excludes}
37         echo '.'
38
39         case $? in
40         0)
41                 ;;
42         *)
43                 echo 'Mounting /etc/fstab filesystems failed,' \
44                     ' startup aborted'
45                 stop_boot true
46                 ;;
47         esac
48 }
49
50 load_rc_config $name
51 run_rc_command "$1"