mirror of
https://github.com/fish-shell/fish-shell.git
synced 2024-11-23 10:43:32 +08:00
Add missing documentation file for ulimit
darcs-hash:20051015111139-ac50b-49fd5b2351360f7fe35f7b376605c753b5e4ad2d.gz
This commit is contained in:
parent
4530ce8194
commit
c5b8393903
52
doc_src/ulimit.txt
Normal file
52
doc_src/ulimit.txt
Normal file
|
@ -0,0 +1,52 @@
|
|||
|
||||
\section ulimit ulimit - Set or get the shells resurce usage limits
|
||||
|
||||
\subsection ulimit-synopsis Synopsis
|
||||
<tt>ulimit [OPTIONS] [LIMIT]</tt>
|
||||
|
||||
\subsection ulimit-description Description
|
||||
|
||||
The ulimit builtin provides control over the resources available to
|
||||
the shell and to processes started by it. The -H and -S options
|
||||
specify that the hard or soft limit is set for the given resource. A
|
||||
hard limit cannot be increased once it is set; a soft limit may be
|
||||
increased up to the value of the hard limit. If neither -H nor -S is
|
||||
specified, both the soft and hard limits are set. The value of limit
|
||||
can be a number in the unit specified for the resource or one of the
|
||||
special values hard, soft, or unlimited, which stand for the current
|
||||
hard limit, the current soft limit, and no limit, respectively. If
|
||||
limit is omitted, the current value of the soft limit of the resource
|
||||
is printed, unless the -H option is given. When more than one
|
||||
resource is specified, the limit name and unit are printed before the
|
||||
value. Other options are interpreted as follows:
|
||||
|
||||
- <code>-a</code> or <code>--all</code> Set or get all current limits
|
||||
- <code>-c</code> or <code>--core-size</code> The maximum size of core files created
|
||||
- <code>-d</code> or <code>--data-size</code> The maximum size of a process’s data segment
|
||||
- <code>-f</code> or <code>--file-size</code> The maximum size of files created by the shell
|
||||
- <code>-l</code> or <code>--lock-size</code> The maximum size that may be locked into memory
|
||||
- <code>-m</code> or <code>--resident-set-size</code> The maximum resident set size
|
||||
- <code>-n</code> or <code>--file-descriptor-count</code> The maximum number of open file descriptors (most systems do not allow this value to be set)
|
||||
- <code>-s</code> or <code>--stack-size</code> The maximum stack size
|
||||
- <code>-t</code> or <code>--cpu-time</code> The maximum amount of cpu time in seconds
|
||||
- <code>-u</code> or <code>--process-count</code> The maximum number of processes available to a single user
|
||||
- <code>-v</code> or <code>--virtual-memory-size</code> The maximum amount of virtual memory available to the shell
|
||||
|
||||
If limit is given, it is the new value of the specified resource. If
|
||||
no option is given, then -f is assumed. Values are in kilobytes,
|
||||
except for -t, which is in seconds and -n and -u, which are unscaled
|
||||
values. The return status is 0 unless an invalid option or argument is
|
||||
supplied, or an error occurs while setting a new limit.
|
||||
|
||||
The fish implementation of ulimit should behave identically to the implementation in bash, except for these differences:
|
||||
|
||||
- Fish ulimit supports GNU-style long options for all switches
|
||||
- Fish ulimit does not support the -p option for getting the pipe size. The bash implementation consists of a compile-time check that empirically guesses this number by writing to a pipe and waiting for SIGPIPE.
|
||||
- Fish ulimit does not support getting the values of multiple limits in one command, except by using the -a switch
|
||||
|
||||
\subsection ulimit-example Example
|
||||
|
||||
<tt>ulimit -Hs 64</tt>
|
||||
|
||||
would set the hard stack size limit to 64 kB:
|
||||
|
Loading…
Reference in New Issue
Block a user