Skip to content

Instantly share code, notes, and snippets.

@hackerzgz
Created May 27, 2020 13:46
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 hackerzgz/dc1e7853b787552a822d797bd1d2da6d to your computer and use it in GitHub Desktop.
Save hackerzgz/dc1e7853b787552a822d797bd1d2da6d to your computer and use it in GitHub Desktop.
watch rx packets
#!/bin/bash
DEVICE=$1
if [[ "${DEVICE}" == "" ]];
then
echo "no special device, exit"
echo "usage: ./watch_rx_packets \$DEVICE"
exit 1
fi
while [[ true ]]; do
/sbin/ifconfig "${DEVICE}" | grep "RX packets";
sleep 1;
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment