xref: /freebsd/usr.bin/quota/quota.1 (revision 1e413cf93298b5b97441a21d9a50fdcd0ee9945e)
1.\" Copyright (c) 1983, 1990, 1993
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.\"	from: @(#)quota.1	8.1 (Berkeley) 6/6/93
36.\" $FreeBSD$
37.\"
38.Dd February 3, 2007
39.Dt QUOTA 1
40.Os
41.Sh NAME
42.Nm quota
43.Nd display disk usage and limits
44.Sh SYNOPSIS
45.Nm
46.Op Fl ghlu
47.Op Fl f Ar path
48.Op Fl v | q | r
49.Nm
50.Op Fl hlu
51.Op Fl f Ar path
52.Op Fl v | q | r
53.Ar user ...
54.Nm
55.Fl g
56.Op Fl hl
57.Op Fl f Ar path
58.Op Fl v | q | r
59.Ar group ...
60.Sh DESCRIPTION
61The
62.Nm
63utility displays users' disk usage and limits.
64By default only the user quotas are printed.
65Disk block usage and limits are shown in 1024-byte blocks.
66.Pp
67The following options are available:
68.Bl -tag -width indent
69.It Fl f Ar path
70Only display quota information for the file system
71that contains the specified path.
72This can be any file within a mounted file system.
73.It Fl g
74Print group quotas for the group
75of which the user is a member.
76.It Fl h
77"Human-readable" output.
78Use unit suffixes: Byte, Kilobyte, Megabyte, Gigabyte, Terabyte and Petabyte.
79.It Fl l
80Do not report quotas on
81.Tn NFS
82file systems.
83.It Fl q
84Print a more terse message,
85containing only information
86on file systems where usage is over quota.
87The
88.Fl q
89flag takes precedence over the
90.Fl v
91flag.
92.It Fl r
93Display the raw quota information as it appears in the quota structure.
94Non-zero time values will also be displayed in
95.Xr ctime 3
96format.
97This option implies
98.Fl v
99and will override the
100.Fl q
101flag.
102.It Fl u
103Print the user quotas.
104This is the default unless
105.Fl g
106is specified.
107.It Fl v
108Display quotas on file systems
109where no storage is allocated.
110.El
111.Pp
112Specifying both
113.Fl g
114and
115.Fl u
116displays both the user quotas and the group quotas (for
117the user).
118.Pp
119Only the super-user may use the
120.Fl u
121flag and the optional
122.Ar user
123argument to view the limits of other users.
124Non-super-users can use the
125.Fl g
126flag and optional
127.Ar group
128argument to view only the limits of groups of which they are members.
129.Pp
130The
131.Nm
132utility tries to report the quotas of all mounted file systems.
133If the file system is mounted via
134.Tn NFS ,
135it will attempt to contact the
136.Xr rpc.rquotad 8
137daemon on the
138.Tn NFS
139server.
140For
141.Tn UFS
142file systems, quotas must be turned on in
143.Pa /etc/fstab .
144If
145.Nm
146exits with a non-zero status, one or more file systems
147are over quota or the path specified with the
148.Fl f
149option does not exist.
150.Pp
151If the
152.Fl l
153flag is specified,
154.Nm
155will not check
156.Tn NFS
157file systems.
158.Sh FILES
159.Bl -tag -width quota.group -compact
160.It Pa quota.user
161located at the file system root with user quotas
162.It Pa quota.group
163located at the file system root with group quotas
164.It Pa /etc/fstab
165to find file system names and locations
166.El
167.Sh SEE ALSO
168.Xr quotactl 2 ,
169.Xr ctime 3 ,
170.Xr fstab 5 ,
171.Xr edquota 8 ,
172.Xr quotacheck 8 ,
173.Xr quotaon 8 ,
174.Xr repquota 8 ,
175.Xr rpc.rquotad 8
176.Sh HISTORY
177The
178.Nm
179command appeared in
180.Bx 4.2 .
181