Skip to content

Instantly share code, notes, and snippets.

@angelikatyborska
Created June 28, 2019 05:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save angelikatyborska/5c1fba7407e1c8a860df10e631a068af to your computer and use it in GitHub Desktop.
Save angelikatyborska/5c1fba7407e1c8a860df10e631a068af to your computer and use it in GitHub Desktop.
file descriptors commands
# check number of used FDs per process
ls /proc/$pid/fd | wc -l
# check number of used FDs system-wide
# returns: 1. allocated, 2. allocated but free (usually 0), 3. system max
sysctl fs.file-nr
# check FD per user limit
ulimit -a
# list open files
lsof
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment