How to create a SubDomain

T

Tina

Our company domain, say, wombat.com needs to create several subdomains:
support, training, and purchase are three of the subdomains needed. So when
someone browses to //training.wombat.com they will be directed to the IP we
have assigned. I have two questions:

1. how can I do this at design time?

2. how can I do this at run time from my asp.net code?

Thanks,
T
 
D

darrel

Our company domain, say, wombat.com needs to create several subdomains:
support, training, and purchase are three of the subdomains needed. So
when someone browses to //training.wombat.com they will be directed to the
IP we have assigned.

All they do is purchase wombat. traning.wombat is something they set up
themselves on their DNS server.
1. how can I do this at design time?
2. how can I do this at run time from my asp.net code?

It's a network/DNS/IIS setting...not an application setting.

-Darrel
 
T

Tina

bruce,
Yes I know they are dns entries. Now, can you answer the two questions?
Thanks so much,
T
"bruce barker (sqlwork.com)"
 
J

Juan T. Llibre

re:
!> Yes I know they are dns entries. Now, can you answer the two questions?
!> 1. how can I do this at design time?
!> 2. how can I do this at run time from my asp.net code?

You can't do it at design time and you can't do it from code.

I suggest you read up on what dns servers actually do.

http://en.wikipedia.org/wiki/Domain_name_system
 
T

Tina

Juan,
I just got done reading the entire help file for the DNS server product. It
was nearly a complete education and I now understand levels of domain mames,
subdomains, zones, reverse lookups, etc. It told me nearly everything....

...except how to create a subdomain

I then spent time googling every word combination I could think of such as
"create a subdomain." to no avail. I found a lot of other people asking but
no answers.

It looks like no one else knows either judging by the quality of answers
I've received thus far on this thread.
T
 
G

Guest

at design or runtime its the same, you give the dns server the ipaddress and
domain name. it must a trusted dns server to update the internet. generally
you need to be admin on the dns server to update it.

how will depend on which dns server you are using as the trusted one (by
the internet). if its a windows box, use dns manager. if you are using a
unix based dns server, then you want to use bind.

if you servers have ldap support you can use a ldap library to talk to the
dns server.

-- bruce (sqlwork.com)
 
B

Bolwerk

(Assuming this isn't a troll question....)

Simply give each DNS record an A record. Alternatively, CNAMES could
point to aliases of already configured subdomains. You realize in
www.whatever.com., www is a subdomain, right?

Controlling DNS records from the application level would be quite
difficult, and I don't see the benefit.

Here's a solution that might work (I don't know how to do it off the top
of my head with IIS, but it can't be difficult): use name-based virtual
hosts. Use a wildcard to resolve all subdomains to a certain host
(GoDaddy supports this feature), then the application could maybe be
programmed to respond differently depending on which subdomain a user's
browser sends in the headers; the browser should pass the subdomain it's
seeking as an environmental variable, and your application can respond
accordingly. When the application checks the environmental variable, it
can deliver a different page based on what host header is supplied by
the browser.

The disadvantage is you couldn't use SSL with name-based vhosts; you
also won't be able to server HTTP 1.0 clients very well (but then,
almost nobody is limited to HTTP 1.0 anymore; most browsers support 1.1,
and many hosting companies use name-based vhosts).

But the advantage is you save IPs and have more flexibility in what
sites to host.

http://httpd.apache.org/docs/2.2/vhosts/ - that's Apache's vhost
configuration info. It won't help with IIS, but it goes into a bit more
detail weighing the advantages and disadvantages than I just did. I
know IIS supports name-based vhosts too. I just don't remember how to do it.
 
T

Tina

thanks, uh, what's a troll question?
T

Bolwerk said:
(Assuming this isn't a troll question....)

Simply give each DNS record an A record. Alternatively, CNAMES could
point to aliases of already configured subdomains. You realize in
www.whatever.com., www is a subdomain, right?

Controlling DNS records from the application level would be quite
difficult, and I don't see the benefit.

Here's a solution that might work (I don't know how to do it off the top
of my head with IIS, but it can't be difficult): use name-based virtual
hosts. Use a wildcard to resolve all subdomains to a certain host
(GoDaddy supports this feature), then the application could maybe be
programmed to respond differently depending on which subdomain a user's
browser sends in the headers; the browser should pass the subdomain it's
seeking as an environmental variable, and your application can respond
accordingly. When the application checks the environmental variable, it
can deliver a different page based on what host header is supplied by the
browser.

The disadvantage is you couldn't use SSL with name-based vhosts; you also
won't be able to server HTTP 1.0 clients very well (but then, almost
nobody is limited to HTTP 1.0 anymore; most browsers support 1.1, and many
hosting companies use name-based vhosts).

But the advantage is you save IPs and have more flexibility in what sites
to host.

http://httpd.apache.org/docs/2.2/vhosts/ - that's Apache's vhost
configuration info. It won't help with IIS, but it goes into a bit more
detail weighing the advantages and disadvantages than I just did. I know
IIS supports name-based vhosts too. I just don't remember how to do it.
 
B

Bolwerk

Tina said:
thanks, uh, what's a troll question?
T

Sorry, I found it odd that you said you knew all about DNS, but didn't
know how to make a subdomain. :p

I have to warn you, the solution I suggested is pretty inflexible, but I
guess works. I think you'd be better off just using subdirectories.

Good luck
 
D

darrel

Yes. I know. Now can you answer the two questions?

You'd think that someone that 'knows' that would ask this question in a DNS
forum rather than an ASP.net one.

-Darrel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top