2

My server is currently hosting 8 separate websites (and growing) of which four are actively sending email throughout the day and some bulk (opt-in) lists at night. I just completed setting up PTR, SPF, Domainkeys and DKIM for each domain and am now wanting to move on to catching bounces to flag and remove bum email addresses.

I want to know if it is possible (and if so, how) to ask postfix to log the mail sent from each of my domains to separate files in addition to the single combined file in /var/log/. Though this doesn't gain me much as far as reading the logs myself it will allow me to run CRON parsers on the smaller logs at different times during the night so I can keep the load on my server from spiking for extended periods of time. Additionally it would make any other analytical work I need to do diagnosing errors with individual domains a little faster.

Should I run a single CRON to post-process the previous day's log and split (which would itself include some extended load), or can I set this up to be done automatically during log writing?

1 Answer 1

1

I assume you are using syslog , try to change to more advanced system loggers like rsyslog (new debian default's syslog) or syslog-ng

With them, you can use regexp to create different logfiles for each domain, and/or do properly realtime accounting.

2
  • @sntg Looks like rsyslog is going to work for me. Thanks for the quick response!
    – Shane
    Feb 3, 2010 at 19:34
  • Here is a more detailed explanation of how to do it: serverfault.com/questions/219162/…
    – lepe
    Nov 7, 2016 at 3:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .