Re: [exim] Accounting (perl_startup, sql)

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Peter Bowyer
Fecha:  
A: Exim Users Mailing List
Asunto: Re: [exim] Accounting (perl_startup, sql)
On Mon, 10 Jan 2005 13:00:01 +0100, jesk <jesk@???> wrote:
> > * jesk <jesk@???> [0144 10:44]:
> >> Hello,
> >>
> >> i want to count the amount a router is ran, what would be the easiest
> >> way to do this?
> >> i want to do this without parsing and analyzing the logfiles, its just a
> >> temporary setup and influencing performance and overhead of exim isnt
> >> very important.
> >
> > eximstats can do that - it parses a mainlog, so there's no extra overhead.
> > --
>
>
> no i dont want parsing the logfiles, i need some specific accounting of
> some routers.
> is there no way to call a perl subroutine inside a router to increase a
> counter in a textfile?
> or to do a "fake-condition" inside a router to update a column with +1 in
> every run with a sql-statement?


You've just answered your own question - you can easily code a
condition which calls a $lookup of type [my|pg]sql, and the SQL
statement performs an UPDATE instead of a SELECT.

You could also use perl, but that would be more expensive.

Peter