Héctor Moreno Blanco
2011-Jun-02 08:13 UTC
[Dovecot] [dovecot] notifications when delivery fails
Hello Timo, We have dovecot 1.2.13. Is there any way to send notifications to the postmaster when a delivery fails? For example, when the dovecot index are corrupted and the mail is not sent to the user (the user who sent the message receives an error informing that the mail has not sent). Thank you very much in advanced. H?ctor Moreno Blanco. ______________________ This message including any attachments may contain confidential information, according to our Information Security Management System, and intended solely for a specific individual to whom they are addressed. Any unauthorised copy, disclosure or distribution of this message is strictly forbidden. If you have received this transmission in error, please notify the sender immediately and delete it. ______________________ Este mensaje, y en su caso, cualquier fichero anexo al mismo, puede contener informacion clasificada por su emisor como confidencial en el marco de su Sistema de Gestion de Seguridad de la Informacion siendo para uso exclusivo del destinatario, quedando prohibida su divulgacion copia o distribucion a terceros sin la autorizacion expresa del remitente. Si Vd. ha recibido este mensaje erroneamente, se ruega lo notifique al remitente y proceda a su borrado. Gracias por su colaboracion. ______________________
On Thu, 2011-06-02 at 10:13 +0200, H?ctor Moreno Blanco wrote:> Hello Timo, > > We have dovecot 1.2.13. Is there any way to send notifications to the > postmaster when a delivery fails?Create a script. Instead of running deliver directly, run something like: #!/bin/sh deliver $* err=$? if [ $err != 0 ]; then echo failed | mail postmaster fi exit $err> For example, when the dovecot index are corrupted and the mail is not > sent to the user (the user who sent the message receives an error > informing that the mail has not sent).This should never happen. The worst that can happen is that deliver returns temporary failure and its delivery is attempted again. Although if deliver crashes, some MTAs treat it as hard failure rather than temporary. You could prevent that with a wrapper script too.