Skip to content

Instantly share code, notes, and snippets.

@hailinzeng
Last active December 29, 2015 10:09
Show Gist options
  • Save hailinzeng/7655549 to your computer and use it in GitHub Desktop.
Save hailinzeng/7655549 to your computer and use it in GitHub Desktop.
watch jvm process thread count
#!/bin/bash
while true; do pstree | grep "|-java" | awk -F* '{print $1}' | sed -e 's/|-java---//g' | sed -e 's/ //g' | tr "\\n" ","; date +"%D %T"; sleep 10; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment