LIMITS(5) LIMITS(5)
NAME
limits - Resource limits definition
DESCRIPTION
The limits file(1,n) (/etc/limits by default or LIMITS_FILE defined con-
fig.h) describes the resource limits you wish to impose. It should be
owned by root and readable by root account only.
By default no quotas are imposed on 'root'. In fact, there is no way to
impose limits via this procedure to root-equiv accounts (accounts with
UID 0).
Each line describes a limit for a user in(1,8) the form:
user LIMITS_STRING
The LIMITS_STRING is a string(3,n) of a concatenated list of resource lim-
its. Each limit consists of a letter identifier followed by a numeri-
cal limit.
The valid identifiers are:
A: max address space (KB)
C: max core file(1,n) size (KB)
D: max data size (KB)
F: maximum filesize (KB)
M: max locked-in-memory address space (KB)
N: max number of open(2,3,n) files
R: max resident set(7,n,1 builtins) size (KB)
S: max stack size (KB)
T: max CPU time(1,2,n) (MIN)
U: max number of processes
K: file(1,n) creation mask, set(7,n,1 builtins) by umask(2).
L: max number of logins for this user
P: process priority, set(7,n,1 builtins) by setpriority(2).
For example, L2D2048N5 is a valid LIMITS_STRING. For reading conve-
nience, the following entries are equivalent:
username L2D2048N5
username L2 D2048 N5
Be aware that after username the rest of the line is considered a limit
string(3,n), thus comments are not allowed. A invalid limits string(3,n) will be
rejected (not considered) by the login(1,3,5) program.
The default entry is denoted by username "*". If you have multiple
default entries in(1,8) your LIMITS_FILE, then the last one will be used as
the default entry.
To completely disable limits for a user, a single dash "-" will do.
Also, please note that all limit settings are set(7,n,1 builtins) PER LOGIN. They are
not global, nor are they permanent. Perhaps global limits will come,
but for now this will have to do ;)
FILES
/etc/limits
SEE ALSO
login(1,3,5)(1), setpriority(2), setrlimit(2)
AUTHOR
Cristian Gafton (gafton@sorosis.ro)
LIMITS(5)