Skip to content

Instantly share code, notes, and snippets.

@ptitfred
Created May 22, 2012 12: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 ptitfred/2768733 to your computer and use it in GitHub Desktop.
Save ptitfred/2768733 to your computer and use it in GitHub Desktop.
Expresses the load relative to processors count (in percents)
/usr/bin/printf %0.f%%\\n $(echo $(cat /proc/loadavg | cut -d" " -f1) / $(grep -c processor /proc/cpuinfo) "* 100" | bc -l)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment