ulimit 說明

ulimit官方描述
Provides control over the resources available to the shell and to processes started by  it,  on  systems that allow such control. 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.



提供控制 shell的可用資源和shell啓動的進程,在系統上容許這樣的操做。

-H和-S 選項是hard 或者soft 設置對於給定的資源。


一個hard 限制不能被增長 一旦被設置,  一個soft limit 能夠被增長 到hard限制的大小


若是 -H或者-S 都沒有被指定,那麼soft和hard 限制都被設置。


限制的值能夠是一個數字單位 對於hard soft的其中一個,或者是unlimited  表明硬限制



當前的soft 限制,和沒有限制, 或者單獨的

若是限制被忽略,  軟限制的當前的值 被打印,除非 指定-H選項 
# End of file
 * 		soft 	nofile 		6553 
 * 		hard 	nofile 		7553
* 		soft 	nproc 		65530
* 		hard 	nproc 		65531 
zjzc01:/root# ulimit   -H -a
core file size          (blocks, -c) unlimited
data seg size           (kbytes, -d) unlimited
scheduling priority             (-e) 0
file size               (blocks, -f) unlimited
pending signals                 (-i) 7808
max locked memory       (kbytes, -l) 64
max memory size         (kbytes, -m) unlimited
open files                      (-n) 7553
pipe size            (512 bytes, -p) 8
POSIX message queues     (bytes, -q) 819200
real-time priority              (-r) 0
stack size              (kbytes, -s) unlimited
cpu time               (seconds, -t) unlimited
max user processes              (-u) 65531
virtual memory          (kbytes, -v) unlimited
file locks                      (-x) unlimited
相關文章
相關標籤/搜索