Skip to content

Instantly share code, notes, and snippets.

@binarytemple
Created February 11, 2016 12:03
Show Gist options
  • Save binarytemple/c35098b95deaddd11fe9 to your computer and use it in GitHub Desktop.
Save binarytemple/c35098b95deaddd11fe9 to your computer and use it in GitHub Desktop.
quick and dirty network rx_bytes sanity check
cat ~/bin/rx_bytes_60_seconds
function rx_bytes() { ifconfig eth0 | sed -ne '/RX bytes/{s_RX bytes:\([0-9]*\).*_\1_;s_ __g;p}'; }
start=$(rx_bytes)
sleep 60
end=$(rx_bytes)
echo "60 second count - rx_bytes = $(( end - start ))"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment