Q. We would like to enable subject logging in Postfix, how do we go about doing that?
A. First, you need to install postfix-pcre package (Perl Compatible Regular Expressions support for postfix). We were doing it on Ubuntu 12, so:
apt-get install postfix-pcre
Create a file to check the headers: eg /etc/postfix/header_checks
In the /etc/postfix/main.cf add the following line:
header_checks = pcre:/etc/postfix/header_checks
The logs should reflect the changes: