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.\" @(#)edquota.8 8.1 (Berkeley) 6/6/93 36.\" 37.Dd "June 6, 1993" 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.br 59.Sh DESCRIPTION 60.Nm Edquota 61is a quota editor. 62By default, or if the 63.Fl u 64flag is specified, 65one or more users may be specified on the command line. 66For each user a temporary file is created 67with an ASCII representation of the current 68disk quotas for that user. 69The list of filesystems with user quotas is determined from 70.Pa /etc/fstab . 71An editor is invoked on the ASCII file. 72The editor invoked is 73.Xr vi 1 74unless the environment variable 75.Ev EDITOR 76specifies otherwise. 77.Pp 78The quotas may then be modified, new quotas added, etc. 79Setting a quota to zero indicates that no quota should be imposed. 80Setting a hard limit to one indicates that no allocations should 81be permitted. 82Setting a soft limit to one with a hard limit of zero 83indicates that allocations should be permitted only on 84a temporary basis (see 85.Fl t 86below). 87The current usage information in the file is for informational purposes; 88only the hard and soft limits can be changed. 89.Pp 90On leaving the editor, 91.Nm 92reads the temporary file and modifies the binary 93quota files to reflect the changes made. 94.Pp 95If the 96.Fl p 97option is specified, 98.Nm 99will duplicate the quotas of the prototypical user 100specified for each user specified. 101This is the normal mechanism used to 102initialize quotas for groups of users. 103If the user given to assign quotas to is a numerical uid 104range (e.g. 1000-2000), then 105.Nm 106will duplicate the quotas of the prototypical user 107for each uid in the range specified. This allows 108for easy setup of default quotas for a group of users. 109The uids in question do not have to be currently assigned in 110.Pa /etc/passwd 111.Pp 112If the 113.Fl g 114flag is specified, 115.Nm 116is invoked to edit the quotas of 117one or more groups specified on the command line. 118The 119.Fl p 120flag can be specified in conjunction with 121the 122.Fl g 123flag to specify a prototypical group 124to be duplicated among the listed set of groups. 125.Pp 126Users are permitted to exceed their soft limits 127for a grace period that may be specified per filesystem. 128Once the grace period has expired, 129the soft limit is enforced as a hard limit. 130The default grace period for a filesystem is specified in 131.Pa /usr/include/ufs/ufs/quota.h . 132The 133.Fl t 134flag can be used to change the grace period. 135By default, or when invoked with the 136.Fl u 137flag, 138the grace period is set for all the filesystems with user 139quotas specified in 140.Pa /etc/fstab . 141When invoked with the 142.Fl g 143flag the grace period is 144set for all the filesystems with group quotas specified in 145.Pa /etc/fstab . 146The grace period may be specified in days, hours, minutes, or seconds. 147Setting a grace period to zero indicates that the default 148grace period should be imposed. 149Setting a grace period to one second indicates that no 150grace period should be granted. 151.Pp 152Only the super-user may edit quotas. 153.Sh FILES 154.Bl -tag -width quota.group -compact 155.It Pa quota.user 156at the filesystem root with user quotas 157.It Pa quota.group 158at the filesystem root with group quotas 159.It Pa /etc/fstab 160to find filesystem names and locations 161.El 162.Sh SEE ALSO 163.Xr quota 1 , 164.Xr fstab 2 , 165.Xr quotactl 2 , 166.Xr quotacheck 8 , 167.Xr quotaon 8 , 168.Xr repquota 8 169.Sh DIAGNOSTICS 170Various messages about inaccessible files; self-explanatory. 171