mountall revision 1.12
11.1Slukem#!/bin/sh
21.1Slukem#
31.12Sriastrad# $NetBSD: mountall,v 1.12 2020/02/23 08:53:25 riastradh Exp $
41.1Slukem#
51.1Slukem
61.6Stsutsui# REQUIRE: mountcritremote named ypbind
71.1Slukem# PROVIDE: mountall
81.1Slukem
91.4Smycroft$_rc_subr_loaded . /etc/rc.subr
101.1Slukem
111.1Slukemname="mountall"
121.7Shaadstart_cmd="mountall_start"
131.7Shaadstop_cmd="mountall_stop"
141.7Shaad
151.7Shaadmountall_start()
161.7Shaad{
171.9Swiz	echo 'Mounting all file systems...'
181.11Sbrad	# Mount file systems noted in fstab.
191.11Sbrad	mount -a
201.12Sriastrad	if checkyesno zfs; then
211.7Shaad		# Mount ZFS file systems.
221.7Shaad		zfs mount -a
231.7Shaad	fi
241.7Shaad}
251.7Shaad
261.7Shaadmountall_stop()
271.7Shaad{
281.9Swiz	echo 'Unmounting all file systems...'
291.12Sriastrad	if checkyesno zfs; then
301.7Shaad		# Unmount ZFS file systems.
311.7Shaad		zfs unmount -a
321.7Shaad	fi
331.11Sbrad	# Unmount file systems noted in fstab.
341.11Sbrad	umount -a
351.7Shaad}
361.1Slukem
371.3Slukemload_rc_config $name
381.1Slukemrun_rc_command "$1"
39