Mark Andrews wrote:
>> Maybe I've been working too much this week, but I can't seem to
>> figure out how to do what I want with a sortlist option, not
>> even after STFW and testing for a couple of hours. In case
>> it's an obvious mistake, I'll give the attempt first:
>>
>> sortlist {
>> {10.98.192/18;};
>> {!10.98.192/18;};
>> };
>>
>> The effect that I'm after is that clients inside the 10.98.192/18
>> netblock receive A records from that netblock first, and that
>> clients outside that netblock receive A records *outside* of
>> 10.98.192/18 first.
>>
>> It works for the first case, but not for the second. In other
>> words, clients outside of 10.98.192/18 are receiving just
>> the standard cyclical behavior. The relevant RRSet is:
>>
>> stealth.example.com. 3600 IN A 10.98.16.142
>> stealth.example.com. 3600 IN A 10.98.200.4
>> stealth.example.com. 3600 IN A 10.98.200.5
>> stealth.example.com. 3600 IN A 10.98.200.6
>> stealth.example.com. 3600 IN A 10.98.16.141
>>
>> What am I missing?

>
> sortlist {
> {10.98.192/18;};
> {{!10.98.192/18; any;}};
> };
>
> This should do what you want, however it is untested.


I was curious so I fiddled with this a bit. At least on 9.5.0-P1 named
seems to completely ignore the !. The only way I could get what the OP
wanted was to specify the subnet for the folks outside the first
block, like this:
sortlist {
{ 10.98.192/18; };
{ any; 10.98.16/24; };
};

hth,

Doug