I had a DNS record (ex: test.example.com) pointing to a single IP:
test.example.com IN A 192.0.2.1
Working fine. Now I have +30 IPs answering for it, example:
teste.example.com IN A 192.0.2.1
teste.example.com IN A 192.0.2.2
(...)
teste.example.com IN A 192.0.2.31
And now it's unstable ("can't find host" errors). Using dig
I got a warning "Truncated, retrying in TCP mode". After some Google searches, I found out that a multi-IP query must have no more than 512 bytes to guarantee that UDP will be used, and avoid an extra query (or problems with no-tcp dns clients or providers, old dns sw, etc).
So, how can I know how many v4 IPs can I have in a single dns entry to guarantee a maximum of 512 bytes UDP answer?
or
Is it possible to configure ISC Bind to return only one IP in a multi-IP query? I know that the IP can be cycled with rrset-order { order cyclic; };
.
Like:
> test.example.com
Server: x.x.x.x
Address: x.x.x.x:53
Name: test.example.com
Address: 192.0.2.6
so, only one of them? Thanks.