I just committed a patch which does this, and some other changes to make this work better.
Cheers,
Simon.
On 29/12/17 21:56, e9hack wrote:
> Hi,
>
> since some time, the log is flooded with messages like this:
>
> Fri Dec 29 20:53:50 2017 daemon.warn dnsmasq[20961]: reducing DNS packet size
> for nameserver 217.237.151.142 to 1280
> (17, 1280)
>
> I did change the name server and start dnsmasq with the option
> '-edns-packet-max=1280'. It doesn't relay help. I did
> check the related source code. I don't understand the source code, but it
> looks strange for me.
>
> I did add an additional check and now I don't get this messages any more.
>
> --- forward.c.save 2017-12-14 23:40:48.000000000 +0100
> +++ forward.c 2017-12-29 21:34:51.131218864 +0100
> @@ -853,8 +853,8 @@
> /* We tried resending to this server with a smaller maximum size and got
> an answer.
> Make that permanent. To avoid reduxing the packet size for an single
> dropped packet,
> only do this when we get a truncated answer, or one larger than the
> safe size. */
> - if (server && (forward->flags & FREC_TEST_PKTSZ) &&
> - ((header->hb3 & HB3_TC) || n >= SAFE_PKTSZ))
> + if ((server && (forward->flags & FREC_TEST_PKTSZ) &&
> + ((header->hb3 & HB3_TC) || n >= SAFE_PKTSZ)) && server->edns_pktsz >
> SAFE_PKTSZ)
> {
> server->edns_pktsz = SAFE_PKTSZ;
> prettyprint_addr(&server->addr, daemon->addrbuff);
>
> Regards,
> Hartmut
>
> _______________________________________________
> Dnsmasq-discuss mailing list
> [email protected]
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Dnsmasq-discuss mailing list [email protected] http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
