Second Level Subdomain DNS Wildcard

10,775

Solution 1

yes you can do this, you basically need a record (bind format)

*.design.mydomain.com. 3600 IN A x.x.x.x

or in djbdns format:

+\052.design.mydomain.com:x.x.x.x:3600

Solution 2

You did not indicate the name server you use. With BIND or NSD, which both use the RFC 1035 format for zone files, this should work:

*.design    IN   A   192.0.2.3
Share:
10,775

Related videos on Youtube

easyappl
Author by

easyappl

Updated on September 17, 2022

Comments

  • easyappl
    easyappl almost 2 years

    I need help setting up a second level subdomain. I have set up wildcard subdomains in the past with success, but I am having trouble with the DNS entry for this one. I need to do something like

    *.design.mydomain.com

    So I tried to create an A record with *.design in it but that failed. Is this possible?

    • easyappl
      easyappl about 15 years
      Sorry. What I meant by "failed" is I would do a dnsstuff report on the design.mydomain.com and that would come back fine, then I ran a report on user.design.mydomain.com and that did not come back with any results.
    • bortzmeyer
      bortzmeyer about 15 years
      DNSstuff is a poor way to test a domain. The best tool is dig and, if you want a report from another site, use zonecheck.fr "It did not come back with any results" is clearly not enough information to help you.
  • bortzmeyer
    bortzmeyer about 15 years
    You forgot the dot at the end of *.design.mydomain.com
  • bortzmeyer
    bortzmeyer about 15 years
    The $ORIGIN is not necessary, you can just use relative or absolute names.
  • Alnitak
    Alnitak about 15 years
    and the TTL is in the wrong place too...
  • alphaGeek
    alphaGeek about 15 years
    I have been doing all our subdomains and MX records this way because of an issue we had when setting up Google Apps. Google would not validate our account unless I stuck them between ORIGIN calls. I have no explanation for it. I understand BIND administration enough to get it done without a lot of trouble, but I wouldn't consider myself an expert.
  • Brendan
    Brendan almost 15 years
    appreciated, should have checked the format of bind (been a while), updated my original post