1

In python using rsyslog I am logging error messages from postfix. However some error logs are broadcasted multiple times with minor changes in it like this:

postfix/error[34864]: 45E23361509: to=<sample@mail.com>, relay=none, delay=1.1, delays=0.01/1/0/0.01, dsn=4.3.0, status=deferred (unknown mail transport error)
postfix/error[34864]: 45E23361509: to=<sample@mail.com>, relay=none, delay=17, delays=17/0/0/0, dsn=4.3.0, status=deferred (unknown mail transport error)
postfix/error[34864]: 45E23361509: to=<sample@mail.com>, relay=none, delay=37, delays=37/0/0/0, dsn=4.3.0, status=deferred (unknown mail transport error)

These are same error logs for only one postfix mail attempt. If one mail operation goes wrong I receive like 7-8 error logs only delay value changed. I want to log only one of them.

Can you offer me a solution? Maybe like a configuration in rsyslog filters.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.