#!/bin/sh
tcpdump -i eth0 -c $1 >>arp_count.txt;
echo "----------------------------------------------------------------------"
echo ""
echo "The ARP Packets takes $(($(grep arp arp_count.txt|wc -l)*100/$1))% in $1 Packets Recived."
echo ""
echo "----------------------------------------------------------------------"
rm -f arp_count.txt
使用时输入要抓取的包数就行了。
阅读(1034) | 评论(0) | 转发(0) |