Saturday, December 8, 2007

Implementing TCP/IP

TCP/IP Overview

Transmission Control Protocol/Internet Protocol (TCP/IP) is an industry-standard suite of protocols designed for wide area networks (WANs). Microsoft Windows 2000 has extensive support for TCP/IP both as a protocol suite and a set of services for connectivity and management of IP networks. This lesson includes an overview of TCP/IP concepts, terminology, and how the Internet standards are created. You will also learn how Windows 2000 integrates with TCP/IP.

Benefits of TCP/IP

All modern operating systems offer TCP/IP support, and most large networks rely on TCP/IP for much of their network traffic. TCP/IP is also the protocol standard for the Internet. In addition, many standard connectivity utilities are available to access and transfer data between dissimilar systems. Several of these standard utilities, such as File Transfer Protocol (FTP) and Telnet, are included with Windows 2000 Server. TCP/IP networks can be easily integrated with the Internet. Because of its popularity, TCP/IP is well developed and offers many utilities that improve usability, performance, and security. Networks that are based on other transport protocols, such as ATM or AppleTalk, can interface with TCP/IP networks through a device known as a gateway. Adding TCP/IP to a Windows 2000 configuration offers the following advantages:

  • It offers a technology for connecting dissimilar systems. TCP/IP is routable and can be connected to different networks through gateways.
  • It allows for a robust, scalable, cross-platform client/server framework. Microsoft TCP/IP offers the WinSock interface, which is ideal for developing client/server applications that can run on WinSock-compliant stacks from other vendors.
  • It provides a method of gaining access to the Internet. By connecting to the Internet, a virtual private network (VPN) or extranet can be established, allowing for inexpensive remote access.

Windows 2000 TCP/IP Communication Protocols

A significant feature of Windows 2000 is the ability to connect to the Internet and to dissimilar systems. Windows 2000 also includes advanced security features that can be implemented when connecting to a system across a network. In order to support all of these features, Windows 2000 TCP/IP has new and enhanced capabilities. These include:

  • IP Security. IP Security (IPSec) is a technology used to encrypt TCP/IP network traffic. IPSec enables secure data transfer between remote clients and private enterprise servers through a virtual private network (VPN).
  • Point-to-Point Tunneling Protocol. The Point-to-Point Tunneling Protocol (PPTP) provides VPN functionality similar to that which IPSec provides. PPTP also supports multiple network protocols such as IP, Internetwork Packet Exchange (IPX), and NetBIOS Enhanced User Interface (NetBEUI).
  • Layer Two Tunneling Protocol. The Layer Two Tunneling Protocol (L2TP) is a combination of Point-to-Point Tunneling Protocol (PPTP) and Layer 2 Forwarding (L2F). L2F is a transmission protocol that allows dial-up access servers to frame dial-up traffic in Point to Point Protocol (PPP) and transmit it over WAN links to an L2F server (a router).

Finally, Microsoft continues to support legacy systems and protocols to preserve the past investments of its customers and reduce the risk, pressure, and financial burden of managing heterogeneous environments. For this reason Windows 2000 supports

  • AppleTalk
  • Internetwork Packet Exchange/Sequenced Packet Exchange (IPX/SPX)
  • NetBEUI

TCP/IP Stack Enhancements

Windows 2000 includes several TCP/IP stack enhancements, including:

  • Large window support that improves performance when many packets are in transit for long periods of time.
  • Selective acknowledgments that allow a system to recover from congestion quickly. The sender needs to retransmit only the packets that were not received.
  • The ability to better estimate round-trip time.
  • The ability to better prioritize traffic for demanding applications.

TCP/IP Utilities

TCP/IP utilities in Windows 2000 include:

  • Data transfer utilities. Windows 2000 provides support for several different IP-based data transfer protocols. These include File Transfer Protocol (FTP), HyperText Transfer Protocol (HTTP), and the Common Internet File System (CIFS).
  • Telnet. UNIX hosts have traditionally been managed using Telnet—a text interface similar to a command prompt that can be accessed across an IP network. Windows 2000 provides both a Telnet client and server.
  • Printing utilities. Windows 2000 can print directly to IP-based printers. Additionally, two TCP/IP utilities provide the ability to print and obtain print status on a TCP/IP printer. Line Printer Remote (LPR) prints a file to a host running the Line Printing Daemon (LPD) service. Line Printer Queue (LPQ) obtains the status of a print queue on a host running the LPD service.
  • Diagnostics utilities. Windows 2000 provides several utilities for diagnosing TCP/IP-related problems including PING, Ipconfig, Nslookup, and Tracert.

Application Layer

The Application layer is at the top of the four-layer conceptual TCP/IP model, and is where software programs gain access to the network. This layer corresponds roughly to the Session, Presentation, and Application Layers of the OSI model. Some TCP/IP utilities and services run at the Application Layer. These utilities and services include:

  • HyperText Transfer Protocol (HTTP). HTTP is the protocol used for the majority of World Wide Web communications. Windows 2000 includes Internet Explorer as an HTTP client, and Internet Information Server (IIS) as an HTTP server.
  • File Transfer Protocol (FTP). FTP is an Internet service that transfers files from one computer to another. Internet Explorer and the command-line utility FTP both act as FTP clients. IIS includes an FTP server.
  • Simple Mail Transfer Protocol (SMTP). SMTP is a protocol that mail servers use to transfer e-mail. IIS can send messages using the SMTP protocol.
  • Telnet. Telnet is a terminal emulation protocol that can be used to log on to remote network hosts. Telnet offers users the capability of running programs remotely and facilitates remote administration. Telnet is available for practically all operating systems and eases integration in heterogeneous networking environments. Windows 2000 includes both a Telnet client and server.
  • Domain Name System (DNS). DNS is a set of protocols and services on a TCP/IP network that allows users of the network to utilize hierarchical user-friendly names when locating hosts instead of having to remember and use their IP addresses. DNS is used extensively on the Internet and in many private enterprises today. When you use a Web browser, Telnet application, FTP utility, or other similar TCP/IP utilities on the Internet, then you are probably using a DNS server. Windows 2000 also includes a DNS server.
  • Simple Network Management Protocol (SNMP). SNMP allows you to manage network nodes such as servers, workstations, routers, bridges, and hubs from a central host. SNMP can also be used to configure remote devices, monitor network performance, detect network faults or inappropriate access, and audit network usage.

Network Application APIs

Microsoft TCP/IP provides two interfaces for network applications to use the services of the TCP/IP protocol stack:

  • WinSock. The Windows 2000 implementation of the widely used Sockets application programming interface (API). The Sockets API is the standard mechanism for accessing datagram and session services over TCP/IP.
  • NetBIOS. A standard API used as an inter-process communication (IPC) mechanism in the Windows environment. Although NetBIOS can be used to provide a standard connection to protocols that support the NetBIOS naming and messaging services, such as TCP/IP and NetBEUI, it is included with Windows 2000 mainly to support legacy applications.

Transport Layer

Transport protocols provide communication sessions between computers and define the type of transport service as either connection-oriented (TCP) or connectionless datagram-oriented (UDP). TCP provides connection-oriented, reliable communications for applications that typically transfer large amounts of data at one time. It is also used for applications that require an acknowledgment for data received. UDP, however, provides connectionless communications and does not guarantee to deliver packets. Applications that use UDP typically transfer small amounts of data at one time. Reliable delivery of data is the responsibility of the application. The Transport Layer in the DOD model corresponds roughly to the Transport Layer in the OSI model.

Internet Layer

Internet protocols encapsulate packets into Internet datagrams and run all of the necessary routing algorithms. The routing functions that the Internet layer performs is necessary to allow hosts to interoperate with other networks. The Internet Layer corresponds roughly to the Network Layer in the OSI model. Five protocols are implemented at this layer:

  • Address Resolution Protocol (ARP), which determines the hardware address of the hosts.
  • Reverse Address Resolution Protocol (RARP), which provides reverse address resolution at the receiving host. (Although Microsoft does not implement the RARP protocol, it is found on other vendors' systems, and is mentioned here for completeness.)
  • Internet Control Message Protocol (ICMP), which sends error messages to IP when problems crop up.
  • Internet Group Management Protocol (IGMP), which informs routers of the availability of members of multicast groups.
  • Internet Protocol (IP), which addresses and routes packets.

Network Interface Layer

At the base of the model is the Network Interface Layer. Each of the local area network (LAN), metropolitan area network (MAN), WAN, and dial-up types, such as Ethernet, Token Ring, Fiber Distributed Data Interface (FDDI), and ARCnet, have different requirements for cables, signaling, and data encoding. The Network Interface Layer specifies the requirements equivalent to the Data Link and Physical Layers of the OSI model. The Network Interface Layer is responsible for sending and receiving frames, which are packets of information transmitted on a network as a single unit. The Network Interface Layer puts frames on the network, and pulls frames off the network.

TCP/IP WAN Technologies

There are two major categories of WAN technologies supported by TCP/IP:

  1. Serial lines, which include dial-up analog, digital lines, and leased lines.

    TCP/IP is typically transported across a serial line using either the Serial Line Internet Protocol (SLIP) or the Point-to-Point Protocol (PPP). Windows 2000 Server supports both protocols with the Routing and Remote Access Service. Because PPP provides greater security, configuration handling, and error detection than SLIP, it is the recommended protocol for serial line communication.

  2. Packet-switched networks, which include X.25, frame relay, and asynchronous transfer mode (ATM).
NOTE
Windows 2000 supports only SLIP client functionality, not SLIP server functionality. The Windows 2000 Routing and Remote Access Service does not accept SLIP client connections.

Transmission Control Protocol

Transmission Control Protocol (TCP) is a reliable, connection-oriented delivery service. TCP data is transmitted in segments, and a session must be established before hosts can exchange data. TCP uses byte-stream communications, which means that the data is treated as a sequence of bytes.

TCP achieves reliability by assigning a sequence number to each segment transmitted. If a segment is broken into smaller pieces, the receiving host knows whether all pieces have been received. An acknowledgment verifies that the other host received the data. For each segment sent, the receiving host must return an acknowledgment (ACK) within a specified period. If the sender does not receive an ACK, then the data is retransmitted. If the segment is received damaged, the receiving host discards it. Because in this case an ACK is not sent, the sender retransmits the segment.

Internet Protocol (IP)

Although TCP separates data into discrete packets and is responsible for guaranteeing their delivery, IP does the actual delivery. At the IP Layer, each incoming or outgoing packet is referred to as a datagram. The IP datagram fields in the following table are added to the header when a packet is passed up from the Network Interface Layer.


Field Function
Source IP Address Identifies the sender of the datagram by the IP address.
Destination IP Address Identifies the destination of the datagram by the IP address.
Protocol Informs IP at the destination host whether to pass the packet up to TCP or UDP.
Checksum A simple mathematical computation that is used to verify that the packet arrived intact.
Time to Live (TTL) Designates the number of seconds a datagram is allowed to spend in transport before it's discarded. This prevents packets from endlessly looping around an internetwork. Each router that forwards the packet decrements the TTL by one. The default TTL in Windows 2000 is 128 seconds.

Basic Concepts of IP Routing

Routing is the process of choosing a path over which to send packets, which is a primary function of IP. A router (commonly referred to as a gateway) is a device that forwards the packets from one physical network to another. When a router receives a packet, the network adapter forwards the datagrams to the IP Layer. IP examines the destination address on the datagram and then compares it to an IP routing table. A decision is then made as to where the packet is to be forwarded. This lesson explains basic IP routing concepts.

Overview of Routing

A router helps LANs and WANs achieve interoperability and connectivity, and can link LANs that have different network topologies, such as Ethernet and Token Ring. Each packet sent over a LAN has a packet header that contains source and destination address fields. Routers match packet headers to a LAN segment and choose the best path for the packet, optimizing network performance. For example, if a packet is sent from Computer A to Computer C, as illustrated in Figure 2.15, the best route uses only one hop. If Router 1 is the default router for Computer A, the packet will be rerouted through Router 2. Computer A will be notified of the better route by which to send packets to Computer C. As each route is found, the packet is sent to the next router, called a hop, until finally delivered to the destination host. If a route is not found, an error message is sent to the source host.

No comments: