Getting DNS Set Up on a Self-Contained MOSS Server


Since I don’t do it very often, I can never remember everything I need to do to get DNS set up correctly when I create a new MOSS VM for testing or development. It’s easier to set the entire thing up to run on a single server to keep it insulated from everything else I might be working on, and it doesn’t suck up as many resources on my VM host as a multi-server farm might (i.e. DC/DNS, Web Server, SQL Server.)

So here are some notes for next time:

  1. Install at least two NICs (physical or virtual adapters) on the box. One can be for external access (i.e. so you can get to the Internet), and the other for local routing (on-box, in this case) only.
    1. Set the External NIC up so that it retrieves an IP address from your network DHCP server. For a home network, this would probably be the gateway router that acts as a DHCP server. Generally, you can just select, “Obtain an IP address automatically” and “Obtain DNS server address automatically”, as shown below.


    2. Set the Internal NIC up with a static IP address. Then specify the DNS server address as either (the loopback address) or as the static IP address you’re giving to this NIC.


  2. DNS – must be installed on the server (as well as Active Directory).
    1. Forward Lookup Zone: this server will provide name resolution for computers listed in this zone.
      1. Zone can be authoritative: means that this server is the primary place to get name resolution for the machines listed.
        For this (assuming the zone doesn’t exist already), create a new zone with the name of the domain for which this box will be authoritative. E.g. “”.
      2. Or, the zone can be non-authoritative: by creating a “stub zone”, this server will get its lists of servers from another DNS resource.
      3. Name-to-IP or IP-to-Name: both types of resolution can be handled with a single entry.
        1. First, right-click your new zone listing under “Forward Lookup Zones” and select “New Host (A)”.


        2. This displays the “New Host” dialogue window.


        3. The Host Name—the name of your site (e.g. “moss” for “http://moss/” or “”) goes in the first box. You don’t need to add the “” part; that will get added automatically and entering it here will cause it to double-up (e.g. “”.)
        4. The IP address goes in the second box. This can be, but it’s better if you have an address that isn’t the loopback address, as that can cause other issues. Use the address you assigned to the Internal NIC.
        5. Checking the first checkbox (“Create associated pointer record”) causes a record to be created that allows reverse-lookup as well. So, typing “http://192.168.x.x”—or whatever the actual IP address of the box is—will cause the site to still be found as “”.
      4. Once you get this far, you should be able to ping the hostname and get a response from the IP address you chose. You should also be able to ping the IP address and get a response.
    2. Reverse Lookup Zone: don’t bother with this for now.
  3. IIS Settings: you may need to create a host-header entry for your web application using the properties window in IIS.
    1. Find the node in the tree for your web application, right-click on it, and select “Properties”.


    2. In the Properties dialogue window, select the “Advanced…” button on the “Web Site” tab.


    3. Click the “Add” button…


    4. And add an entry by specifying:
      1. The IP address (or leaving as “All Unassigned”);
      2. The port (“80” is the default for HTTP traffic; “443” is the default for SSL traffic);
      3. And the Host Header value. For the Host Header, enter the name you want to use when going to the website. In the existing entry above, I’ll be able to type “” to get to my SharePoint site.


      4. Multiple Host Header values can be added for a single web application. In addition, each Host Header can be bound to its own static IP address. In order to do this, however, you’ll need to add additional IP addresses to one of the box’s NICs. That can be done using the following dialogue window:


        This can be opened by clicking the “Advanced” button on the Internet Protocol (TCP/IP) Properties dialogue window.

        1. Right-click on the Internal NIC';
        2. Select “Internet Protocol (TCP/IP)”;
        3. Click the “Properties” button to view Internet Protocol (TCP/IP) Properties;
        4. Click the “Advanced” button.
        5. Select the “DNS” tab.
  4. hosts file: If all else fails, or you’re still having some odd routing issues, or for some reason one of the host names you’re trying to use won’t resolve to the right IP address, you can try adding a host-name-to-IP-address matching directly in the host file (c:\windows\system32\drivers\etc\hosts; the file has no extension.) It’s a simple text file; open it in a text editor like Notepad.exe and add a line like this:

    (Note: that’s a tab between the IP address and the host name.)

Ok, hope that helps next time you’re trying to get a new machine set up—physical, virtual, or otherwise.

Skip to main content