Click to See Complete Forum and Search --> : Log File Parsing Help


gwaine
04-15-2002, 11:38 AM
Hi everyone!
I would like to parse my Apache access log to look for lines matching specific criteria. For example: full_photo.php?photo_id=45
I would like to see how many times that photo has been accessed. I've tried opening the log in a text editor, but the files are so huge, the program just kinda hangs. Is there a program out there that would be able to parse my log file and just give stats on those specific criteria? I don't need graphs or anything. Thanks!

msalerno
04-15-2002, 11:55 AM
Yes my friend. The all powerful grep will take care of this for you.

grep -c logo.gif ./access_log

You could also do it in perl easily, but you already have grep.

Good Luck.

gwaine
04-15-2002, 12:28 PM
Thanks so much for your help!!!

ph34r
04-15-2002, 02:41 PM
www.analog.cx (http://www.analog.cx) - for all your weblog needs. I use it to get stats on our colleges entire web presence - 2gb of logs in one month, with 1.5 to 2 million hits per month.