• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1252
  • Last Modified:

Mapping Subdomain to ANOTHER Server using IIS

Well I know how simple this would be in Apache.....all I'd have to do is update the DNS A records and it would be done.  However, the company I'm working with uses a Windows/IIS platform.  So here is the situation:

The company I'm working with for a web project owns the domains and currently has their own Windows/IIS server.  I will be providing content for their website using my own PHP code on my own server that only I will have access to.  Therefore I need to redirect traffic from their site to my own web server (currently has it's own static IP).  Here's the kicker - I only need to redirect certain subdomains.....not the main domain.

Example:
http://au.COMPANYSITE.com needs redirected to http://IPADDRESS#1
http://ca.COMPANYSITE.com needs redirected to http://IPADDRESS#2
http://in.COMPANYSITE.com needs redirected to http://IPADDRESS#3

Before jumping to conlusions, I want it so users do not know the re-mapping is taking place.  Therefore, when a user visits http://au.COMPANYSITE.com/folder/aboutus.php the request is actually mapped to http://IPADDRESS#1/folder/aboutus.php ..... but the user's address bar still shows http://au.COMPANYSITE.com/folder/aboutus.php.  Therefore they are oblivious to the transparent mapping.

Now on apache I have found this simple, simple, simple to do.  But I'm pulling my hair out trying to figure out how to do it with Windows/IIS.  Right now I have been given remote desktop access to their Windows 2000 server.  I've looked at everything from individual subdomain properties to the DNS administration program.  The "test changes" I've made have not been successful.  For instance, I tried simply updating the subdomain using the "Home Directory" tab in the properties dialog box.  I changed the option from "A directory located on this computer" to "A redirection to a URL".  Now this did redirect.....but now the user/visitor's address bar showed the IPADDRESS#1.  

Does anyone have some advise for a non Windows/IIS person to make this work correctly?  I appeciate your assistance.  Thanks, everyone!





0
ellisgolf
Asked:
ellisgolf
  • 2
2 Solutions
 
humeniukCommented:
It's still simple to do.  You just use your same DNS solution you suggested off the top, ie. point the A record for each subdomain to the IP address of the server that will contain that website.  It doesn't matter if the destination server is Apache or IIS as long as it is configured to serve that website.
0
 
ellisgolfAuthor Commented:
I don't know how to update the A record.  Through the DNS Program in IIS, it does not appear that anything is even being used anyway.  It baffles me.  There are about 40 subdomains setup on the server that work correctly, and also several other domain names.  But none of the records are available in the DNS program from what I can find.
0
 
humeniukCommented:
The IIS server isn't necessarily acting as the DNS server for that domain.  They could be using their registrar or a third party DNS service.  Ask them what they are using for DNS.  That's where you will have to change the settings.  Once you have found that it is as simple as using a host (A) record to point a subdomain to the proper IP address (assuming the web server at that IP address - apache, IIS, whatever - is configured to serve that website: sub.domain.com).

If it turns out they are using local Windows DNS, check back here and I can give you help configuring it.
0
 
lokipCommented:
I obviously can't test this on your machine, but I had a similiar problem a few years ago with 2k. I had to delete the subdomain and just add an A record *without* IIS knowing their was a subdomain even there. When IIS thought there was a subdomain, it had a nasty habit of taking over the DNS entries for it.

Eric
0

Featured Post

The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now