Gentoo Archives: gentoo-dev

From: Gregg <gregg@××.am>
To: gentoo-dev@g.o
Subject: [gentoo-dev] my quota startup script
Date: Thu, 25 Jul 2002 10:16:01
Message-Id: 1025.12.247.253.40.1027610250.squirrel@sc.am
1 This is my startup script for quota. It runs from the "boot" runlevel.
2 This turns quotas on and does the initial check at boot. Then on
3 shutdown/reboot turns it off. I think maybe it could go in the package
4 for quota?
5
6 #!/sbin/runscript
7
8 depend() {
9 need net
10 }
11
12 start() {
13 ebegin "Starting Quota"
14 if [ -x /sbin/quotacheck ]
15 then
16 echo "Checking quotas. This make take some time."
17 /sbin/quotacheck -avug
18 echo "Done."
19 fi
20 if [ -x /sbin/quotaon ]
21 then
22 echo "Turning on quota"
23 /sbin/quotaon -avug
24 fi
25 eend $?
26 }
27
28 stop() {
29 ebegin "Stopping quota"
30 if [ -x /sbin/quotaoff ]
31 then
32 echo "Turning quota off"
33 /sbin/quotaoff -avug
34 fi
35 eend $?
36 }

Replies

Subject Author
Re: [gentoo-dev] my quota startup script Christian Axelsson <smiler@××××××××××.nu>