At 03:07 PM 5/5/99 -0500, Fred Lindberg wrote:
>What happens when qmail-send is killed, as e.g. a routine shutdown
>while qmail-remote is hanging onto clients?
>
>It appears that qmail-remote completes the delivery, but has nobody to
>tell it did so, resulting in duplications.
>
>Is this really what happens? Of course duplication in such a situation
>is quite acceptable. I'm just trying to find out if this is the source
>of the duplications seen (or if there is a real problem).
>
>Normally, when shutting down, qmail-send it is not doing deliveries, or
>trying deliveries that have a low likelihood of succeeding, i.e.
>redeliveries. Thus, this wouldn't be apparent. This time, I shut it
>down (-TERM) during maximal activity for reconfiguration (test system).

I am not sure I answer your question, but here is what I know on the subject:

qmail-send catches the TERM signal, waits for all qmail-remotes to complete
and shuts down. So if you kill -TERM (or just kill), there won't be any
duplicates.

However, if you kill -KILL (kill -9), qmail-send dies immediately and
results are unpredictable.

If you use sys V, a script is called to kill qmail-send
(/etc/rc?.d/K??script) with 'stop' as argument when you shutdown the
machine. Make sure that this script kill -TERM qmail-send.

David.

Reply via email to