1. file-max

/proc/sys/fs/file-max:

这个文件决定了系统级别所有进程可以打开的文件描述符的数量限制,如果内核中遇到VFS: file-max limit <number> reached的信息,那么就提高这个值。

设置方式:

# /etc/sysctl.conf
fs.file-max = 6553500
sysctl -p

2. file-nr

这个是一个状态指示的文件,一共三个值,第一个代表全局已经分配的文件描述符数量,第二个代表自由的文件描述符(待重新分配的),第三个代表总的文件描述符的数量。

cat /proc/sys/fs/file-nr

3. nofile

nofile全称number of open files,最大可打开的文件描述符数量,这个限制是针对用户和进程来说的。

3.1. 全局修改,永久生效,需要重启

# /etc/security/limits.conf
* soft nofile 65535
* hard nofile 65535

注意:对于ubuntu系统,还需要加载相应的pam模块才能生效

# /etc/pam.d/login
# Sets up user limits according to /etc/security/limits.conf
# (Replaces the use of /etc/limits in old login)
session required pam_limits.so

3.2. 临时调整

ulimit -HSn 655350

fs-max、file-nr和nofile的关系的更多相关文章

  1. supervisor监管进程max file descriptor配置不生效的问题

    配置了 sudo vim /etc/security/limits.conf * soft nofile * hard nofile   单独起进程没问题, 放到supervisor下监管启动,则报错 ...

  2. ES部署报错 max file size 和 kibana 报错File size limit exceeded

    启动失败一 ERROR: [2] bootstrap checks failed [1]: max file descriptors [4096] for elasticsearch process ...

  3. 安装排错 max file descriptors [4096] for elasticsearch process is too low, increase to at least [65536]

    https://blog.csdn.net/cookzrk/article/details/80179006 转载:https://my.oschina.net/u/2510243/blog/8105 ...

  4. 记一次环境变量导致的elasticsearch启动错误:max file descriptors [65535] for elasticsearch process is too low, incre

    问题描述,elasticsearch启动时报max file descriptors错误: [hadoop@node-33 elasticsearch-5.4.0]$ bin/elasticsearc ...

  5. 3ds Max File Format (Part 3: The department of redundancy department; Config)

    Now we'll have a look at the Config stream. It begins like follows, and goes on forever with various ...

  6. 3ds Max File Format (Part 1: The outer file format; OLE2)

    The 3ds Max file format, not too much documentation to be found about it. There are some hints here ...

  7. FS,FT,DFT,DFS和DTFT的关系

    对于初学数字信号(Digital Signal Processing,DSP)的人来说,这几种变换是最为头疼的,它们是数字信号处理的理论基础,贯穿整个信号的处理. FS:时域上任意连续的周期信号可以分 ...

  8. linux alsa音频中采样率fs、比特率BCLK 、主时钟MCLK关系

    转:https://blog.csdn.net/lugandong/article/details/72468831 一.拿512fs说话: 看图知道采样的位深是32bit(位),左右声道各占了8*3 ...

  9. 3ds Max File Format (Part 5: How it all links together; ReferenceMaker, INode)

    At this point, you should start to familiarize yourself a bit with the publicly available 3ds Max AP ...

随机推荐

  1. CentOS7 + Nginx1.13.5 + PHP7.1.10 + MySQL5.7.19 源码编译安装

    一.安装Nginx 1.安装依赖扩展 # yum -y install wget openssl* gcc gcc-c++ autoconf libjpeg libjpeg-devel libpng ...

  2. 由 System.arraycopy 引发的巩固:对象引用 与 对象 的区别

    作者:林冠宏 / 指尖下的幽灵 掘金:https://juejin.im/user/587f0dfe128fe100570ce2d8 博客:http://www.cnblogs.com/linguan ...

  3. centos7基础学习第一天

    Linux是一个操作系统: 智能手机,Android和ios.Windows: 网站.游戏.QQ.微信等都是运行在Linux系统之上的应用:客户端.服务器端交互的: Linux的起源: Linux之前 ...

  4. FPGA在其他领域的应用(四)

    工业领域: 从工厂和过程自动化到能源基础设施和机器视觉系统,工业产品有助于改善我们的世界.产品必须安全.可靠.适应性强,而且耐用.同时,商业成功要求你在激烈竞争的市场中行动迅速,同时降低总成本. 英特 ...

  5. ubuntu环境下lnmp环境搭建(2)之Nginx

    1. ubuntu编译安装nginx http://www.cnblogs.com/zhangjun516/archive/2013/02/03/2890990.html 1. 手动编译安装 Ngin ...

  6. vDSP加速的应用

    vDSP 是IOS提供一系列加速处理算法..在优化时可以考虑应用一二... 1.在项目中加入Accelerate.framework库 点开项目属性->Build Phases->Link ...

  7. ios获取内核数目

    #include <mach/mach_host.h> unsigned int countCores() { host_basic_info_data_t hostInfo; mach_ ...

  8. Django Cookie 和 Sessions 应用

    在Django里面,使用Cookie和Session看起来好像是一样的,使用的方式都是request.COOKIES[XXX]和request.session[XXX],其中XXX是您想要取得的东西的 ...

  9. ABAP字符串的加密与解密

    FIEB_PASSWORD_DECRYPT:字符串解密:FIEB_PASSWORD_ENCRYPT:字符串加密.旧版本的可以用. PARAMETERS:str1 type char32 OBLIGAT ...

  10. invalid types 'int[int]' for array subscript// EOF 输入多组数据//如何键盘输入EOF

    数组维度搞错了 一次运行,要输入多组数据,直到读至输入文件末尾(EOF)为止 while(scanf("%d %d",&a, &b) != EOF) // 输入结束 ...