Skip to content

Instantly share code, notes, and snippets.

@ericstewart
Created July 25, 2011 15:45
Show Gist options
  • Save ericstewart/1104426 to your computer and use it in GitHub Desktop.
Save ericstewart/1104426 to your computer and use it in GitHub Desktop.
List open files and limits for java processes
for pid in `pidof java`; do echo "$(< /proc/$pid/cmdline)"; egrep 'files|Limit' /proc/$pid/limits; echo "Currently open files: $(ls -1 /proc/$pid/fd | wc -l)"; echo; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment