]> git.cameronkatri.com Git - apple_cmds.git/blob - diskdev_cmds/edquota.tproj/edquota.8
diskdev_cmds: Fix BINDIRs
[apple_cmds.git] / diskdev_cmds / edquota.tproj / edquota.8
1 .\" Copyright (c) 1983, 1990, 1993, 2002
2 .\" The Regents of the University of California. All rights reserved.
3 .\"
4 .\" This code is derived from software contributed to Berkeley by
5 .\" Robert Elz at The University of Melbourne.
6 .\"
7 .\" Redistribution and use in source and binary forms, with or without
8 .\" modification, are permitted provided that the following conditions
9 .\" are met:
10 .\" 1. Redistributions of source code must retain the above copyright
11 .\" notice, this list of conditions and the following disclaimer.
12 .\" 2. Redistributions in binary form must reproduce the above copyright
13 .\" notice, this list of conditions and the following disclaimer in the
14 .\" documentation and/or other materials provided with the distribution.
15 .\" 3. All advertising materials mentioning features or use of this software
16 .\" must display the following acknowledgement:
17 .\" This product includes software developed by the University of
18 .\" California, Berkeley and its contributors.
19 .\" 4. Neither the name of the University nor the names of its contributors
20 .\" may be used to endorse or promote products derived from this software
21 .\" without specific prior written permission.
22 .\"
23 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
24 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
25 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
26 .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
27 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
28 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
29 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
30 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
31 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
32 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
33 .\" SUCH DAMAGE.
34 .\"
35 .\" @(#)edquota.8 8.2 (Berkeley) 4/27/95
36 .\"
37 .Dd "March 28, 2002"
38 .Dt EDQUOTA 8
39 .Os
40 .Sh NAME
41 .Nm edquota
42 .Nd edit user quotas
43 .Sh SYNOPSIS
44 .Nm edquota
45 .Op Fl u
46 .Op Fl p Ar proto-username
47 .Ar username ...
48 .Nm edquota
49 .Fl g
50 .Op Fl p Ar proto-groupname
51 .Ar groupname ...
52 .Nm edquota
53 .Fl t
54 .Op Fl u
55 .Nm edquota
56 .Fl t
57 .Fl g
58 .Sh DESCRIPTION
59 .Nm Edquota
60 is a quota editor.
61 By default, or if the
62 .Fl u
63 flag is specified,
64 one or more users may be specified on the command line.
65 For each user a temporary file is created
66 with an ASCII representation of the current
67 disk quotas for that user.
68 The list of filesystems with user quotas is determined by
69 scanning the mounted filesystems for a
70 .Pa .quota.ops.user
71 file located at its root.
72 An editor is invoked on the ASCII file.
73 The editor invoked is
74 .Xr vi 1
75 unless the environment variable
76 .Ev EDITOR
77 specifies otherwise.
78 .Pp
79 The quotas may then be modified, new quotas added, etc.
80 Setting a quota to zero indicates that no quota should be imposed.
81 Setting a hard limit to one indicates that no allocations should
82 be permitted.
83 Setting a soft limit to one with a hard limit of zero
84 indicates that allocations should be permitted on
85 only a temporary basis (see
86 .Fl t
87 below).
88 The current usage information in the file is for informational purposes;
89 only the hard and soft limits can be changed.
90 .Pp
91 On leaving the editor,
92 .Nm edquota
93 reads the temporary file and modifies the binary
94 quota files to reflect the changes made.
95 The binary quota file,
96 .Pa .quota.user
97 is stored at the root of the filesystem.
98 The default filename and root location for the user
99 quotas cannot be overridden.
100 .Pp
101 If the
102 .Fl p
103 flag is specified,
104 .Nm edquota
105 will duplicate the quotas of the prototypical user
106 specified for each user specified.
107 This is the normal mechanism used to
108 initialize quotas for groups of users.
109 .Pp
110 If the
111 .Fl g
112 flag is specified,
113 .Nm edquota
114 is invoked to edit the quotas of
115 one or more groups specified on the command line.
116 The list of filesystems with group quotas is determined by
117 scanning the mounted filesystems for a
118 .Pa .quota.ops.group
119 file located at its root.
120 Similarly, the binary quota file,
121 .Pa .quota.group
122 is stored at the root of the filesystem.
123 The default filename and root location for group
124 quotas cannot be overridden.
125 The
126 .Fl p
127 flag can be specified in conjunction with
128 the
129 .Fl g
130 flag to specify a prototypical group
131 to be duplicated among the listed set of groups.
132 .Pp
133 Users are permitted to exceed their soft limits
134 for a grace period that may be specified per filesystem.
135 Once the grace period has expired,
136 the soft limit is enforced as a hard limit.
137 The default grace period for a filesystem is specified in
138 .Pa /usr/include/sys/quota.h .
139 The
140 .Fl t
141 flag can be used to change the grace period.
142 By default, or when invoked with the
143 .Fl u
144 flag, the grace period is set for each filesystem with a
145 .Pa .quota.ops.user
146 file located at its root.
147 When invoked with the
148 .Fl g
149 flag, the grace period is
150 set for each filesystem with a
151 .Pa .quota.ops.group
152 file located at its root.
153 The grace period may be specified in days, hours, minutes, or seconds.
154 Setting a grace period to zero indicates that the default
155 grace period should be imposed.
156 Setting a grace period to one second indicates that no
157 grace period should be granted.
158 .Pp
159 Only the super-user may edit quotas.
160 .Sh FILES
161 Each of the following quota files is located at the root of the
162 mounted filesystem. The mount option files are empty files
163 whose existence indicates that quotas are to be enabled
164 for that filesystem. The binary data files will be
165 created by edquota, if they don't already exist.
166 .Pp
167 .Bl -tag -width .quota.ops.group -compact
168 .It Pa .quota.user
169 data file containing user quotas
170 .It Pa .quota.group
171 data file containing group quotas
172 .It Pa .quota.ops.user
173 mount option file used to enable user quotas
174 .It Pa .quota.ops.group
175 mount option file used to enable group quotas
176 .El
177 .Sh SEE ALSO
178 .Xr quota 1 ,
179 .Xr quotactl 2 ,
180 .Xr quotacheck 8 ,
181 .Xr quotaon 8 ,
182 .Xr repquota 8
183 .Sh DIAGNOSTICS
184 Various messages about inaccessible files; self-explanatory.