Watch as I awkwardly stumble through life

Sort web server logs to find top users

Posted by Marius Voila on September 23, 2010 in London, U.K . — 0 comments This post contains 63 words

Sometimes there is a very quick need to determine what user(s) are causing high load to a particular page. Instead of tailing high-speed logs and giving yourself a headache, Throw in a one-lined piped cat command to give you the info you’re after without the foreplay. cat /path/to/access.log | awk '{print $1}' | sort | uniq -c | sort -n | tail