Linux Shell 脚本 过滤NetScreen防火墙日志(2)

[orcle@localhost ~]$ ./syslogana  /usr/Syslog2011-09-30.txt awk { for(i=1;i<=NF;i++) { if( ~ /sent/ ) print ,i++,,i++,,i++, } } ' Syslog2011-09-30.txt | awk '{ print Syslog2011-09-30.txt,,, }'  >/var/tmp/sysn................................... sed 's/=/ /g' /var/tmp/sysn >/var/tmp/sysnn...................................awk '{ sent[] += ;Recv[] +=  } END { for(i in sent) print i,tt, sent[i],tt,Recv[i] }' /var/tmp/sysnn >/var/tmp/sysnnn...................................IP                      Send bytes(B)           Recv bytes(B)=====================================================================10.2.0.195               389190206               3.21879e+0910.2.0.230               133985217               133386378710.2.0.240               86287521                50698167110.100.1.240             69406016                13480948610.2.0.249               56816187                14380941210.2.0.245               40095561                5869195010.2.0.228               36652824                18304863010.2.0.194               27172677                8062195710.2.0.252               23434488                9307896210.100.5.252             20701571                14683126610.2.0.241               18873421                65888402

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/23380.html