Out: 451 4.3.0 Error: queue file write error
I found a lot of posts on the web asking about this problem over the
years without an answer.
Now I found out what actually happens: when it takes main smtpd
process more than smtpd_timeout (default: 300s) to receive all DATA,
filter smtpd process will timeout and close connection, even though in
the meantime main smtpd process continues to receive DATA. When main
smtpd process finishes receiving all DATA and tries to deliver it to
filter smtpd process, connection to filter is already closed and we
get this:
Out: 451 4.3.0 Error: queue file write error
I know I can increase smtpd_timeout on filter process to some
arbitrarily large value to fix this problem. But is there a better way
to do this? Is there a way to tell main process to deliver DATA in
chunks, instead of accumulating it all before passing to filter
process?
smtpd_proxy_options=speed_adjust
When this option is used on main smtpd process, postfix will receive
complete message before it will invoke filter, so filter will not
timeout on long messages. The only thing I worry about, postfix
documentation says with this option content filter must not
selectively reject recipients of a multi-recipient message. Does
anyone know if it is safe to use this option with spampd filter?