#Simple Network Load Monitor
#Ben Marlin - marlin[at]cs[dot]toronto[dot]edu
#Notes: Needs an ssh setup where you can log into a machine
#*without* having to input your password. 

#Enter a list of machine names or ip addresses
boxes="foo.bar.net"

#This will keep running until you kill it with a ^c
while [ 1 ]
do
  clear
  for box in $boxes
  do
    #This should work for most boxes with a /proc file system
    #including just about any redhat linux box. If you get errors,
    #poke around and see if /proc/loadavg exists on the machines
    #you want to monitor.
    ssh $box 'echo -n `hostname`; echo -n "  ";  cat /proc/loadavg'
  done
  echo ''
  echo Type [ctrl]-c to exit. 
  #This controls the delay between updates in seconds. Set it to 
  #suit your needs.
  sleep 20
done
