quarta-feira, 7 de maio de 2014

AWK command line to parse greater consumer from Squid access.log

1. Introduction

AWK command line to interpret Squid's  access.log file


2. Example


awk '$8 != "-" {users[$3] = $8} $2 > 600000 && ($5 / ($2/1000)) > 65536 && $6 ~ /CONNECT/ {print int(($5 / ($2/1000))/1024) " " strftime("%F %T", $1) " " users[$3] " " $0}' < /var/log/squid/access.log | sort -n -k1



3. References



Nenhum comentário:

Postar um comentário