Skip to content

Instantly share code, notes, and snippets.

@njs50
Last active December 26, 2015 09:09
Show Gist options
  • Save njs50/7127861 to your computer and use it in GitHub Desktop.
Save njs50/7127861 to your computer and use it in GitHub Desktop.
get number of open file handles by process
sudo lsof | perl -lane '$x{"$F[0]:$F[1]"}++; END { print "$x{$_}\t$_" for sort {$x{$a}<=>$x{$b}} keys %x}'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment