John Alex.: > Hi, I encountered the same issue on two FreeBSD 13.1 + Postfix 3.7.2 > installations. It > only occurs when trying to send an email with >4999 recipients (the mail > queue is > otherwise empty). This issue does not happen on another machine with FreeBSD > 13.0 + > Postfix 3.6.3. > > After some search I found that it is caused by the following addition in > qmgr_message.c in > 3.7 (line 441): > > if (strchr(expected_rec_types, rec_type) == 0) { > msg_warn("Unexpected record type '%c' at offset %ld", > rec_type, (long) curr_offset); > rec_type = REC_TYPE_ERROR; > break; > } > > in combination with the pre-existing (line 385): > > /* Keep interrupt latency in check. */ > if (recipient_limit > 5000) > recipient_limit = 5000; > > > If I remove the code that was introduced in 3.7, the mail is delivered > without issue. I > also tried changing 5000 to 10001 and the email was again succesfully > delivered to up to > 10000 recipients. > > So it seems this issue occurs whenever the mail queue total recipient count > reaches 5000 > addresses.
Thanks, that is very useful. This appeats to be a corner-case error, and that woiuld explain why the problem was difficult to reproduce. How was your Postfix queue file with 5000 recipients created? - with Postfix virtual_alias_maps expansion, - with Postfix alias_maps expansion (/etc/aliases), - by submitting a message with 5000 recipients over SMTP? - ?? I prefer not to remove the new sanity check, but instead fix the corner-case error. Wietse