大概如下

 

1:文件句柄  可以理解为文件的索引

2: 设置方式

    系统修改 /etc/security/limits.conf

root soft nofile 65535
root hard nofile 65535
*    soft nofile 65535
*    hard nofile 65535

  正常情况1W的数量就很大了,  root 表示用户, soft 表示应用,可修改为

root soft nofile 65535
root hard nofile 65535
*    soft nofile 25535
*    hard nofile 25535

 

  Nginx针对进程的句柄数限制,修改.conf文件

 

 

worker_rlimit_nofile 35535;  进程的句柄数

对于小站点1W 足够了

 

 use epoll

 

posted on 2019-07-24 15:36  1161588342  阅读(851)  评论(0编辑  收藏  举报