<acct-file>
The line sets how often the engine closes the accounting file and starts a new one. The default is 1d.
🔴 It works only together with move-to. Without a destination directory the interval is silently ignored — the manual says so plainly. There will be no warning.
The second closing condition is size, max-size, and it works independently: the file starts over on reaching the ceiling even without a directory.
This line is not for the webhook. There the rhythm of batches is set by http-webhook-max-interval, and the manual refers to it explicitly.
Why it was removed rather than supplemented with a directory. The move has to be on the same volume, so it will not free up space; and delete-after stops working with move-to active, so files would start piling up in the archive directory with no expiry. The accounting file already has rotation: it is closed at max-size 25M and deleted after seven days.
The interval makes sense only with a destination directory:
| Value | When |
|---|---|
| 1d (default) | files are picked up once a day |
| 1h | an external collector comes often |
| without move-to | does not work at all |
For the webhook — a different line, http-webhook-max-interval.
# both lines are needed together, otherwise the interval stays silent <acct-file /var/log/pmta/acct.csv> move-to /var/log/pmta/archive move-interval 1h</acct-file>
what people get wrong and how it ends2 mistakes▶
§ 3.3.11.3
§ 3.3.11.21
2 relations
ls -la --time-style=full-iso /var/log/pmta/archive/ 2>/dev/null | tail -5
3 articles
◇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.◇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.◇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.