czp3009 / blog

personal blog
GNU General Public License v3.0
4 stars 0 forks source link

Ubuntu增加最大文件打开数量限制 | czp's blog #15

Open czp3009 opened 5 years ago

czp3009 commented 5 years ago

https://www.hiczp.com/2018/10/22/Linux/Ubuntu%E5%A2%9E%E5%8A%A0%E6%9C%80%E5%A4%A7%E6%96%87%E4%BB%B6%E6%89%93%E5%BC%80%E6%95%B0%E9%87%8F%E9%99%90%E5%88%B6/

环境: Ubuntu Desktop 18.04众所周知, Linux 的文件打开数量限制是用 ulimit -n 命令查看的.$ ulimit -n 1024 然后我们就会发现默认只有 1024.然后我们按照人云亦云的办法, 去修改 /etc/security/limits.conf, 在文件末尾增加如下两行