itbrokeand.ifixit.com

Sometimes things break, and then we've got to fix them.

Simple Apache Access Log Analysis

-

Although there exist excellent tools for doing full log analysis, sometimes you just want to quickly pull out a little information. I recently found myself wanting to parse a section of our Apache access logs and find IPs consistently hitting the same URLs over and over. This lead to a line of awk, sort, uniq and grep chained together with pipes; since that didn't handle variations very well, it's now a line of awk, sort, uniq and grep chained together with pipes and wrapped in a little bit of Ruby. :)

Here is the Github gist.

comments powered by Disqus