web page statistics - my first bash script

Please support our Shell Scripting advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: May 2005
Posts: 1
Reputation: danny_xmas is an unknown quantity at this point 
Solved Threads: 0
danny_xmas danny_xmas is offline Offline
Newbie Poster

web page statistics - my first bash script

 
0
  #1
May 14th, 2005
Hi there, I'm new to this forum and to bash scripting.

I am required to write a bash shell script that processes statistical information for a website. Each web page has a "hits" file associated with it, eg. index.hits. Each line of a hits file records a single access of that web page, including IP address and access time. Example line:

123.123.123.123 Mon Feb 7 22:02:35 GMT 2005

My script will process this information and present it in a table. I can't figure out how I would find if there where more than one "hit" from the same IP?

Can anyone give me a little help?

Many Thanks

Dan
Reply With Quote Quick reply to this message  
Join Date: Nov 2004
Posts: 21
Reputation: vgersh99 is an unknown quantity at this point 
Solved Threads: 0
vgersh99's Avatar
vgersh99 vgersh99 is offline Offline
Newbie Poster

Re: web page statistics - my first bash script

 
0
  #2
May 18th, 2005
use awk's associative arrays index by the first field [ip address].
vlad
+-----------------------------------+
| #include <disclaimer.h> |
+-----------------------------------+
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



Tag cloud for Shell Scripting
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC