For running a kafka service (with jbod disks, where we encountered problems due to too many open files) with an increased LimitNOFILE of 500000, we decided to increase the fs.file-max from 500000 to 1000000 on our RHEL 7.x server.

As I understand when increasing fs.file it also has an impact about open more file descriptors.

so we want to understand if other kernel parameters should be update also when increasing the fs.file-max ?

from reading , I saw that inode-max , should be “3-4 times larger than the value in file-max,

but we not found this parameter on our server

 more /proc/sys/fs/inode-max
/proc/sys/fs/inode-max: No such file or directory

more /etc/sysctl.conf
# System default settings live in /usr/lib/sysctl.d/00-system.conf.
# To override those settings, enter new settings here, or in an /etc/sysctl.d/<name>.conf file
# For more information, see sysctl.conf(5) and sysctl.d(5).
fs.file-max = 500000
vm.swappiness = 10
vm.vfs_cache_pressure = 50
  • 1
    hi, so, fs.file-max is the maximum number of open files. What other things would you need to increase to solve the problem you're having? We don't know what that problem is, so it's kind of hard to know what else you need to increase! Jan 4, 2022 at 13:48
  • lets say I want to increase the fs.file-max to 20000000 , so that it? , or maybe since we increased the fs.file-max we should increase or update additional params?
    – yael
    Jan 4, 2022 at 13:50
  • 2
    again, what other parameters do you need? I can't tell you what you need - I don't even know why you're increasing file-max. Tell us your problem before discussing the solution, engineering rule nr. 1! Jan 4, 2022 at 13:53
  • we increase the fs.max-file to 1000000 because we increased the LimitNOFILE to 500000 for kafka service , ( since we have kafka service that using jbod disks , then we faced the problem about too many open files ) , so we increase the imitNOFILE=500000 ,
    – yael
    Jan 4, 2022 at 13:56
  • 2
    I added that info into your question, it seems very important! Can you check whether my edit makes sense to you? Jan 4, 2022 at 14:01

1 Answer 1


the inode-max file doesn't exist because this sysfs was removed starting with linux-2.4; where there was no longer a static limit on the number of inodes.

/proc/sys/fs/inode-max (only present until Linux 2.2) This file contains the maximum number of in-memory inodes. This value should be 3–4 times larger than the value in file-max, since stdin, stdout and network sockets also need an inode to handle them. When you regularly run out of inodes, you need to increase this value.

  Starting with Linux 2.4, there is no longer a static limit
  on the number of inodes, and this file is removed.


To my knowledge, you should not need to adjust any other kernel parameters when adjusting fs.file-max.

That said, on systemd systems; sometimes you may need to set resource limits in /etc/systemd/user.conf (for user) or /etc/systemd/system.conf (system-wide), as systemd may override or ignore resource limits, in some circumstances.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .