<dns>
The default is 5m. The line sets how often the engine re-resolves the domains from the precache list.
The manual describes this as a replacement for the record’s time to live: the interval is similar to it in meaning, but it is set manually and overrides the one set by the receiver. The usual TTLs for these domains are ignored.
Hence a direct consequence, which is exactly why this line is worth remembering: the receiver no longer controls how quickly you learn about a change in its route. You control it — with this very line.
It works only together with the list: precached-domains-file.
The second half is the reverse: a short interval on a long list is a constant load on the resolver. The number of domains divided by the interval is the number of queries per second — and they go out always, not only when there are messages.
What to set. The interval is compared with the record TTL at the receiver itself:
| Value | When |
|---|---|
| 5m (default) | the list is short, the receivers are large and change routes |
| shorter | the receiver sets a very short TTL, and falling behind is not an option |
| longer | the list is large, and these domains’ routes have not changed for years |
The guideline is simple: the interval must not be noticeably longer than the TTL the receiver set itself. It did not choose it at random.
# an interval shorter than what large receivers set <dns> precached-domains-file /etc/pmta/precached-domains.txt precached-refresh-interval 2m</dns>
what people get wrong and how it ends2 mistakes▶
§ 3.3.16.2
our experience
1 relation
grep -n -A4 '^<dns>' /etc/pmta/config wc -l /etc/pmta/precached-domains.txt dig +noall +answer +ttlid gmail.com MX | head -3
3 articles
◇How the policy for a receiver is assembledSettings are assembled from the most general pattern to the most precise; the order of blocks in the file means nothing.◇Backoff mode — the queue's second personalityA queue that a receiver has started refusing switches to a parallel set of limits, retries and routes — ten directives that act only in this mode.◇Reputation monitoring inside the nodeThe engine itself watches the receiving servers’ replies and changes the queue mode on a pattern match — a reaction within the connection, not through telemetry.