zoukankan      html  css  js  c++  java
  • 调整Linux最大文件打开数

    1、编辑/etc/security/limit.conf 最后一行增加如下内容

      *   soft   nofile    65535

           *   hard  nofile    65535

    2、在 /etc/rc.local 中添加

          ulimit -SHn  65535

    备注:如查看nginx应用的最大文件打开数脚本

        for pid in `ps -ax | grep nginx | grep -v grep | awk '{print $2}'`

        do

          cat /proc/${pid}/limits | grep 'Max open files'

        done

  • 相关阅读:
    echo
    shell
    grub
    find
    脚本案例
    dd if= of= MBR
    cat <<EOF> file
    fieldset——一个不常用的HTML标签
    闪烁图片
    跑马灯效果
  • 原文地址:https://www.cnblogs.com/wuhengood/p/11275670.html
Copyright © 2011-2022 走看看