for that matter, bash and 'tr' might do this as well?


On 5/8/2007, "Jeff Pang" <[EMAIL PROTECTED]> wrote:



>Squid log format is strict.Try to do,

>

>s/\s+/,/g;

>

>on each line.

>

>

>2007/5/8, Craig Schneider <[EMAIL PROTECTED]>:

>> Hi Guys

>>

>> Following is a log file extract which I desperately need to covert to

>> coma separated for an entire logile called access.log (squid proxy log)

>> for reporting purposes. There has been some internet surfing abuse on a

>> client's network.

>>

>> 1178606984.937      1 192.168.1.55 TCP_DENIED/407 1904 POST

>> http://stats.update.microsoft.com/ReportingWebService/ReportingWebServic

>> e.asmx - NONE/- text/html

>> 1178606996.768   2714 192.168.1.182 TCP_MISS/200 539 POST

>> http://mail.google.com/mail/? engelam DIRECT/209.85.137.18

>> text/javascript

>> 1178607000.873   2259 192.168.1.182 TCP_MISS/200 2733 POST

>> http://mail.google.com/mail/? engelam DIRECT/209.85.137.19 text/html

>> 1178607004.012   1086 192.168.1.182 TCP_MISS/200 6140 GET

>> http://mail.google.com/mail/? engelam DIRECT/209.85.137.19 text/html

>>

>> Output would look something like:

>>

>> 1178606984.937,1,192.168.1.55,TCP_DENIED/407,1904,POST,http://stats.upda

>> te.microsoft.com/ReportingWebService/ReportingWebService.asmx,-,NONE/-,t

>> ext/html

>>

>> Any assistance with this would be greatly appreciated.

>>

>> Thanks

>> c

>>

>> --

>> To unsubscribe, e-mail: [EMAIL PROTECTED]

>> For additional commands, e-mail: [EMAIL PROTECTED]

>> http://learn.perl.org/

>>

>>

>>

>

>

>--

>Chinese Practical Mod_perl book online

>http://home.arcor.de/jeffpang/mod_perl/

>

>--

>To unsubscribe, e-mail: [EMAIL PROTECTED]

>For additional commands, e-mail: [EMAIL PROTECTED]

>http://learn.perl.org/

>

>

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to