Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I think the title says it all really, but to reiterate, I'd like to know how to configure Windows 2003 to allow a wildcard on a subdomain. So site1.sub.domain.tld and site2.sub.domain.tld should both go to the same IIS site, whose host header value is sub.domain.tld.

I've tried the following without success - sub.domain.tld works, but not site1.sub.domain.tld.

sub     A   my.ip.goes.here
*.sub   A   my.ip.goes.here

Thanks, Iain

share|improve this question

migrated from stackoverflow.com Sep 16 '10 at 10:16

This question came from our site for professional and enthusiast programmers.

3 Answers 3

In Windows 2003 DNS, your subdomain should show up as a "folder" inside the parent domain (to create: right-click the parent domain, choose "New domain...", and enter the subdomain name). For the wildcard, you make a new host ('A') record with '*' as the name.

In this case, it sounds like you want something like this:

  1. In domain.tld, create a new domain "sub".
  2. In sub.domain.tld, create a new 'A' record with no name, and give it the IP address of your server. (This will respond to sub.domain.tld).
  3. In sub.domain.tld, create a new 'A' record with '*' as the name, and give it the IP address.

Just to be confusing, Windows will allow you to create a 'A' record called "sub" in the parent domain. But for the wildcarding Windows will need to have the subdomain.

share|improve this answer

It's been a while I configured my wildcard DNS, but if I remember correctly, the record has to be:

*.sub.domain.tld IN A 11.22.33.44
share|improve this answer
    
Hi thanks for your answer - it doesn't work at least for me however. –  Iain Jul 25 '09 at 9:27

Explanation of DNS Wildcards

From looking at the examples, a couple suggestions:

The DNS names must eventually become an a real FQDN, and by that, I mean explicitly dot terminated.

You should try:

*.sub.domain.tld. IN A 11.22.33.44

(Note the dot after "tld". I'm sure you will tell me that without the dot, the subdomain should be used to append a suffix before becoming an FQDN, but it might work better if you are explicit, as shown in the example.

Also, does this file have a serial number. Could it be that you made an edit and did not increment the serial number?

share|improve this answer

Your Answer

 
discard

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