The file-max file /proc/sys/fs/file-max sets the maximum number of file-handles that the Linux kernel will allocate. We generally tune this file to improve the number of open files by increasing the value of /proc/sys/fs/file-max to something reasonable like 256 for every 4M of RAM we have: i.e. for a machine with 128 MB of RAM, set it to 8192 – 128/4=32 32*256=8192.
So them if we want to see how many number of file-handles are setting in /proc/sys/fs/file-max we can use any text editor or the famous echo command.
And if we want see the list of file-handles we can do it with the command “lsof” …
~#> lsof | wc -l
