1ulimit [ [ -SHacdfiklmnpqsTtvwx | -N resource [ limit ] ... ]
2       Set  or  display  resource limits of the shell and the processes
3       started by the shell.  The value of limit can be a number in the
4       unit  specified  below  or  one of the values `unlimited', which
5       removes the limit on the resource, or  `hard',  which  uses  the
6       current value of the hard limit on the resource.
7
8       By  default, only soft limits are manipulated. If the -H flag is
9       given use hard limits instead of soft limits.  If the -S flag is
10       given together with the -H flag set both hard and soft limits.
11
12       If no options are used, the file size limit (-f) is assumed.
13
14       If limit is omitted the current value of the specified resources
15       are printed.  When more than one resource value is printed,  the
16       limit name and unit is printed before each value.
17
18       When looping over multiple resources, the shell will abort imme-
19       diately if it detects a badly formed argument.  However,  if  it
20       fails to set a limit for some other reason it will continue try-
21       ing to set the remaining limits.
22
23       Not all the following resources are supported  on  all  systems.
24       Running ulimit -a will show which are supported.
25
26       -a     Lists all of the current resource limits.
27       -b     Socket buffer size in bytes (N.B. not kilobytes)
28       -c     512-byte blocks on the size of core dumps.
29       -d     Kilobytes on the size of the data segment.
30       -f     512-byte blocks on the size of files written.
31       -i     The number of pending signals.
32       -k     The number of kqueues allocated.
33       -l     Kilobytes on the size of locked-in memory.
34       -m     Kilobytes on the size of physical memory.
35       -n     open file descriptors.
36       -p     The number of pseudo-terminals.
37       -q     Bytes in POSIX message queues.
38       -s     Kilobytes on the size of the stack.
39       -T     The number of simultaneous threads available to the user.
40       -t     CPU seconds to be used.
41       -u     The number of processes available to the user.
42       -v     Kilobytes on the size of virtual memory.  On some systems
43              this refers to the limit called `address space'.
44       -w     Kilobytes on the size of swapped out memory.
45       -x     The number of locks on files.
46
47       A resource may also be specified by  integer  in  the  form  `-N
48       resource', where resource corresponds to the integer defined for
49       the resource by the operating system.  This may be used  to  set
50       the  limits for resources known to the shell which do not corre-
51       spond to option letters.  Such limits will be shown by number in
52       the output of `ulimit -a'.
53
54       The  number may alternatively be out of the range of limits com-
55       piled into the shell.  The shell will try to read or  write  the
56       limit anyway, and will report an error if this fails.
57