I can use ulimit but I think that only affects my shell session. I want the limit increased for all processes. This is on Red Hat.
According to the article Linux Increase The Maximum Number Of Open Files / File Descriptors (FD), you can increase the open files limit by adding an entry to
Append a config directive as follows:
Then save and close the file. Users need to log out and log back in again to changes take effect or they can just type the following command:
You can also verify your settings with the command:
Justin's answer tells you how to raise the number of open files available total to the whole system. But I think you're asking how to raise the per-user limit, globally. The answer to that is to add the following lines to
(Where the * means all users.)
There's some summary documentation in that file itself and in
And, I have to admit, I have no idea where that 1024 default comes from. And believe me, I looked. I even tried without the pam_limits module configured, and it's still there. It must be hard-coded in somewhere, but I'm not exactly sure where.
Increase max number of ulimit open file in Linux
1)Step : open the sysctl.conf and add this line fs.file-max = 65536
vi /etc/sysctl.conf add end of line fs.file-max = 65536
save and exit.
2)Step : vi /etc/security/limits.conf and add below the mentioned
* soft nproc 65535
* hard nproc 65535
* soft nofile 65535
* hard nofile 65535
save and exit check max open file ulimit
[root@localhost# ulimit -a
open files (-n) 65535