[Pdns-users] Wildcard record based on type
Fernando Morgenstern
fernandomorgenstern.fm at gmail.com
Tue May 14 20:11:44 UTC 2013
Hi John,
I have a service that creates one subdomain for each account. Example:
account1.domain.com
account2.domain.com
I have to create an A record for each subdomain. This is easy since i'm
using the mysql backend.
The issue is that sometimes Powerdns won't "see" the new subdomains. I'm
not able to reproduce this issue easily, but even with the subdomain
created, it takes a while for Powerdns to serve that record properly. In
other words, i see it in the database, but a simple dig directly to
Powerdns won't return it.
A solution that I found was to use a wildcard record. It works perfectly
since all subdomains point to the same IP.
Now i also have to create TXT records ( which varies between accounts ) for
each subdomain so the wildcard for A records stopped working and i'm not
sure about how to deal or fix this.
On Tue, May 14, 2013 at 4:49 PM, John Miller <johnmill at brandeis.edu> wrote:
> Hi Fernando,
>
> This is how wildcard DNS is supposed to behave. Only if there's no label
> for your query will the wildcard entry be read.
>
> In your case, yes, if there's a TXT record
>
> test.example.org. TXT adsfasdfasdfasdfasdfasdfasdfas**dfasdf
>
> then a query of
>
> test.example.org. A?
>
> will not fall through to the wildcard, because there's a record with label
> "test".
>
> See section 2.2.1 in RFC 4592 (http://tools.ietf.org/html/**rfc4592<http://tools.ietf.org/html/rfc4592>)
> for a fairly good example of this.
>
> You could of course write your own code to look for a wildcard entry (by
> querying something outlandish like qwerqwerqwerwqerwqerqwer.**example.org<http://qwerqwerqwerwqerwqerqwer.example.org>and checking the response).
>
> Can you explain why you'd want to do this, however? In what cases would
> you have a TXT record for a label, but want to use a wildcard A record?
>
> John
>
>
>
>
> On 05/14/2013 02:59 PM, Fernando Morgenstern wrote:
>
>> Hi,
>>
>> I have a wildcard of type A for a certain domain ( Eg.: *.example.org
>> <http://example.org> ).
>>
>>
>> I noticed that it only works if no records are found for a subdomain,
>> including other types like TXT, SPF etc.
>>
>> Example: if there is a test.example.org <http://test.example.org> record
>>
>> of type TXT but no record for the subdomain of type A, wildcard won't
>> work.
>>
>> Is it possible to avoid this and force powerdns to always use the
>> wildcard?
>>
>> Thanks.
>>
>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.powerdns.com/pipermail/pdns-users/attachments/20130514/80017fd3/attachment-0001.html>
More information about the Pdns-users
mailing list