Re: Postfix pipe process defer if error

2011-09-10 Thread Wietse Venema
Ramprasad: > I have a custom pipe script which postfix sends to > > For eg in master.cf > > bounce_handler unix - n n - - pipe >flags=FR argv=/opt/path/bounce_handler > > How do I configure postfix that it defers the mails in case the script > exits with an

Re: Postfix pipe process defer if error

2011-09-10 Thread Pascal Volk
On 09/10/2011 10:44 AM Ramprasad wrote: > Do I need to to use exit 75 > > I am using a C program that exits with exit(EXIT_FAILURE) > but that causes the mail to get bounced rather than defer Read the fine manual at: http://www.postfix.org/FILTER_README.html and search for EX_TEMPFAIL. Regards

Re: Postfix pipe process defer if error

2011-09-10 Thread Ramprasad
On 9/10/2011 1:23 PM, Pascal Volk wrote: On 09/10/2011 09:48 AM Pascal Volk wrote: Something like that: #!/bin/sh # do something with the message # check return code from the last command if [ $? -ne 0 ]; then return 75 fi return 0 Sorry - use exit instead of return: if [ $? -n

Re: Postfix pipe process defer if error

2011-09-10 Thread Pascal Volk
On 09/10/2011 09:48 AM Pascal Volk wrote: > Something like that: > > #!/bin/sh > > # do something with the message > > # check return code from the last command > if [ $? -ne 0 ]; then > return 75 > fi > return 0 Sorry - use exit instead of return: if [ $? -ne 0 ]; then

Re: Postfix pipe process defer if error

2011-09-10 Thread Pascal Volk
On 09/10/2011 09:27 AM Ramprasad wrote: > I have a custom pipe script which postfix sends to > > For eg in master.cf > > bounce_handler unix - n n - - pipe >flags=FR argv=/opt/path/bounce_handler > > > > How do I configure postfix that it defers the mails

Postfix pipe process defer if error

2011-09-10 Thread Ramprasad
I have a custom pipe script which postfix sends to For eg in master.cf bounce_handler unix - n n - - pipe flags=FR argv=/opt/path/bounce_handler How do I configure postfix that it defers the mails in case the script exits with an error