summaryrefslogtreecommitdiffstats
path: root/etc/rc.d/quota
blob: d2598822c1c570aa5a36423b3a8f20da5a61c2c4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/sh
#
# $FreeBSD$
#

# Enable/Check the quotas (must be after ypbind if using NIS)
#

# PROVIDE: quota
# REQUIRE: mountcritremote
# BEFORE: DAEMON
# KEYWORD: FreeBSD

. /etc/rc.subr

name="quota"
rcvar="enable_quotas"
start_cmd="quota_start"
stop_cmd="/usr/sbin/quotaoff -a"

quota_start()
{
	if checkyesno check_quotas; then
		echo -n 'Checking quotas:'
		quotacheck -a
		echo ' done.'
	fi

	echo -n 'Enabling quotas:'
	quotaon -a
	echo ' done.'
}

load_rc_config $name
run_rc_command "$1"
OpenPOWER on IntegriCloud