I have my Apache logs set up like this:
LogFormat "%v %t %I %O" billing
How can I use AWK to generate a report which shows me the total bandwidth (received + sent) in MB per virtual host?
Here's an example log output:
bob.com [3 JULY 2013] 903 299
bob.com [8 JULY 2013] 192 138
luke.com [12 JULY 2013] 34 123
bob.com [19 JULY 2013] 616 213
luke.com [22 JULY 2013] 23 74
I'm looking for an output that sums up the 3rd and 4th columns for bob.com and luke.com without actually specifying the domains, as I have 50+ domains and wouldn't want to maintain a list. Much easier just to have the print out consolidated.