Simple bash script to view CPU & RAM usage every n seconds

view story

http://forum.xda-developers.com – this is a script made for devs who cant use ps or top command for some reasons like me. So i thought i'd share here. its originally made by Paul Colby(credits to him). this script doesnt work on my shell, so i modified it to be very simple(for newbies like me;)) ,and to be compatible with any bash shells. i've also added ram usage to view.. ram usage:p have fun coding! Code: busybox renice -n19 -p$$ busybox ionice -c3 -p$$ prev_total=0 prev_idle=0 while true; do cpu=`cat /proc/stat | head -n1 | sed 's/cpu  //'` user=`echo $cpu | awk '{print $1}'` system=`echo $cpu | awk '{print $2} (HowTos)