ENGINEERING NOTE / MAIL

What Postfix status=sent means

For an SMTP delivery, status=sent means the next server accepted the message. To work out how far it got, read the transport, recipient and relay response, then follow any queue handoffs.

DELIVERY RESULT

Read the whole result.

This illustrative log excerpt is shortened and wrapped for readability:

postfix/smtp[1204]: A1B2C3D4:
  to=<reader@example.net>,
  relay=mx.example.net[192.0.2.25]:25,
  dsn=2.0.0, status=sent
  (250 2.0.0 Ok: queued as E5F6A7B8)

smtp identifies the delivery transport. A1B2C3D4 is the local queue ID, and to identifies the recipient for this result. The relay accepted the message and returned its own queue ID, E5F6A7B8. If you have access to that server’s logs, the returned ID gives you a way to continue the investigation there.

The meaning of success depends on the transport: an SMTP relay, an LMTP server and local delivery represent different stages. The Postfix SMTP and LMTP manual describes how delivery requests and recipient results are handled. A successful SMTP handoff does not show what the receiving system later did with the message, including filtering, quarantine or inbox placement.

CORRELATION

Follow identifiers across each handoff.

Start from a known Message-ID, application correlation ID or local queue ID. For file-based Postfix logs, a queue-ID search gives a useful first set of lines:

rg -F 'A1B2C3D4' /var/log/mail.log

Look for events that contain two identifiers: an application entry with a correlation ID and Message-ID, a Postfix cleanup entry with a Message-ID and queue ID, or a queued as handoff. Follow those links through filters, reinjection and relays. The ID after queued as belongs to the accepting hop; it need not be another queue on the server you started from.

Keep the Postfix instance with each queue ID. The queue documentation notes that IDs are not globally unique and can also be reused within an instance. A bounded time window helps avoid joining an old message to a newer one with the same ID.

Timestamps help order events once they are correlated. On their own, they are a weak reason to join two lines: a busy server can send several messages to the same recipient in one second. MailForensics uses identifier expansion to follow those explicit links.

CURRENT QUEUE

Check whether the item is still queued.

postqueue -j

A live queue listing can show whether an item is present now, which helps interpret an earlier deferred-delivery event. Each returned entry records an item seen during the listing. The queue can change while it is collected, so this is not an atomic snapshot.

If the item is absent, return to the event trace. Absence alone does not tell you whether it was delivered, expired, removed or requeued under another ID. A later delivery result is more informative than an old retry event or a missing queue entry.

ASSESSMENT

Name the last confirmed stage.

If the application records submission but the supplied logs contain no matching Postfix event, the trace stops before Postfix. That gap does not establish a Postfix failure. If there is a queue entry without a delivery result, the last confirmed stage is queueing.

For the SMTP example above, the result is: mx.example.net accepted the message for reader@example.net. The remaining question is what happened on that server. Answering it requires downstream evidence, rather than a broader interpretation of the local status=sent line.