Inside Windows 98

Previous chapterNext chapterContents


- 22 -

Configuring Internet Connections


Although the Internet has existed for many years, only in this decade has it become widely popular outside academic, government, and military circles. The Internet's explosive growth has stimulated a strong demand for support of TCP/IP and Internet-related utilities and programs. Windows 98 offers a set of core components and general utilities that make it an excellent platform for TCP/IP internetworking.

This chapter helps you understand, configure, and use TCP/IP to provide connectivity between computers on your LAN as well as a connection to the Internet. The chapter covers the following topics:

This chapter helps you configure and use TCP/IP and begin connecting to the Internet. To learn about the TCP/IP and Internet utilities included with Windows 98, refer to Chapter 28, "Integrating Windows 98 and Novell NetWare."


NOTE: This chapter provides a general overview of TCP/IP to help you understand how to configure and use TCP/IP. If you require a more technical description of how TCP/IP works, consult the Microsoft Windows NT Resource Kit, Microsoft Windows 98 Resource Kit, one of the many resources and FAQs (Frequently Asked Question documents) available on the Internet, or Inside TCP/IP by New Riders Publishing.

For information on how to connect to the Internet using PPP and SLIP protocols through the Dial-Up Networking service in Windows 98, refer to Chapter 21, "Using Dial-Up Networking and Direct Cable Connection."

An Overview of TCP/IP and the Internet

The two primary topics in this chapter--TCP/IP and the Internet--generally are closely related; you need the TCP/IP protocol to connect to and use the Internet. But even if you don't need to access the Internet, TCP/IP still offers an excellent means of interconnecting disparate operating systems on a single network. This section of the chapter provides a brief overview of TCP/IP and the Internet.

TCP/IP

TCP/IP stands for Transmission Control Protocol/Internet Protocol. TCP/IP, which actually comprises two protocols--TCP and IP--serves as a network transport protocol widely supported by a majority of operating systems, including all versions of UNIX, Windows NT, Windows 98, Novell NetWare, Macintosh, Open VMS, and others. Originally, TCP/IP was developed through the Defense Advanced Research Projects Agency to support defense-related projects. TCP/IP offers a number of advantages that make it an excellent network transport protocol, particularly for connecting dissimilar computers and for enabling wide-area networking.

The TCP/IP protocol included with Windows 98, dubbed Microsoft TCP/IP, operates as a 32-bit, protected-mode transport that you can use as your only network protocol or in conjunction with another protocol. You might use NetBEUI within your LAN, for example, and use TCP/IP to connect to the Internet through a router or dial-up connection. The following list describes some of Microsoft TCP/IP's features and advantages.

Although setting up TCP/IP is not difficult per se, it can prove to be a complex task.

The Internet

The Internet began as a small group of interconnected LANs and has grown into a world-wide network that spans many thousands of networks and millions of computers. Although the Internet began primarily as a defense- and education-related network, it has grown to encompass government and commercial networks and users, as well as individual users. The Internet really is nothing more than a huge wide area network. On this network, however, you can access an amazing variety of services and data. You can send and receive email around the globe, transfer files, query enormous databases, participate in special-interest groups, and much more.

There are many ways to access the Internet. If you have a user account on one of the popular online services, such as CompuServe or America Online, or are a member of the Microsoft Network (MSN), you can gain access to the Internet through those services. Or, your network at work might be connected to the Internet through a dedicated or dial-up connection. You might connect from your computer to an Internet service provider through a dial-up connection. Regardless of the method you use to connect to the Internet, you can't do it without TCP/IP. Understanding TCP/IP is critical to configuring and initiating your Internet connection. The next section provides an examination of some key issues for TCP/IP networking.

Understanding TCP/IP

TCP/IP is versatile but also complex. Before you can set up a TCP/IP network and correctly configure the computers and other devices on the network, you must understand many key issues. The following sections explain these issues, beginning with IP addressing.

Understanding IP Addressing

On a TCP/IP network, a host is any device on the network that uses TCP/IP to communicate, including computers, routers, and other devices. Each host must have a unique address, called an IP address (IP stands for Internet Protocol). An IP address identifies the host on the network so IP data packets can be properly routed to the host. IP data packets are simply data encapsulated in IP format for transmission using TCP. Every IP address on the network must be unique; conflicting (identical) IP addresses on two or more computers prevent those computers from correctly accessing and using the network.

An IP address is a 32-bit value usually represented in dotted-decimal notation, in which four octets (eight bits each) are separated by decimals, as in 198.87.118.1. The IP address actually contains two items of information: the address of the network and the address of the host on the network. How the network and address are defined within the address depends on the class of the IP address.

IP addresses are grouped into three classes, A, B, and C. These classes are designed to accommodate networks of varying sizes. Table 22.1 describes the IP address classes, where the variables w.x.y.z designate the octets in the address structure.

TABLE 22.1 IP Address Classes

Class ID Network Host ID Available Networks Available Hosts per Network
A 1-126 w x.y.z 126 16,777,214
B 128-191 w.x y.z 16,384 65,534
C 192-223 w.x.y z 2,097,151 254


TIP: The address 127.x.x.x is reserved on the local computer for loopback testing and interprocess communication, and therefore is not a valid network address. Addresses 224 and higher are reserved for special protocols, such as IGMP multicast, and can't be used as host addresses. Host addresses 0 and 255 are used as broadcast addresses and should not be assigned to computers. You can always reference your local LAN card by the address 127.0.0.1 for testing.

As Table 22.1 shows, class A networks are potentially quite large, encompassing as many as 16,777,214 hosts. If you set up your own TCP/IP network, yours most likely falls into the class C network category, which is limited to 254 hosts.

You might wonder what's so important about an IP address. Routing data packets between computers is impossible without an IP address. By referencing the network portion of your IP address, a sending computer can route packets (with the help of intermediate routers and networks) to your network. The host portion of your IP address then routes the packet to your computer when the packet finally reaches the network.

Using Subnet Masks

A subnet mask is a 32-bit value expressed as a series of four octets separated by periods, just like an IP address. The subnet mask enables the re- cipient of an IP data packet to strip (mask) the IP address to which the IP packet is being sent into network ID and host ID. Basically, the subnet mask enables the IP address to be broken into its two component parts. Table 22.2 shows the default subnet masks for standard class A, B, and C networks, with each subnet mask shown in binary and dotted-decimal forms.

TABLE 22.2 Default Subnet Masks

Class Bit Value Subnet Mask
A 11111111 00000000 00000000 00000000 255.0.0.0
B 11111111 11111111 00000000 00000000 255.255.0.0
C 11111111 11111111 11111111 00000000 255.255.255.0


TIP: The subnet masks described in Table 22.2 are not the only masks you can use. Sometimes you have to mask only some of the bits in an octet. The network address and subnet mask must match, however, for every host on a local network.

In addition to enabling an IP address to be resolved into its network and host components, subnet masks also serve to segment a single network class address space into multiple subnets. For example, subnetting enables you to divide a single class C address space into multiple, separate networks. Instead of having one subnet that contains 254 hosts, for example, you might divide the class C address space into two separate subnets. Each subnet would act as a unique network. Using a mask of 255.255.255.224, for example, creates six subnets with a maximum of 30 hosts per subnet.

Here's an example of when you might use subnetting: Assume that you want to build a wide area network (WAN) that encompasses multiple divisions of your company. You have two different sites and need to route traffic between them. You have been assigned only one class C address space, however. To set up routing between the different divisions, the IP addresses of the routers must be in different subnets. So you divide your single class C address space into two subnets, one for each division.

Without subnetting, class A and B networks would be too large to be practical. A class A address space, for example, contains enough addresses to accommodate 224 - 2 hosts. It's unlikely that anyone would want to build a network with that many hosts, so subnetting is employed to break the class A network into separate smaller networks with fewer hosts.

In addition, subnetting hides the internal structure of a network from external routers. To reach a host on a subnetted network, an external router needs only to know the IP address of the router that serves the class B network. This significantly reduces the size of public routing tables and makes routing much more efficient.

When you are applying a subnet mask to a computer, keep in mind that the subnet mask effectively places the computer on a specific subnet. The subnet mask must therefore match the subnet mask of all other hosts on the same subnet. If it does not match, routing will not occur properly for that computer. The subnet mask you use is dependent on the logical design of your network. If you aren't sure which subnet mask to use, consult your network administrator.


TIP: Calculating subnet masks by hand is difficult. A good utility that simplifies subnet calculation is the IP Subnet Calculator developed by Net3 Group, Inc., of St. Paul, MN, U.S. You can find a copy of the program at http://www.tucows.com.

Acquiring an IP Address

Although theoretically you could arbitrarily assign your own IP network address for your network, any address you might choose probably would already be assigned to someone else's network. If your network is self- contained and not connected to the Internet, duplicate addressing shouldn't cause any problems. If your network is connected to the Internet or you decide to connect it in the future, however, duplicate addressing causes serious routing problems for both networks.

To assure uniqueness of network addresses, a governing organization known as InterNIC (Internet Network Information Center) is responsible for assigning and maintaining IP addresses. If you set up a TCP/IP network, you should contact InterNIC to obtain a unique network IP address for your network. You can contact InterNIC at the following address or phone number. You also can register through the Internet by sending a registration request to hostmaster@internic.net. If you want more information about InterNIC and IP addressing, you can connect through the Internet to is.internic.net, log on as anonymous, and browse the directory /INFOSOURCE/FAQ for more information. Or, you can point your browser to http://rs.internic.net. To contact InterNIC through standard mail, phone, or fax, use the following information:

Network Solutions InterNIC Registration Services 505 Huntmar Park Drive Herndon, VA 22070 703-742-4777 Fax 703-742-4811

Understanding Gateways and Routing

To interconnect and provide routing of data packets, TCP/IP subnetworks interconnected with one another or connected to the Internet use gateways (routers). Generally, a default gateway is a computer or router that maintains the IP address information of remote networks (networks outside its own network). Default gateways are required only on interconnected networks--standalone TCP/IP subnets do not require default gateways.

Before a host transmits an IP packet, IP inserts the originating and destination IP addresses into the packet. It then checks the destination address to determine whether the packet is destined for the same local network as the originating host. If the network addresses match (based on the subnet mask), the packet is routed directly to the destination host on the same subnet. If the network addresses don't match, the packet is sent to the subnet's default gateway, which then handles routing of the packet. The default gateway maintains a list of other gateways and network addresses, and routes the packet accordingly. Although the packet might pass through many gateways, it eventually reaches its destination.

If yours is a standalone subnet, you don't need a default gateway. Otherwise, you need at least one functioning default gateway to communicate outside of your subnet. If for some reason your default gateway becomes inoperative (a router fails, for example), you can't communicate outside your subnet, but you still can work within your subnet. If you need to ensure a connection, you might want to consider using multiple default gateways.


TIP: You can use the route utility from the command prompt to specify a static route and override the default gateway.

Using Dynamic Address Assignment

In TCP/IP networks that comprise relatively few nodes, or in which the network configuration is static (computers do not access the network remotely and the number of hosts doesn't fluctuate), IP address administration is relatively easy. The network administrator simply assigns specific IP addresses to each host.

On large or dynamic networks, however, administering IP addresses can be difficult and time consuming. To help overcome this problem, Windows 98 supports Dynamic Host Configuration Protocol, or DHCP, which enables a host to automatically obtain an IP address from a DHCP server when the host logs on to the network. When you move a host from one subnet to another on your network, the host automatically receives a new IP address, and its original IP address is released, making it available for other connecting hosts.

By providing dynamic addressing, DHCP enables you to manage a pool of IP addresses for a group of hosts. Assume that your company has 100 employees who often dial into your subnet from remote locations, but not at the same time. At any one time, 25 to 30 remote users might be connected to the network, but your subnet has only 50 available subnet host addresses. If you assign IP addresses manually, you can accommodate only 50 of the remote users. You can't assign the same IP address to 2 users, because if they both connect to the network at the same time, routing problems prevent them from using the network.

Through DHCP, you can allocate a pool of 50 IP addresses to be assigned automatically to the dial-in users. When a user dials in and connects, DHCP assigns its host a unique IP address from the pool. As long as no more than 50 users attempt to log on to the network remotely and acquire IP addresses, you can accommodate all 50 with unique addresses. If the number of users who need to connect exceeds the number of available addresses, the only solution is to expand your pool of available addresses or modify the subnet mask to accommodate more than 50 addresses.

DHCP in Windows 98 relies on a Windows NT DHCP server (or hardware-based DHCP server) that can assign IP addresses to hosts on the local subnet when the hosts start Windows 98, and can assign IP addresses to hosts that connect to the network remotely.

In addition to using DHCP, Windows 98 can request an IP address from a PPP (Point-to-Point Protocol) dial-up router. Whether you use DHCP or connect to a PPP dial-up router, you use the same configuration option to configure dynamic address assignment.

Understanding Domains and Name Resolution

Computers have no problems using IP addresses to locate other networks and hosts. The average user, however, can have trouble remembering those dotted-decimal addresses. Domain names and computer names make specifying the addresses or other networks or hosts much easier.

A domain name is a unique named formatted much like an IP address, except that the domain name uses words rather than numbers. The domain name identifies your network and is associated with your network's IP address. If your company is Foo Fang Foods, Inc., for example, your departmental subnet might be known as sales.foofang.com. The first portion, sales, identifies your subnet. The second portion, foofang, identifies your corporate network. The last portion, .com, specifies the type of organization, and in this example, indicates a commercial network. Other common designators are .gov for government, .edu for education, .mil for military, .org for noncommercial organizations, and .net for networking organizations.


TIP: As with your IP address, your domain must be unique. If you connect your network to other networks or to the Internet, contact the InterNIC to apply for a unique domain name.
A computer name specifies a host on the subnet. Your host computer name is combined with your domain to derive your Internet address. Your host name doesn't have to match your computer's name that identifies it in its workgroup, but it 
can. By default, Windows 98 uses as your host name the NetBIOS computer name you specify during setup, but you can specify a different name when you configure TCP/IP. Whatever name you specify as the computer name in the TCP/IP configuration is 
registered with the network when Windows 98 starts.


NOTE: The computer name you specify for your computer when you install Windows 98 is its NetBIOS name. A computer's NetBIOS name bears no relationship to its host name under TCP/IP. The two names can be different or the same.

No direct translation or correlation exists between IP addresses and domain names and host names. Some method, therefore, is required to enable computers to look up the correct IP address when a user specifies a name rather than an IP address. Your Windows 98 host can use one of two methods: DNS or WINS.


NOTE: For a technical discussion of DNS and WINS, you can consult volume 2 of the Microsoft Windows NT Resource Kit, Windows NT Networking Guide, or the Windows 98 Resource Kit on the Windows 98 CD-ROM.

Understanding DNS

DNS stands for Domain Name System and is a distributed database system that enables a computer to look up a computer name and resolve the name to an IP address. A DNS server maintains the database of domain names and their corresponding IP addresses. The DNS server stores records that describe all hosts in the name server's zone.

If you use DNS for your Windows 98 workstation, you specify the IP address of one or more DNS servers in your TCP/IP configuration. When your workstation needs to resolve a name into an IP address, it queries the DNS servers. If the server doesn't have an entry for the your specified name, the name server returns a list of other name servers that might contain the entry you need. The workstation then can query these additional name servers to resolve the name.


TIP: You can define multiple DNS servers in your Windows 98 TCP/IP configuration.

Besides a DNS server, you can use the Hosts file to resolve host.domain- formatted names to IP addresses.

Understanding WINS

WINS stands for Windows Internet Name Service. WINS provides a dynamic database for managing name resolution. WINS relies on a Windows NT server to act as a WINS server. When you install TCP/IP on your workstation, the client software necessary to connect to a WINS server is installed automatically.

One advantage of using WINS is that it's dynamic, rather than static like DNS. If you use DHCP to assign network addresses, WINS automatically updates the name database to incorporate DHCP IP address assignments. As computers move from one place (and address) to another on the network, the WINS server automatically updates and maintains their addresses.

Another advantage of using WINS is that it includes NetBIOS name space, which enables it to resolve NetBIOS names into IP addresses. Assume that your computer's NetBIOS name is joeblow, your computer's TCP/IP host name is JoeB, and your domain name is bozos.are.us. A DNS server could only resolve JoeB.bozos.are.us, but a WINS server could resolve JoeB.bozos.are.us and joeblow.bozos.are.us into the correct IP address.


TIP: The Microsoft Windows NT Resource Kit contains a good technical explanation of other advantages WINS offers.

When you configure TCP/IP in Windows 98, you can specify the IP addresses of up to two WINS servers to handle name resolution. If your network uses DHCP, you can configure your workstation to resolve the addresses of WINS servers dynamically using DHCP.

If you don't have a WINS server available to provide name resolution of NetBIOS computer names to IP addresses (such as resolving your computer's name to its IP address), you can use the Lmhosts file to resolve NetBIOS names.

Issues for NetWare

The NetWare client provided with Windows 98, Client for NetWare Networks, supports the IPX/SPX protocol also included with Windows 98. The IPX/SPX protocol provides full compatibility with NetWare networks and replaces the NetWare IP protocol. The Client for NetWare Networks, however, doesn't support NetWare IP protocol. Also, the Microsoft TCP/IP protocol stack that comes with Windows 98 does not support any NetWare clients owing to differences in the protocol implementations of TCP/IP and NetWare IP. Therefore, you must use the IPX/SPX protocol or a NetWare-supplied protocol for NetWare connectivity.

Even though you can't use Microsoft TCP/IP for NetWare connectivity, you can use Microsoft TCP/IP to provide internetworking for other clients and services. You might use IPX/SPX for connectivity with NetWare servers on the network, for example, and use Microsoft TCP/IP for connectivity and resource sharing with Microsoft- or UNIX-based servers. Or, you might use Microsoft TCP/IP for Internet connectivity through a router or a dial-up networking connection.

If you use only a NetWare client (because you have a homogeneous NetWare environment with no other server types), and want to use Microsoft TCP/IP for connectivity through a router or dial-up connection to the Internet, you don't have to install any other networking clients or services to enable that TCP/IP connection. TCP/IP connectivity to the Internet does not require a network client or sharing service of its own.

Preparing to Install TCP/IP

Now that you have a little background in how TCP/IP works, you're almost ready to install, configure, and begin using TCP/IP on your Windows 98 workstation. Before you begin the installation procedure, however, you need to gather together the information you must provide when you configure TCP/IP. In particular, you need to know the following information:


TIP: If you are configuring TCP/IP for use only with dial-up networking, you do not have to worry about configuring any TCP/IP settings through the Network object in the Control Panel. You set these values through the Dial-Up Networking connection properties.

Installing and Configuring TCP/IP in Windows 98

Before you can begin taking advantage of TCP/IP, you have to install it. Of all network protocols, TCP/IP is the most complex to install and configure owing to its many settings and options. This section explains those settings and options, beginning with the installation process.


NOTE: If you have not read the previous section of this chapter, you should do so to learn what items of information you need before you install and configure TCP/IP.

Installing Microsoft TCP/IP

Microsoft TCP/IP installs like any other network transport protocol--through the Control Panel. To install TCP/IP, open the Control Panel and choose the Network object. From the Configuration property page, choose the Add button. Windows 98 displays a Select Network Component Type dialog box from which you can choose the type of network component you want to install. Select Protocol from the supplied list, and then choose Add. Windows 98 displays a Select Network Protocol dialog box similar to the one shown in Figure 22.1. From the Manufacturers list, select Microsoft. Then, from the Network Protocols list, select TCP/IP.

FIGURE 22.1 Choose the TCP/IP protocol from the Network Protocols list.

After you choose OK, Windows 98 adds the TCP/IP protocol to your PC, copying files as necessary from the Windows 98 distribution disks or CD. After it copies the files, the TCP/IP protocol appears in the installed components list on the Configuration property page. If you have more than one adapter, Windows 98 adds TCP/IP to each one. If your workstation contains a network adapter, for example, and you also use the Dial-Up Adapter for remote access, Windows 98 binds TCP/IP to both adapters. If you need TCP/IP on only one adapter, select the instance of the TCP/IP protocol that you don't need, and then choose Remove.

Next, you need to specify a number of settings to properly configure TCP/IP, beginning with the IP address. To do so, select the TCP/IP protocol from the Configuration property page, and then choose Properties to open the TCP/IP property sheet. The following sections explain how to set the values on the property pages for the TCP/IP protocol.


TIP: You can configure and use multiple sets of TCP/IP settings. You can use one configuration for your LAN TCP/IP connection, for example, and specify different settings for each dial-up connection you use. For information on using TCP/IP over a dial-up networking connection, refer to Chapter 21.

Configuring IP Addressing

When Windows 98 first displays the property sheet for the TCP/IP protocol, the IP Address page appears (see Figure 22.2). If you use a static IP address for your workstation, choose the Specify an IP address option button; then 
enter the IP address and subnet mask for your workstation in the IP address and Subnet mask fields. If you want to rely on a DHCP server or PPP server to assign an IP address automatically for your workstation, choose the 
Obtain an IP address automatically option button. You do not have to specify the IP address of the DHCP server.

FIGURE 22.2 Specify the IP address or choose DHCP for automatic assignment.

If you specify an explicit IP address, take the time to verify that you have entered the correct address and subnet mask before you continue to the other configuration steps.

Configuring a Gateway

If your subnet is connected to other subnets, to other networks, or to the Internet, you must specify at least one default gateway. To do so, choose the Gateway tab to open the Gateway property page (see Figure 22.3).

FIGURE 22.3 For many connections you must specify a default gateway.


TIP: Your network's router typically is the default gateway.

If your network is connected to multiple gateways, you can specify as many gateways as necessary to allow for fault tolerance if one gateway becomes unavailable. To add a gateway, enter its IP address in the New gateway field, and then choose Add. Windows 98 adds the gateway's IP address to the Installed gateways list. If you add multiple gateways to the list, the IP address at the top of the list serves as the default gateway. Other gateways in the list are used only if the default gateway is inaccessible. Unfortunately, you can't simply drag the IP addresses in the Installed gateways list to prioritize them. Instead, the gateway addresses are placed in the list in the order in which you add them. To prioritize a set of gateways, write down the gateway addresses, remove the addresses, and add them back in using your preferred order of priority, adding the default gateway first.

Using DNS

If your workstation requires Domain Name System (DNS) services, click the DNS Configuration tab to open the DNS Configuration property page shown in Figure 22.4. To enable DNS, choose the Enable DNS option button.

FIGURE 22.4 You use DNS to resolve names into IP addresses.


TIP: If your computer needs to use Lmhosts to resolve network names, you must enable DNS.

Specifying Host and Domain Names

After you enable DNS, you need to specify some additional items of information. First, you need to specify the host name for your computer in the Host text box. By default, the host name is your computer's name as specified in the Identification property page of the Network property sheet. You can use any host name, however; you might use your name as the host name, for example. You can use any combination of letters and numbers--a dash, or a period, but not a space or underscore character--in the host name.

Next, specify the domain name for your network in the Domain text box. TCP/IP combines the host name you specify with the domain name you specify to derive a Fully Qualified Domain Name (FQDN) for your computer. If your host name is JimB and your domain name is newriders.mcp.com, the FQDN for your computer is JimB.newriders.mcp.com.


NOTE: Some TCP/IP utilities use your host name, domain name, and FQDN to authenticate your computer name. Note that a computer's FQDN is not the same as a user's e-mail address. Although the FQDN might be JimB.newriders.mcp.com, the e-mail address might be jboyce@newriders.mcp.com. Also, a DNS domain name and a Windows NT or LAN Manager domain name are in no way related.

Specifying DNS Server IP Addresses

If you do not use DHCP to define IP addresses, you must provide the IP addresses of the DNS servers you use. If you do use DHCP, the DHCP server can automatically provide the IP addresses of the DNS servers.

You can specify up to three DNS server addresses in the DNS Server Search Order group of controls. First, determine the IP address of the DNS server you want to use by default. Then, enter the server's IP address in the IP address text box and choose Add. Enter a second IP address if you want, and then choose Add. Enter a third IP address in the same manner if you have a third DNS server.


NOTE: The DNS server IP addresses are placed in the list in the order in which you add them. Therefore, you should enter the DNS server with the highest priority first, followed by any other servers in descending order of priority. To change priority of DNS servers in the list, you must remove and re-add the IP addresses. Windows 98 uses the secondary and tertiary DNS servers only if the primary DNS server does not respond. If the primary DNS server responds that the requested name is not recognized, Windows 98 does not query the secondary or tertiary DNS servers. If you know the name is correct, you can use the Hosts file to enable proper resolution of the name, as explained later in the section titled "Using Hosts and Lmhosts Files."

Adding Domain Suffix Entries

Normally, DNS appends the domain name specified in the Domain text box to your host name to resolve the FQDN of your computer. You can specify up to five additional domain suffixes that DNS can use if it can't resolve the FQDN using the default domain name. A DNS server attempts to resolve the FQDN using these additional suffixes in alphabetical order (which is how they appear in the list after you add them).

To add additional domain suffixes, enter a domain name in the Domain Suffix Search Order text box, and then choose Add. Repeat the process to add up to five domain names.

Using WINS

If your network includes one or more Windows NT servers configured as WINS servers, or access to WINS servers, you can configure your Windows 98 TCP/IP stack to use WINS to resolve names. WINS offers numerous advantages over DNS, particularly in conjunction with DHCP. To configure WINS, click the WINS Configuration tab to display the WINS Configuration property page shown in Figure 22.5.

FIGURE 22.5 WINS is similar to DNS in many respects.

To enable WINS for your computer, choose the Enable WINS Resolution option button. You can specify a primary and a secondary WINS server by entering their IP addresses in the fields provided for that purpose on the property page. If your computer uses DHCP to resolve names, however, you can leave the IP address fields blank and choose the Use DHCP for WINS Resolution option button, and Windows 98 queries the DHCP server for the WINS server addresses.

Binding the TCP/IP Protocol

If you use TCP/IP for resource access and/or resource sharing, you must bind the protocol to the necessary network client and/or resource sharing service. To do so, click the Bindings tab to open the Bindings property page (see Figure 22.6). Enable the check box beside the client or service to bind the protocol to the client or service.

FIGURE 22.6 Use the Bindings page to bind protocols to a client or service.


NOTE: If you use TCP/IP only to provide access to the Internet and use a different network protocol to provide local resource sharing, you don't have to bind TCP/IP to your clients or services.

Using Hosts and Lmhosts Files

DNS name servers resolve FQDN names provided in the host.domain format to IP addresses. A WINS server can resolve IP host.domain names to IP addresses, and it also can resolve a computer's NetBIOS name into its address name. Sometimes, however, being able to resolve names locally, without relying on a DNS or WINS name server, comes in handy. You might not have a DNS or WINS name server available to you, for example, or the server might be temporarily unavailable.

Windows 98 provides two methods for resolving names to IP addresses locally, which you can use in conjunction with or in place of DNS and WINS name resolution. Both methods rely on simple ASCII files to store database entries for names and corresponding IP addresses. The first of these files, Hosts, resolves DNS-formatted names, and works with or in place of DNS. The second file, Lmhosts, resolves NetBIOS names into IP addresses and works with or in place of WINS.

The following section explains the Hosts file. The Lmhosts file is explained in the section after the following section.

Using the Hosts File for Name Resolution

If you can't access a DNS server, or you want to supplement a DNS server with your own entries, you can use the Hosts file to maintain a database of host names and their corresponding IP addresses. The Hosts file is called a host table because it contains a table of host names and their IP addresses. Windows 98 can look up entries in the Hosts file to resolve names.

When you install Microsoft TCP/IP, Windows 98 creates a sample Hosts file named Hosts.sam in the Windows folder. The Hosts.sam file is an ASCII file that you can edit using Notepad, WordPad, Edit, or any other ASCII editor. You should copy Hosts.sam to Hosts (omitting a file extension) and retain the sample file for future reference in case your Hosts file becomes corrupted or is accidentally deleted. The following lists the contents of the Hosts.sam file:

# Copyright (c) 1994 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Chicago
#
# 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 correspond
# ing host name. The IP address and the host name should be sepa
# rated by at least one space.
#
# Additionally, comments (such as these) may be inserted on indi-
# vidual lines or following the machine name denoted by a `#'  # symbol.
#
# For example:
#
#      102.54.94.97     tools.acme.com          # source server
#       38.25.63.10     x.acme.com             # x client host
127.0.0.1       localhost

The Hosts file uses the same format as the hosts file used on 4.3 BSD UNIX, stored in the /etc/hosts file. The Hosts.sam file contains comments identified by a leading # character and a single address entry for localhost. The localhost entry is always 127.0.0.1 and is used for loopback testing. You should not change the IP address for localhost or remove it from the Hosts file.

To add an entry to the Hosts file, enter the IP address, tab to the second column and then enter the host name. You can specify more than one host name for an IP address, but you must use multiple entries for the different domains, each with the same IP address, as in the following example:

102.54.94.97     tools.acme.com
102.54.94.97     TOOLS.ACME.COM
102.54.94.97     fooyang.gruel.com

Entries in the Hosts file are case sensitive. The two entries for tools.acme.com and TOOLS.ACME.COM would enable the correct host name resolution if you specified the host name in lowercase or uppercase.

You can include a single host name for each entry or specify multiple host names for a single IP address. The following, for example, are valid entries:

198.87.118.72   me           theboss         jboyce.somewhere.com
198.87.118.50   TheServer     theserver       THESERVER

Each of the entries in this example specifies three host names for each IP address.

Windows 98 parses the entries in the Hosts file in sequential order until it finds a match. If you have a large Hosts file, you can speed up lookup time by placing the most-often-used host name entries at the top of the file.

Using the Lmhosts File for Name Resolution

If you want Windows 98 to be able to resolve NetBIOS computer names to IP addresses, you need to use a WINS or Lmhosts file. NetBIOS names are the computer names assigned to computers on Microsoft-based networks, such as the name you assigned to your computer through the Identification page of the Network property sheet. As explained previously, your computer's NetBIOS name is not equivalent to your TCP/IP host name, although the two can use the same name.

Windows 98 automatically resolves NetBIOS names for computers running TCP/IP on a local network. To resolve IP addresses of computers on other networks to which yours is connected by a gateway (when a WINS server is not available), you need to use Lmhosts.


NOTE: Like Hosts, Lmhosts is an ASCII file, and the format of an entry is similar to entries in a Hosts file. The Lmhosts file, however, supports special keywords, which are explained later in this chapter. Windows 98 includes a sample Lmhosts file named Lmhosts.sam, located in the Windows folder. To use Lmhosts, copy Lmhosts.sam to Lmhosts without a file extension, and then modify Lmhosts to add entries.

Microsoft TCP/IP reads the Lmhosts file when you start the computer. As it does the Hosts file, Windows 98 parses each line sequentially, which means you should place often-accessed names at the top of the file for best performance. You also need to place entries that contain special keywords at specific locations in the file (these placement rules are explained later in the chapter). First, here are a few rules for structuring a Lmhosts file:


TIP: Although Microsoft TCP/IP reads the Lmhosts file at system startup, only entries designated as preloaded by the #PRE keyword are read into the name cache at startup. Other entries are read only after broadcast name resolution queries fail.

You can use any or all of six special keywords (described in the following list) in a Lmhosts file:

#INCLUDE     \\server\pub\lmhosts     #PRE






184.121.214.2  appserver  #PRE  #DOM:thedomain    #This is a  comment






#INCLUDE  c:\mystuff\Lmhosts      #Includes local file




NOTE: If you reference a remote Lmhosts file on a server outside your network in a #INCLUDE statement, you must include an entry for the IP address of the remote server in the Lmhosts file. The server's entry must be inserted in the Lmhosts file before the #INCLUDE statement that references it. You also should not use #INCLUDE to reference a Lmhosts file on a redirected network drive, because your drive mappings might be different from one session to another. Use the UNC path for the file instead. Centralized Lmhosts files should never use drive-referenced entries, because the drive mappings in the file probably will not apply to all users who might use the file.
109.88.120.45   "thename   \0x14"       #Uses special character

Adding an Entry to Lmhosts

NetBIOS computer names of computers on your LAN are resolved automatically. To resolve remote names when a WINS server is not available, add the NetBIOS names and their corresponding IP addresses to the Lmhosts file. To add an entry, use Notepad, WordPad, Edit, or any other text editor that enables you to edit and save ASCII files.

Each line consists of the IP address and NetBIOS name, and also can contain optional keywords and comments as explained previously. The following are examples of Lmhosts entries:

192.214.240.2	me				#Alias for 							#my computer
198.87.118.72	tower				#Fred's computer
198.87.118.50	rli-server  #PRE		#Application server
120.89.101.70	server      #PRE #DOM:tigers	#Some comment here
182.212.242.2	sourcesrvr  #PRE		#Source for shared 							#Lmhosts
182.212.242.3	source2     #PRE		#Source for shared 							#Lmhosts
182.212.242.4	source3     #PRE		#Source for shared 							#Lmhosts
187.52.122.188	images				#Imaging server
#INCLUDE		c:\mystuff\lmhosts		#My private Lmhosts 							#file

#BEGIN_ALTERNATE
#INCLUDE		\\sourcesrvr\pub\Lmhosts	#Primary central 								#Lmhosts
#INCLUDE		\\source2\pub\Lmhosts		#Alternate source
#INCLUDE		\\source3\pub\Lmhosts		#Alternate source
#END_ALTERNATE

In the preceding example, only the rli-server, server, sourcesrvr, source2, and source3 entries are preloaded into the name cache at system startup, because only they include the #PRE keyword. Other entries are parsed only after broadcast name resolution requests fail.


TIP: The addresses of servers you specify in a block inclusion must be preloaded through entries earlier in the file. Any entries not preloaded are ignored.

Using a Proxy Server

A proxy server is a device that serves as an intermediary agent (a proxy) between a client and server resources. The proxy server software might run on a server (such as Windows NT), or it might reside within a piece of networking equipment such as a router. In any case, the proxy server performs two primary functions: it acts as a security barrier to help isolate an internal LAN from the outside world (such as the Internet), and can also serve to limit the types of resources that client machines on the LAN can access.

A proxy server typically resides on two subnets. One side resides on the LAN, and the other resides on the Internet side. The proxy server is referred to as a multihomed system for this reason, and contains two (or more) network interface cards. Figure 22.7 shows an example of a proxy server implementation.

FIGURE 22.7 A typical proxy server implementation.

Because the proxy server sits between the Internet and the LAN, it can serve as an intermediary between the Internet and clients on the LAN for specific types of IP traffic. When a client requests a Web page, for example, the client passes the request to the proxy server. The proxy server then passes the request to the remote Web server, substituting its own address for the client's. When the Web page is returned to the proxy server, the proxy server passes the page to the client. The same behavior occurs for other proxied services such as FTP, Gopher, and so on.

The other function the proxy server performs is to isolate the LAN addresses from the Internet. The proxy server requires one valid IP address on the Internet side, but the LAN addresses can comprise essentially any range of IP addresses. These LAN-side addresses can duplicate those at other sites on Internet without generating routing conflicts because those LAN IP addresses are never broadcast past the proxy server. With a proxy server in place, you can essentially "pull IP address assignments out of the air." You don't have to worry about being allocated address space from InterNIC for your LAN. You only have to have a valid, unique IP address for the Internet side of the proxy server and, of course, for your router and any other hosts on the Internet side of the proxy server.

In a sense, the proxy server acts as a router and performs limited firewall functions. Because the proxy server does not generally perform advanced packet filtering, however, it does not offer the full capability of a firewall. Proxy servers can, however, be an important security tool.

Windows 98 enables you to configure your workstation to work through a proxy server. To configure proxy settings, right-click the Internet Explorer icon on the desktop and choose Properties or double-click the Internet object in the Control Panel. The Internet Properties sheet appears. Click the Connection tab to display the Connection page shown in Figure 22.8.

FIGURE 22.8 You access proxy server settings through the Connection page.

In the Proxy server control group, place a check in the Access the Internet using a proxy server check box. In the Address field, specify the IP address of the proxy server. Specify the TCP port for proxy services on the server in the Port field. If you have intranet resources on the LAN that you can access without going through the proxy server, place a check in the Bypass the proxy server for local (intranet) addresses check box.

If your network provides multiple proxy servers, each handling a different type of protocol (HTTP, FTP, and so on), you can configure each one separately. Click the Advanced button to display the Proxy Settings dialog box shown in Figure 22.9.


FIGURE 22.9 You can specify unique settings for each proxied service.

If you use the same proxy server for all protocols, place a check in the Use the same proxy server for all protocols check box. Otherwise, specify the address and port for each protocol in its respective text box.

One additional configuration you can perform through the Proxy Settings dialog box is to specify addresses for which Windows 98 should bypass the proxy server. These would be addresses for local intranet resources that you do not have to go through the proxy server to access. Separate each entry with a semicolon. You can use wildcards to specify ranges of addresses or match multiple domains. For example, using 205.219.134.* would cause Windows 98 to bypass the proxy server for all addresses within the specified subnet. You also can specify DNS names such as *.mydomain.com. When you are satisfied with the settings, choose OK, and then OK on the Internet Properties sheet to close the sheet.

Now that you have a better understanding of TCP/IP, you're ready to begin putting TCP/IP to work for you. The remaining chapters in this section explore the many TCP/IP utilities and programs included with Windows 98 for file download, troubleshooting, and browsing the Web.


Previous chapterNext chapterContents

© Copyright, Macmillan Computer Publishing. All rights reserved.