Hi Willy,

On 06/24/2016 03:52 PM, Willy Tarreau wrote:
> Hi Conrad,
> 
> On Thu, Jun 23, 2016 at 06:49:19PM +0200, Conrad Hoffmann wrote:
>> Hi,
>>
>> attached is my shot at supporting negotiating UDP message sizes > 512 bytes
>> in the Haproxy DNS implementation. The default DNS size of 512 bytes can
>> often lead to truncated responses, which are discarded.
>>
>> With the attached patch and adding "udp_msg_size 2048" to my resolvers
>> section, I can succesfully use a hostname that yields ~100 A records in our
>> company network, something that did not work before.
>>
>> This was an approach suggested by Baptiste a long time ago, unfortunately I
>> got distracted with other things for a while. Nevertheless, I'd also like
>> to discuss
>>
>> a) whether this is really a sufficient replacement for DNS over TCP support
>> b) why truncated responses are immediately discarded, even if they contain
>>    one or more records that satisfy the original request
>>
>> But such discussion could optionally be moved to a seperate thread.
> 
> Thanks for this, it indeed sounds useful and could be even more useful
> once we manage to setup a backend using DNS responses. I'm having one
> question though : what would be the impact of enabling this all the time,
> I mean without the configuration directive ?

Yeah, I was pondering the same thing. DNS servers not capable of that
extensions (very few, I think) would ignore it, so always adding the OPT
record would be safe indeed. I just wasn't sure about the value itself. I
guess always setting it rather high would be an option. I didn't quite
finish thinking about whether there are scenarios where the server actually
sending such a big packet it might not make it through your network (e.g.
if the server would set the IP don't fragment bit). In our setup, IP
fragmentation kicks in and it works nicely.

Maybe you have more thoughts on that? I'd be happy with either solution.

Conrad


> 
> willy
> 

-- 
Conrad Hoffmann
Traffic Engineer

SoundCloud Ltd. | Rheinsberger Str. 76/77, 10115 Berlin, Germany

Managing Director: Alexander Ljung | Incorporated in England & Wales
with Company No. 6343600 | Local Branch Office | AG Charlottenburg |
HRB 110657B

Reply via email to