Re: [Tutor] parsing sendmail logs

2008-07-18 Thread Jeff Younker
If you run a pipeline chain from within subprocess every part of the chain will be a separate process, thats a lot of overhead. Thats why admins tend to prefer writing utilities in Perl rather than bash these days. ... Nobody I know uses perl for systems administration because it doesn't have

Re: [Tutor] parsing sendmail logs

2008-07-17 Thread nibudh
2008/7/16 Jeff Younker <[EMAIL PROTECTED]>: > Parsers as referenced in your link are intended for heavy-duty lifting > such as parsing programming languages. > > Sendmail logs are very simple, so those parsers are vast overkill. Split > on whitespace combined with regular expressions should be u

Re: [Tutor] parsing sendmail logs

2008-07-17 Thread nibudh
2008/7/15 Martin Walsh <[EMAIL PROTECTED]>: > > Any pragmatic advice on building or working with a framework to get > > to the point where i can do analysis on my logs would be cool. > > > > > As an exercise, I think it would be a reasonable approach to write > python derivatives of the s

Re: [Tutor] parsing sendmail logs

2008-07-15 Thread Alan Gauld
"Monika Jisswel" <[EMAIL PROTECTED]> wrote to say the truth I never thought about "additional overhead of getting the input/output data transferred" because the suprocess itself will contain the (bash)pipe to redirect output to the next utility used not the python subprocess.PIPE pipe so it w

Re: [Tutor] parsing sendmail logs

2008-07-15 Thread Jeff Younker
On Jul 14, 2008, at 12:29 AM, nibudh wrote: Hi List, I'm looking for some support libraries that will help me to parse sendmail logs. I'm confused about whether i need a "parser" per se, and if i do which parser to use. I found this website http://nedbatchelder.com/text/python-parsers.htm

Re: [Tutor] parsing sendmail logs

2008-07-15 Thread Martin Walsh
Monika Jisswel wrote: > to say the truth I never thought about "additional overhead of getting > the input/output data transferred" because the suprocess itself will > contain the (bash)pipe to redirect output to the next utility used not > the python subprocess.PIPE pipe so it will be like one su

Re: [Tutor] parsing sendmail logs

2008-07-15 Thread Monika Jisswel
> > but in that case use bash or ksh Hi Alan, to say the truth I never thought about "additional overhead of getting the input/output data transferred" because the suprocess itself will contain the (bash)pipe to redirect output to the next utility used not the python subprocess.PIPE pipe so it

Re: [Tutor] parsing sendmail logs

2008-07-15 Thread Alan Gauld
"Monika Jisswel" <[EMAIL PROTECTED]> wrote but if you want to go on your own I believe awk, grep, sort are extremely extremely extremely (yes 3 times !) powerfulI tools, so giving them up is a ... a python program that uses them thru subprocess module, I am a big fan of awk but I'd never w

Re: [Tutor] parsing sendmail logs

2008-07-14 Thread nibudh
On Tue, Jul 15, 2008 at 4:10 AM, Monika Jisswel <[EMAIL PROTECTED]> wrote: > lire & logethy are an option. > but if you want to go on your own I believe awk, grep, sort are extremely > extremely extremely (yes 3 times !) powerfulI tools, so giving them up is a > bad decision I guess either talki

Re: [Tutor] parsing sendmail logs

2008-07-14 Thread nibudh
On Mon, Jul 14, 2008 at 8:47 PM, Kent Johnson <[EMAIL PROTECTED]> wrote: > Lire looks like it might be useful: > http://www.logreport.org/lire.html > I have seen lire, of course it's Perl, but looking over the source would give me some ideas. In fact from a practical point of view if it does the

Re: [Tutor] parsing sendmail logs

2008-07-14 Thread Monika Jisswel
lire & logethy are an option. but if you want to go on your own I believe awk, grep, sort are extremely extremely extremely (yes 3 times !) powerfulI tools, so giving them up is a bad decision I guess either talking about thier speed or what they would allow you to do in few lines of code. so w

Re: [Tutor] parsing sendmail logs

2008-07-14 Thread Kent Johnson
On Mon, Jul 14, 2008 at 3:29 AM, nibudh <[EMAIL PROTECTED]> wrote: > Hi List, > > I'm looking for some support libraries that will help me to parse sendmail > logs. Lire looks like it might be useful: http://www.logreport.org/lire.html > Initially I'm wanting to be able to report on who the recip

[Tutor] parsing sendmail logs

2008-07-14 Thread nibudh
Hi List, I'm looking for some support libraries that will help me to parse sendmail logs. I'm confused about whether i need a "parser" per se, and if i do which parser to use. I found this website http://nedbatchelder.com/text/python-parsers.html which compares a slew of python parsers. Initiall