Linux check open file handles command


#count all open file handles command

lsof | wc -l

#List File Descriptors in Kernel Memory

sysctl fs.file-nr

#List File Opened By a PID 

 - find id by command ps aux
 - lsof -p <pid> | lso -a -p <pid>

 OR

 cd /proc/<pid>/fd 
 ls -l | wc -l

  •  
  •  
  •  
  •  

Viet Luu has written 318 articles

If you like what you are reading, please consider buying us a coffee ( or 2 ) as a token of appreciation.

Buy Me A Coffee

We are thankful for your never ending support.