On Sat, May 8, 2010 at 9:37 AM, Mark Scholten <m...@streamservice.nl> wrote: > I am now doing it by parsing the logs, but I want to get the following > information in a MySQL database (currently I get it from the logs, but that > takes a few hours to parse for 1 day logs). I currently log the following > data in a MySQL database: > - sender (email address) > - receiver (email address) > - IP sender (from where did postfix receive it) > - date/time (when) > I would like to add: subject (but I didn't find a solution yet for that). > Also doing it "realtime" and not with a delay (as we don't do parse it every > minute and putting it in a database when we receive the information would be > great). >
You can log headers as subject with header_checks. > What do you think is the best solution? >> LogProcessor (http://sf.net/projects/logprocessor) provide a cool engine to load logfile in real-time to a database. Each module is a class, then is easy to implement support for new log formats. Postfix module isn't complete, and you can contribute with the project. Some modules like to Iptables are available. -- Reinaldo de Carvalho http://korreio.sf.net http://python-cyrus.sf.net "Don't try to adapt the software to the way you work, but rather yourself to the way the software works" (myself)