#!/bin/sh # # $FreeBSD: head/etc/rc.d/zfs 168695 2007-04-13 18:46:35Z des $ # # PROVIDE: zfs # REQUIRE: mountcritlocal # KEYWORD: nojail . /etc/rc.subr name="zfs" rcvar="zfs_enable" start_cmd="zfs_start" stop_cmd="zfs_stop" required_modules="zfs" zfs_start() { zfs volinit zfs mount -a zfs share -a if [ ! -r /etc/zfs/exports ]; then touch /etc/zfs/exports fi } zfs_stop() { zfs unshare -a zfs unmount -a zfs volfini } load_rc_config $name run_rc_command "$1"