Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm experimenting with the Windows 7 search domain option, so I can fake wildcard *.dev URL's.

I registered (for now) with a free dns service (www.cloudns.org) and added a wildcard A record pointing to the IP address of my webserver (Ubuntu virtual machine).

Testing;

  • http:// test.franssen.cloudns.org (200 OK)
  • http:// test.test2.test3.franssen.cloudns.org (200 OK)

Ok, working as expected; next I added "franssen.cloudns.org" as search domain in windows 7 (and for consistency also in ubuntu).

Testing;

  • ping test.franssen.cloudns.org
  • ping test.test2.test3.franssen.cloudns.org
  • ping test
  • ping test.test2.test3

The first 3 pings resolve to the IP of the virtual machine, the last one stays unresolved... what the?!

See als a screenshot which says more than a 1000 words (it's a dutch machine, but should make my point clear)

enter image description here

enter image description here

share|improve this question
add comment

1 Answer

up vote 0 down vote accepted

Since you have all these DNS entries published, I added your domain suffix with the exact same results. I have the feeling you will not be able to fix that in the manner you were trying since it is probably looking at the last test3 not as a host, but as an incomplete domain.

I would do this: Go to C:\Windows\System32\drivers\etc\hosts, unmark the file as read-only, and add this entry and save:

192.168.56.128 test.test2.test3

This worked for me. If it works for you, please come back and mark this as answered.

share|improve this answer
    
P.S. In a command box, do an ipconfig /flushdns before you test. You should not need it, but just in case. –  KCotreau Jun 18 '11 at 12:07
    
I'm currently doing that, but the idea was to use this trick to create wildcard *.dev URL's in windows (dynamic ftw) –  Roland Franssen Jun 18 '11 at 16:36
    
@Roland Franssen Somehow, I don't think you will get by that behavior. –  KCotreau Jun 18 '11 at 16:57
    
A colleague of mine is saying that it should work, in fact it is working on his OS X. See also tools.ietf.org/html/rfc3397 (section 4.2) "Resolve a name that contains any dots by first trying it as an FQDN and if that fails, with the local domain name (or searchlist if specified) appended." Nothing about "test.test2.test3" is assumed to be a FQDN and therefor the searchlist should be ignored.. –  Roland Franssen Jun 20 '11 at 17:00
    
@Roland Franssen What should work, what OS X does, and what Microsoft does are all different things. Microsoft has a history of doing things their own way. For example, only with IE8 did they start following the RFC's for that. I was able to reproduce your results exactly, and tried to get around it, with no luck other than to add the entry to the hosts file. My experience tells me that it is hard-coded to work that way, whether it follows the RFC or not. –  KCotreau Jun 20 '11 at 17:10
show 3 more comments

Your Answer

 
discard

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.