Hosts File

From MediaSmartServerWiki
Revision as of 16:32, 11 December 2008 by Cougar (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Frequently, someone has an issue where the client can't connect to the server, or the WHS Connector won't find the server. This is often due to name resolution not being handled correctly, and is easily overcome by making a manual entry to point to your server. If you add a hosts entry, you will need to ensure you either have a static IP address assigned to the server, either by a DHCP reservation from your DHCP Server or Router or by making the change directly on the server.


Windows XP

The Hosts file is stored in C:\Windows\System32\Drivers\etc and is a plain text file and as such is easily edited in NOTEPAD.

In the HOSTS file example below, a Windows Home Server entry for HPSERVER using IP address 192.168.0.100 has been added as an example, the IP Address is added followed by the name, and the file can then be saved.

This method can also be used if your router will not connect internally to your external name, i.e. http://cougar.homeserver.com. Simply add another line with the servers IP address and the Fully Qualified Domain Name of your server, i.e cougar.homeserver.com


# Copyright (c) 1993-1999 Microsoft Corp. #
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host

127.0.0.1 localhost
192.168.0.100 HPSERVER
192.168.0.100 cougar.homeserver.com


Windows Vista

As above, the Hosts file is stored in C:\Windows\System32\Drivers\etc and is a plain text file and as such is easily edited in NOTEPAD.

In the HOSTS file example below, a Windows Home Server entry for HPSERVER using IP address 192.168.0.100 has been added as an example, the IP Address is added followed by the name, and the file can then be saved.

This method can also be used if your router will not connect internally to your external name, i.e. http://cougar.homeserver.com. Simply add another line with the servers IP address and the Fully Qualified Domain Name of your server, i.e cougar.homeserver.com

# Copyright (c) 1993-2006 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host

127.0.0.1 localhost
::1 localhost
192.168.0.100 HPSERVER
192.168.0.100 cougar.homeserver.com

References