idc下載統計

#!/bin/bash
#author:xumubin
#qq:40594324
PATH=$PATH:$HOME/bin:/usr/local/sbin:/usr/local/bin:/sbin:/usr/sbin:/usr/bin:/root/bin
export PATH

source /home/falcon/function/var

cd $IDCROOT/idcreport
ls
echo -e "${RED}請選擇日期${RES}"
read datecheck
cd $datecheck
while read hw_list hw_down
do
        grep $hw_list wgetdown.txt
        grep $hw_list wgetdown.txt |sort -nt: -k 3|sed '/^.*speed :0 K/d'>/root/count.txt
        awk -F '[: ]+' '{print $6}' /root/count.txt >/root/count1.txt
        echo -e "$hw_list  `awk -F'[: ]+' ' {sum+=$6}END{printf "   average speed is %.f k/s\n",sum/NR}' /root/count.txt`"
        echo -e "$hw_list min average speed is `head -n 1 /root/count1.txt` K/s"
        echo -e "$hw_list min average speed is `tail -n 1 /root/count1.txt` K/s"
        echo -e ""
done</home/falcon/ip_list/idcdownlist

北美測試的結果

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章