This is probably a really simple question but it's causing us problems.

We have a small company intranet with office staff and students who attend our school. We wish to give the students access to one website on the shared office server. The students connect to the internet and network using a seperate set of IP addresses (through the router) than the main office.

I added a new website to IIS, added an IP address, assigned the IP address to the website etc and everythign works fine - except that it mucks up the resolving. The two websites are called

Server (very origional - the name of the main office server)
StudentNet(again very origional - the name of the new website pointing to the new website)

We had a problem when we set it up that sometimes when an office pc tried to go to Server either in a browser (for interal sites) or as part of a connection string to a sql database etc it wouldnt find it. To fix this issue we added a line in the hosts file on all the office PC's, which works but I HATE this solution. Its old and clunky. When someone comes and connects into the network you need to add this to their host file or get them to use th e ip addres. When we buy new machines this needs to be done.

I cant believe there isnt a better solution involving either the Windows Server or one of the routers we have as gateway to the net.

Any suggestions?

4 Answers 4


I assume the server(s) and PCs are in a Windows domain. You could add a host name to your domain server's DNS settings (Administrative Tools -> DNS). Try nslookup on the clients to see if the names are correctly resolved.

Note: you don't need different IP addresses for the webs on the server, because IIS "understands" the concept of http host headers. You can set host headers for a website on the same IP address:

IIS Manager -> Website -> IP Address -> button "Advanced..."

It's possible to just add two websites to IIS and use different Host Headers as splattne said. This is the easiest way to do it. Then just add the "site name" as an cname record in DNS and point it to your A name.

IIS tree:
Web Sites
-> Server (host header of 'server.mydomain.tld')
-> StudentNet (host header of 'studentnet.mydomain.tld')

DNS Tree A Host
Host '@' Points To '111.222.333.444'
Host 'server' Points To '@'
Host 'studentnet' Points To '@'

Edit: Not sure what happened to my formatting. It looks so nice in edit mode.

  • He he, nice IP address: 111.222.333.444 ;-)
    – splattne
    Commented Jul 31, 2009 at 14:30

manually add the dns records in DNS server so for example, new host(A) record server pointing to the corresponding IP adress and the same thing for StudentNet. then on a client do a ipconfig /flushdns and ipconfig /registerdns to immediately have the new dns database. then try it out...

  • I use the build in DNS server on windows to do this yes?
    – Toby Allen
    Commented Jul 6, 2009 at 11:29

Yes, use Windows DNS Server, since it's inside your network

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .