Currently ulimit -n shows 10000. I want to increase it to 40000. I've edited /etc/sysctl.conf and put fs.file-max=40000. I've also edited /etc/security/limits.conf and updated hard and soft values. But still ulimit shows 10000. After making all these changes I rebooted my laptop. I've access to root password.

usr_name@usr_name-lap:/etc$ /sbin/sysctl fs.file-max
fs.file-max = 500000

Added following lines in /etc/security/limits.conf -

*     soft    nofile          40000
*     hard    nofile          40000

I also added following line in /etc/pam.d/su-

session    required   pam_limits.so

I've tried every possible way as given on other forums, but I can reach up to a maximum limit of 10000, not beyond that. What can be the issue?

I'm making this change because neo4j throws maximum open file limits reached error.

  • Remove the change to sysctl.conf and reboot! You don't want to set the system-wide file descriptor limit to 40,000! (Check /etc/security/limits.d, the problem is most likely there.) – David Schwartz Feb 2 '14 at 22:25
  • or you can as sudo use root instead of *. You actually want both. Then log-out, back in and you are butter. – Shane May 15 '15 at 17:47
  • take a look at this stackoverflow.com/questions/21515463/… – goggelj Feb 29 '16 at 19:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.