Wednesday, April 8, 2009

Postfix enable Subject for logging

To enable logging of the "Subject:" information feature in Postfix, you need to modify the "header_checks" file in the main.cf file.

To create a file use this:
"regexp:/etc/postfix/header_checks".

main.cf entry = "header_checks = regexp:/etc/postfix/header_checks"

Once that file is created, you need to modify the file by adding:
"/^Subject:/ WARN"

This will add the Subject text to the info or mail.info log file. You can then grep based on the subject text.

No comments: