Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

It is well known that it is possible to configure a DNS server to do a "catch-all" resolving on a single subdomain level, such as * IN A x.x.x.x, so that maps to a single IP/CNAME.

However, I need to set up an at least "level-2" wildcard sub-subdomain catch-all wildcard system so that or better, will be resolved to a single IP.

Has anyone got this working?

share|improve this question
I can just say it definitely is possible. You'll have to wait for someone competent to tell you how, though. –  o0'. Jun 12 '11 at 14:40
Yes, I belive it is. But I need an advice how to achieve this on common server software (BIND, Microsoft DNS server, etc.). –  Jan Rovner Jun 12 '11 at 15:29
You should add the DNS software that you are using –  MichelZ May 22 '14 at 10:57

3 Answers 3

On any real DNS server a wildcard record will match one or more labels.

See section 4.3.3 of RFC 1034.

share|improve this answer

Works in bind with just a record for *, it will grab anything under that domain. I.e.

This is a sample configuration file.

BIND 9.2.4 and the zone file content is 
*          CNAME
share|improve this answer
Thank you for the reply, could you please give me a BIND version number and possibly and the contents of a zone file? –  Jan Rovner Jun 13 '11 at 12:36

We use multi level subdomains on our CDNs. In our DNS control panel (Zerigo) we just used * mapping to a CName of our CDN. Then we can use

I haven't had a chance to test this on BIND etc. but I'm fairly certain it will work the same in there, Zerigo responsds with


share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.