Skip to main content

Too many open files

Comments

2 comments

  • Jason Azze

    "Note that this assumes jenkins is the Unix user running the Jenkins process."
    Indeed. And if you're running JOC, the user is probably jenkins-oc. It only took me a couple of hours to figure out I was changing the limits for the wrong user.

    0
  • Steven Christenson

    Based on our results, it may NOT be sufficient to increase the Jenkins limits if the system limit is lower.

    Here is one guide that may help

    I
    n summary:

    1. Check the system limit:   cat /proc/sys/fs/file-max
    2. Increase the system limit:   sudo sysctl -w fs.file-max=100000
    3. Make the increase permanent:  sudo vi /etc/sysctl.conf
         change or add the line "fs.file-max = 100000"
    4. If you are spawning processes that run as other users, you may need to add /etc/security/limits.conf for those user(s) as well.

    Jenkins may need to be restarted to make all changes take effect.

    If you have the metrics plugin installed, you can monitor the file-handle limit RATIO (called vm.file.descriptor.ratio)

    There is a known file handle leak in 2.60.x Jenkins that manifests as a constant leak of log files. We've watched Jenkins accumulate 1000 additional file handles per day. 

    1

Please sign in to leave a comment.

About CloudBees Support

Our Support Engineers are available to help with any questions or problems you may have with any of our products.