<acct-file>criticalset by the Hub
Accounting is the only channel through which the node tells what happened to messages. The line chooses what exactly it tells about. There are eight types, and each can be named by a letter or a word:
| Letter | Word | What the record is about |
|---|---|---|
| d | delivery | the message was delivered |
| b | bounce | a local bounce generated by the node itself |
| t | transient | a transient error for one recipient |
| tq | transient-queue | a transient error for the whole queue |
| r | receipt | the message was accepted by the node for sending |
| f | feedback-loop | a complaint parsed by the processor |
| rb | remote-bounce | a bounce that arrived as a message from the receiving server |
| rs | remote-status | a status report from the receiving server |
The default is d,b, and the line is written once per block.
A type that was not selected is an event that, for analytics, never happened. There is nothing to restore it from later: the node simply did not record it. So the set of types is, in essence, a description of what the fleet is able to measure at all.
Bounces come in two breeds, and this is the main subtlety of the set. b is bounces the node generated itself, synchronously, right in the conversation with the receiving server. Asynchronous bounces that arrive later as a message do not get in here — they have rb, and it works only with a configured bounce processor.
The vendor advises keeping t and tq in a separate file. One message can have many delivery attempts, and these records swell faster than the rest, cluttering the main file.
In the telemetry block five types are selected: d, b, rb, t, feedback-loop. Asynchronous bounces (rb) and complaints are included on purpose: without them the share of hard bounces and spam complaints on the fleet dashboard would be incomplete. tq, r and rs are not included.
In the file block (/var/log/pmta/acct.csv) it is d, b, rb: deliveries and both kinds of bounces. The file is read by the “Accounting stats” module. Transient failures and complaints are deliberately not written there: attempts bloat the file, complaints have a different set of columns, and both go out via the webhook anyway.
The set is chosen by the questions you will need to answer:
| Types | What becomes visible |
|---|---|
| d,b (default) | delivery and synchronous bounces |
| +rb | the real share of hard bounces |
| +f | spam complaints |
| +t,tq | why messages are delayed — in a separate file |
| +r | what was submitted to the node at all |
rb and f work only with configured processors — without a bounce and complaint parsing block, records of these types will not appear.
# fleet telemetry: deliveries, both bounce types and complaints <acct-file /var/log/pmta/mtahub-webhook.json> records d, b, rb, t, feedback-loop record-fields d * </acct-file> # transient errors — in a separate file, as the vendor advises <acct-file /var/log/pmta/transient.csv> records t, tq </acct-file>
what people get wrong and how it ends3 mistakes▶
§ 3.3.11.11
§ 3.3.11.11
our experience
4 relations
cut -d, -f1 /var/log/pmta/acct-*.csv | sort | uniq -c
3 articles
◇Two inbound report processors and what to do with themBounces by message and complaints are parsed by two identically structured blocks; each has its own address list and its own pair of decisions about the message’s fate.◇What the node tells about itself and through which channelsSeven observation surfaces: the web monitor, the console in four formats, the log, accounting, accounting search, metrics and export to external analytics.◇Five ways for a queue to hand off a messageA queue does not have to use SMTP: it can write to a file, run a program, call over HTTP or discard.