* soft nofile 100000
* hard nofile
100000
其中*表示所有用户 nofile表示最大文件句柄数,表示能够打开的最大文件数目
session required pam_limits.so
3.编辑/etc/profile,添加如下内容
ulimit -SHn
100000
然后重新启动机器,再利用ulimit -n查看文件句柄数,发现文件句柄数变为100000
* soft nofile 100000
* hard nofile
100000
其中*表示所有用户 nofile表示最大文件句柄数,表示能够打开的最大文件数目
session required pam_limits.so
ulimit -SHn
100000
然后重新启动机器,再利用ulimit -n查看文件句柄数,发现文件句柄数变为100000
转载于:https://www.cnblogs.com/msnsj/p/4242611.html