#!/bin/sh a=0; while [ true ]; do b=`ifconfig $1 |grep "RX bytes" | sed 's/:/ /g' |awk '{print $3}'`; echo `expr $b - $a`; a=$b; sleep 1; done