xref: /freebsd/libexec/rc/rc.d/quota (revision 61e21613)
1#!/bin/sh
2#
3#
4
5# Enable/Check the quotas (must be after ypbind if using NIS)
6
7# PROVIDE: quota
8# REQUIRE: mountcritremote ypset
9# BEFORE: DAEMON
10# KEYWORD: nojail
11
12. /etc/rc.subr
13
14name="quota"
15desc="Enable/check the quotas"
16rcvar="quota_enable"
17load_rc_config $name
18start_cmd="quota_start"
19stop_cmd="/usr/sbin/quotaoff ${quotaoff_flags}"
20
21quota_start()
22{
23	if checkyesno check_quotas; then
24		echo -n 'Checking quotas:'
25		quotacheck ${quotacheck_flags}
26		echo ' done.'
27	fi
28
29	echo -n 'Enabling quotas:'
30	quotaon ${quotaon_flags}
31	echo ' done.'
32}
33
34run_rc_command "$1"
35