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

At work we have an internal server which we use to host things like a wiki and other internal applications - we also use it to demo applications we're currently building within an environment other than our own machines.

Historically employees have had to use http://ServerName:Port to navigate applications on this server and this is precisely what I'd like to overcome; what I want to enable my colleagues to do is use a friendly, familiar and also somewhat descriptive URL. How might one achieve this?

I followed an article which walked through the process of setting up DNS on a server but to no avail.

Is there a clean-cut, efficient way to do this as I'm just wasting time right now?

  • I set up DNS

  • Added Forward Lookup Zone (with defaults so it auto-added (SOA), (NS) and two HOSTS (A) records

  • Added a CNAME record which uses the parent domain

I can hit http://ServerName which directs me to the default website (which is some Sharepoint thing, I think, stored in the c:\inetpub\wwwroot folder), however on setting up a new website in IIS and adding the header values I want (say, wiki.servername(.co.uk)), I simply can't land on this page as it tried to enter the wild.

Any thoughts on how I might achieve this or what I might be doing wrong?

share|improve this question

2 Answers 2

up vote 2 down vote accepted

You're overcomplicating it, if the goal is to drop the port number and use an alternative short name. Use a single-label name, not a semi-dotted sub-server sub-domain sub-name like "wiki.server"!

Keep in mind that the browser has its own ideas about what's internal and external - rule of thumb, if you throw an address with dots at IE, it'll hit the proxy and try to go externally.

Use your existing internal DNS namespace - the same one that clients use at the moment. If http://servername resolves, use whatever domain that runs from.

Create A-records there for the new server names (to work around potential kerberos issues with IE and CNAME resolution later), and then set the host header for one of those servername:port websites to match the short server name. You don't need to remove the old port binding, you're just adding a new binding for port 80, host header "aliasname".

Aside: Host headers are resolved based on the value the browser client sends to the server in the "Host:" header - which will reflect whatever you typed (i.e. if you typed http://aliasname, it'll be Host: aliasname, not the FQDN of the server). So as long as clients type something that matches that host header string, they'll be routed to the right website.

With this configured, it should basically work, because

  • you're using short names in the browser, which the browser doesn't intuitively want to send to the proxy (or consider part of the Internet zone)
  • you're using the same name in the address bar as you're using for the host header value
share|improve this answer
    
Amazing - thanks! Although, one of the biggest issues was a lack of knowledge of circumstances (I was trying to set DNS up on a server which was ultimately part of our network that already had a DNS server). The solution was to implement what you suggest on the correct server. –  Grant Thomas Mar 23 '11 at 14:49
    
Glad it worked for you! –  TristanK Mar 23 '11 at 20:19

You should have set up a domain name within your DNS, for example companyname.co.uk. wiki.servername.co.uk would skip your inside servers and search the co.uk TLD for a servername domain, which obviously doesn't exist.

If you're just wanting internal clients to access it, you can set up a fake domain name internally like company.lan. Then, add it as a search domain for your internal clients in their TCP/IP settings.

Further, on IIS, you need to set up a new website (besides default) to host the subdomain. Name the website wiki.servername.company.lan, or whatever else you desire.

Alternative to all of the above, you can just use unique names for the website without resorting to subdomains. For example, since http://servername already works, you could set up a new website in IIS that will respond to http://anothername. As long as anothername is in your internal DNS pointing to the same IP.

EDIT: I wanted to give an example of what I mean. In my network, we have a domain name of company.org. For internal monitoring, we have set up two websites called itadmin and itwiki on a server called intapps. To access one of these websites, users type either http://itadmin.company.org or just http://itadmin. The internal DNS server points itadmin and itwiki to the same IP, which is the IP for intapps. The A records are recorded under the company.org zone in DNS.

share|improve this answer
    
Thanks for the info - so do I need to add an A record for each site I want to set up with a unique name? –  Grant Thomas Mar 18 '11 at 12:45
    
Yes, you would. It's much easier if you don't mess with subdomains, since you'd only have to create a new A record in the main zone. Subdomains require you to set up a domain for "servername" in DNS. For example, wiki.servername.company.co.uk would need to be set up under the company.co.uk zone, with an A record for wiki in a subdomain called servername. To create a subdomain in Windows DNS, just right click the zone and select "New Domain". The final structure of your DNS zone will be "companyname.co.uk" Zone -> "Servername" Domain -> Wiki A Record. –  Hyppy Mar 18 '11 at 12:51
    
Note that the DNS server in this case is the same machine as will be hosting these internal apps - is this sane? –  Grant Thomas Mar 18 '11 at 12:54
    
That's not too big of a deal if you're short on servers. –  Hyppy Mar 18 '11 at 12:56
    
Hm, still can't get this to resolve. Do you possibly know of some resources to aid me in this exercise? I'm no server admin and to be quite honest don't have the time to learn the ins and outs of this whole scenario. Thanks. –  Grant Thomas Mar 18 '11 at 13:42

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.