FAQ
Being a total Perl noob I get tasked with some log parsing duties. The
project involves parsing the apache access log. What I need to be able
to do is get the "time served" data per hour per page.

Something like: script.pl <url> <time> would return all the logged
instances of that url and how long it took to serve each page for the
time requested. I was able to pull that data out using awk into a flat
file, however that's not as efficient as having Perl read thru the file
and store the data on the fly.. I just have no idea how to start.. does
anyone have any ideas on this?

Search Discussions

  • Randal L. Schwartz at Mar 26, 2004 at 2:45 am
    "Christopher" == Christopher Gallimore writes:
    Christopher> Being a total Perl noob I get tasked with some log
    Christopher> parsing duties. The project involves parsing the apache
    Christopher> access log. What I need to be able to do is get the "time
    Christopher> served" data per hour per page.

    Either get Analog (for speedy parsing with lots of options,
    www.analog.cx), or roll something yourself with Apache::Log (a module
    you can find in the CPAN).

    --
    Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
    <merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
    Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
    See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupbeginners @
categoriesperl
postedMar 26, '04 at 1:21a
activeMar 26, '04 at 2:45a
posts2
users2
websiteperl.org

People

Translate

site design / logo © 2022 Grokbase