2011/11/25 Wietse Venema <
wie...@porcupine.org>:
Thanks Wietse (also for the honor).
Maybe I've been not clear enough and I apologyze for that.
I'll try to describe a real life case.
Once I do the submission with sendmail tool, I need to check on my
machine whether the message actually left the system for the delivery
(which can access the Internet) or if it got queued or trashed for
some reason.
As far as I remember I can link the various lines in the log only
thanks to the queue ID.
This is what I do, step by step, within the logs:
0. First restrict the search field to a "reasonable" time period in
the logs. Usually one day.
1. I look for "postfix/qmgr" and the destination email address to
extract che queue ID (something like 42DF66C96E).
2. I look then for both that queue ID and "postfix/smtp" in order to
extract the status (something like "status=sent") and the remote SMTP
response (something like "(250 2.0.0 OK 1322295987
b11si12544560fak.190)" ).
3. I look then for both that queue ID and "postfix/cleanup" in order
to extract the local message-ID (something like
"message-id=<201111260826...@system.domain>")
The step #2 is needed in order to know whether the message actually
left the system (status=sent) or bounced or got deferred. I can also
get the actual response from the remore server.
Steps #2 and #3 are needed in order to be able to look for the message
on either side.
The steps #0 and #1 are approximate, especially when I send several
distinct messages in the same second to the same destination. Which
can easily happen.
I understood that I cannot grab the local message ID straight from
sendmail, this is why I focused on the queue ID.
But, is it possible to know the queue ID from the sendmail tool (or
whatever other submission tool) to be reasonably precise on the
subsequent email tracking lookups?