[wellylug] Apache (and other) log files to database
michael at diaspora.gen.nz
michael at diaspora.gen.nz
Wed Dec 6 19:12:38 NZDT 2006
Cliff Pratt writes:
>I have a need to write Apache (and maybe other) logfiles to a database.
pglogd logs to a Postgres database by reading Apache common logging
format records from a Unix socket.
If you're developing a web application, rather than a generic "I'm
running a web server", you may want to write a custom logger to add
"interesting information" from your application; in which case you'll
want a custom schema, etc. anyway, and you'd might be better off just
writing a Perl program.
Watch out for delaying web performance by making threads block logging
into the db; it can often be better to write logs into a file, and
then load a database from the flat file through a bulk loader utility
(eg Postgres' COPY FROM routine).
-- michael.
More information about the wellylug
mailing list