# 桀蝟餌絞閮剖 (ulimit -a # 舀亦券典)& O, {% }. ^- J
ulimit -n ! U! P' Y4 L4 i* `
1024$ F" W) E& {8 p, `! k
# r7 Z8 U& H# i) H& L& i2 |0 j# H+ w. f6 ]6 b
# limits.conf 閮剖 nofile (nofile - max number of open files) 憭批
- v$ E' p9 P0 S+ Jvim /etc/security/limits.conf ( F/ o' ?7 m1 A6 l2 N+ N g
! o) C- |" ^( u( w1 ? d2 \7 B% r# l4 W
- ~, k# g& }4 ]' V! w+ B7 H+ X1 [# 憓/靽格 銝餈啣抵 ( 2^20 = 1048576 )
3 W4 ~0 f$ c! o& v/ R* soft nofile 1048576: |# d* ~) q) B5 `
* hard nofile 1048576/ U! X& \( ~& U
, l9 Z; |9 }/ V! @; Y& G
1 t$ z5 b+ D( h8 P: y& Q# 餃箏, 餃, 瑁撠望箇暹迨
$ I7 ^- |5 m$ D5 g! b9 ?ulimit -n 4 N% Y3 k' x/ x$ s$ z* q Y
1048576
' B. Q0 h; p% F$ F! {! g ulimit -n 瘝箇 1048576 閰, 臭蝙典撥嗉身摰
5 {; T' F4 S- |" ^2 k Z3 v$ f Y7 S
: R6 p* V& c$ u( ]
ulimit -n 10485764 E+ ^ i4 [7 n4 N5 h& ]
1 R# x+ a: Y: ?" k% s7 j* M+ H
/ X. m3 f, {& N. d7 ~9 D# 瑼X亥身摰5 F. s, Q+ S; k7 @# I: m, b
ulimit -n
4 L9 F# `$ i+ r$ V: l4 [1048576
/ F' G8 \+ T; p |
|