DATA COMMUNICATIONS AND NETWORKING

Transcription

FM Page i Wednesday, February 23, 2000 2:30 PMDATA COMMUNICATIONSANDNETWORKINGSecond Edition

FM Page ii Wednesday, February 23, 2000 2:30 PM

FM Page iii Wednesday, February 23, 2000 2:30 PMDATA COMMUNICATIONSANDNETWORKINGSecond EditionBehrouz A. ForouzanDeAnza CollegewithCatherine CoombsBostonandSophia Chung FeganBurr Ridge, ILDubuque, IAMadison,ork WISan dridMexico CityMilanNew DelhiSeouleSydneySingaporaipeiT orontoT

FM Page iv Wednesday, February 23, 2000 2:30 PMDATA COMMUNICATIONS AND NETWORKINGPublished by McGraw-Hill, an imprint of the McGraw-Hill Companies, Inc. 1221 Avenue of the Americas, NewYork, NY, 10020. Copyright 2001, 1998 by The McGraw-Hill Companies, Inc. All rights reserved. No part of thispublication may be reproduced or distributed in any form or by any means, or stored in a database or retrievalsystem, without the prior written consent of The McGraw-Hill Companies, Inc., including, but not limited to, in anynetwork or other electronic storage or transmission, or broadcast for distance learning.This book is printed on acid-free paper.1 2 3 4 5 6 7 8 9 0 DOC/DOC 0 9 8 7 6 5 4 3 2 1 0ISBN 0-07-232204-7Publisher: Thomas CassonExecutive editor: Elizabeth A. JonesDevelopmental editor: Emily J. GraySenior marketing manager: John T. WannemacherSenior project manager: Amy HillSenior production supervisor: Heather D. BurbridgeFreelance design coordinator: Gino CieslikSupplement coordinator: Susan LombardiNew media: Christopher StylesCover design: Joanne SchoplerCover illustration: Tony StoneCompositor: Interactive Composition CorporationTypeface: 10/12 Times RomanPrinter: R. R. Donnelley & Sons Company[CIP to come]http://www.mhhe.com

FM Page v Wednesday, February 23, 2000 2:30 PMTo Faezeh with love.

FM Page vi Wednesday, February 23, 2000 2:30 PM

FM Page vii Wednesday, February 23, 2000 2:30 PMBRIEF CONTENTSContentsixPrefacexxviiChapter 1Introduction1Chapter 2Basic Concepts21Chapter 3The OSI Model43Chapter 4SignalsChapter 5Encoding and ModulatingChapter 6Transmission of Digital Data: Interfacesand Modems 139Chapter 7Transmission MediaChapter 8MultiplexingChapter 9Error Detection and CorrectionChapter 10Data Link ControlChapter 11Data Link ProtocolsChapter 12Local Area NetworksChapter 13Metropolitan Area NetworksChapter 14Switching6591187231273301329369413431vii

FM Page viii Wednesday, February 23, 2000 2:30 PMviiiBRIEF CONTENTSChapter 15Point-to-Point Protocol (PPP)455Chapter 16Integrated Services Digital Network (ISDN)Chapter 17X.25Chapter 18Frame RelayChapter 19ATMChapter 20SONET/SDHChapter 21Networking and Internetworking DevicesChapter 22Transport LayerChapter 23Upper OSI LayersChapter 24TCP/IP Protocol Suite: Part 1Chapter 25TCP/IP Protocol Suite: Part 2, Application Layer471505525553Appendix A ASCII Code593613657677705777Appendix B Numbering Systems and TransformationAppendix C Representation of Binary NumbersAppendix D Fourier Analysis783791799Appendix EHardware Equipment for Error DetectionAppendix FHuffman Coding803811Appendix G LZW (Lempel-Ziv-Welch) Compression MethodAppendix H Next Generation of TCP/IP Protocol Suite: IPv6and ICMPv6Spanning TreeAppendix IGlossary845AcronymsIndex000877737825839817

FM Page ix Wednesday, February 23, 2000 2:30 PMTABLE OFCONTENTSPrefacexxviiChapter 1Introduction11.11.2WHY STUDY DATA COMMUNICATIONSDATA COMMUNICATION 21.3NETWORKSComponents34Distributed ProcessingNetwork Criteria 5Applications 61.414PROTOCOLS AND STANDARDS7Protocols 7Standards 81.5STANDARDS ORGANIZATIONSStandards Creation CommitteesForums 12Regulatory Agencies 131.61.71.81.999STRUCTURE OF THE BOOK 13KEY TERMS AND CONCEPTS 13SUMMARY 14PRACTICE SET 15Review Questions 15Multiple Choice 16Exercises 18Chapter 22.1Basic ConceptsLINE CONFIGURATION2121Point-to-Point 21Multipoint 222.2TOPOLOGY22Mesh 23Star 25Tree 25ix

FM Page x Wednesday, February 23, 2000 2:30 PMxTABLE OF CONTENTSBus 26Ring 27Hybrid Topologies2.328TRANSMISSION MODE28Simplex 29Half-Duplex 29Full-Duplex 292.4CATEGORIES OF NETWORKS30Local Area Network (LAN) 30Metropolitan Area Network (MAN)Wide Area Network (WAN) 322.52.62.72.8INTERNETWORKS 33KEY TERMS AND CONCEPTSSUMMARY 34PRACTICE SET 353233Review Questions 35Multiple Choice 36Exercises 383.1Chapter 3The OSI ModelTHE MODEL43Layered Architecture3.243FUNCTIONS OF THE LAYERSPhysical Layer 47Data Link Layer 48Network Layer 49Transport Layer 51Session Layer 53Presentation Layer 54Application Layer 55Summary of Layer Functions3.33.43.53.6434756TCP/IP PROTOCOL SUITE 56KEY TERMS AND CONCEPTS 57SUMMARY 58PRACTICE SET 59Review Questions 59Multiple Choice 60Exercises 63Chapter 44.1SignalsANALOG AND DIGITAL6565Analog and Digital Data 66Analog and Digital Signals 664.2APERIODIC AND PERIODIC SIGNALSPeriodic Signals 67Aperiodic Signals 674.3ANALOG SIGNALS68Simple Analog Signals6866

FM Page xi Wednesday, February 23, 2000 2:30 PMTABLE OF CONTENTS4.44.5TIME AND FREQUENCY DOMAINCOMPOSITE SIGNALS 7574Frequency Spectrum and Bandwidth764.6DIGITAL SIGNALS4.74.84.9KEY TERMS AND CONCEPTSSUMMARY 82PRACTICE SET 8379Decomposition of a Digital Signal8081Review Questions 83Multiple Choice 84Exercises 86Chapter 55.1Encoding and ModulatingDIGITAL-TO-DIGITAL CONVERSION9192Unipolar 92Polar 94Bipolar 975.2ANALOG-TO-DIGITAL CONVERSION102Pulse Amplitude Modulation (PAM) 102Pulse Code Modulation (PCM) 103Sampling Rate 104How Many Bits Per Sample 106Bit Rate 1075.3DIGITAL-TO-ANALOG CONVERSION107Aspects of Digital-to-Analog Conversion 108Amplitude Shift Keying (ASK) 109Frequency Shift Keying (FSK) 111Phase Shift Keying (PSK) 113Quadrature Amplitude Modulation (QAM) 116Bit/Baud Comparison 1185.4ANALOG-TO-ANALOG CONVERSION120Amplitude Modulation (AM) 121Frequency Modulation (FM) 122Phase Modulation (PM) 1255.55.65.7KEY TERMS AND CONCEPTSSUMMARY 126PRACTICE SET 127125Review Questions 127Multiple Choice 128Exercises 133Chapter 66.1Transmission of Digital Data: Interfaces andModems 139DIGITAL DATA TRANSMISSION139Parallel Transmission 140Serial Transmission 1416.2DTE-DCE INTERFACE143Data Terminal Equipment (DTE)144xi

FM Page xii Wednesday, February 23, 2000 2:30 PMxiiTABLE OF CONTENTSData Circuit–Terminating Equipment (DCE)Standards 145EIA-232 Interface 1456.3OTHER INTERFACE STANDARDS144152EIA-449 153EIA-530 157X.21 1586.4MODEMS159Transmission Rate 160Modem Standards 1646.556K MODEMS171Traditional Modems 17156K Modems 172Why Only 56 Kbps? 1746.6CABLE MODEM174Downloading 174Uploading 1756.76.86.9KEY TERMS AND CONCEPTSSUMMARY 176PRACTICE SET 177175Review Questions 177Multiple Choice 179Exercises 185Chapter 77.1Transmission MediaGUIDED MEDIA188Twisted-Pair Cable 188Coaxial Cable 192Optical Fiber 1937.2UNGUIDED MEDIA200Radio Frequency Allocation 200Propagation of Radio Waves 200Terrestrial Microwave 205Satellite Communication 206Cellular Telephony 2087.3TRANSMISSION IMPAIRMENT211Attenuation 211Distortion 213Noise 2137.4PERFORMANCE214Throughput 214Propagation Speed 215Propagation Time 2157.57.67.77.87.9WAVELENGTH 215SHANNON CAPACITY 216MEDIA COMPARISON 217KEY TERMS AND CONCEPTSSUMMARY 220218187

FM Page xiii Wednesday, February 23, 2000 2:30 PMTABLE OF CONTENTS7.10PRACTICE SET222Review Questions 222Multiple Choice 223Exercises 230Chapter 8Multiplexing2318.18.28.38.4MANY TO ONE/ONE TO MANY 231FREQUENCY-DIVISION MULTIPLEXING (FDM)WAVE-DIVISION MULTIPLEXING (WDM) 235TIME-DIVISION MULTIPLEXING (TDM) 2368.5MULTIPLEXING APPLICATION: THE TELEPHONE SYSTEMInverse Multiplexing244Common Carrier Services and HierarchiesAnalog Services 246Digital Services 2488.6232DIGITAL SUBSCRIBER LINE (DSL)245254ADSL 254RADSL 255HDSL 256SDSL 256VDSL 2568.7FTTC257FTTC in the Telephone Network 257FTTC in the Cable TV Network 2578.8 KEY TERMS AND CONCEPTS8.9 SUMMARY 2598.10 PRACTICE SET 261258Review Questions 261Multiple Choice 262Exercises 266Chapter 99.1Error Detection and CorrectionTYPES OF ERRORS273273Single-Bit Error 273Burst Error 2749.2DETECTION275Redundancy2759.39.49.5VERTICAL REDUNDANCY CHECK (VRC) 277LONGITUDINAL REDUNDANCY CHECK (LRC) 279CYCLIC REDUNDANCY CHECK (CRC) 2809.69.7CHECKSUM 284ERROR CORRECTIONPerformance284287Single-Bit Error Correction 287Hamming Code 289Burst Error Correction 291245xiii

FM Page xiv Wednesday, February 23, 2000 2:30 PMxivTABLE OF CONTENTS9.8 KEY TERMS AND CONCEPTS9.9 SUMMARY 2939.10 PRACTICE SET 294292Review Questions 294Multiple Choice 294Exercises 298Chapter 1010.1Data Link ControlLINE DISCIPLINE301302ENQ/ACK 302Poll/Select 30410.2FLOW CONTROL306Stop-and-Wait 308Sliding Window 30810.3ERROR CONTROL312Automatic Repeat Request (ARQ)Stop-and-Wait ARQ 312Sliding Window ARQ 31510.410.510.6KEY TERMS AND CONCEPTSSUMMARY 321PRACTICE SET 322312321Review Questions 322Multiple Choice 323Exercises 326Chapter 1111.1Data Link ProtocolsASYNCHRONOUS PROTOCOLS329330XMODEM 330YMODEM 331ZMODEM 331BLAST 331Kermit 33111.211.3SYNCHRONOUS PROTOCOLS 332CHARACTER-ORIENTED PROTOCOLSBinary Synchronous Communication (BSC)BSC Frames 334Data Transparency 33711.4BIT-ORIENTED PROTOCOLSHDLC 340Frames 342More about FramesExamples 35311.5339348LINK ACCESS PROCEDURES357LAPB 357LAPD 358LAPM 35811.6KEY TERMS AND CONCEPTS358332333

FM Page xv Wednesday, February 23, 2000 2:30 PMTABLE OF CONTENTS11.711.8SUMMARY 359PRACTICE SET 360Review Questions 360Multiple Choice 361Exercises 36412.1Chapter 12Local Area NetworksPROJECT 802369IEEE 802.1 370LLC 371MAC 371Protocol Data Unit (PDU)12.2ETHERNET369371372Access Method: CSMA/CD 373Addressing 374Electrical Specification 374Frame Format 374Implementation 37612.3OTHER ETHERNET NETWORKS380Switched Ethernet 380Fast Ethernet 382Gigabit Ethernet 38412.412.5TOKEN BUS 385TOKEN RING 386Access Method: Token PassingAddressing 388Electrical Specification 388Frame Formats 388Implementation 39112.6FDDI386393Access Method: Token Passing 393Addressing 395Electrical Specification 396Frame Format 397Implementation: Physical Medium Dependent (PMD) Layer12.7 COMPARISON 40112.8 KEY TERMS AND CONCEPTS12.9 SUMMARY 40212.10 PRACTICE SET 404401Review Questions 404Multiple Choice 405Exercises 410Chapter 1313.1Metropolitan Area NetworksIEEE 802.6 (DQDB)413Access Method: Dual BusDistributed Queues 416413413399xv

FM Page xvi Wednesday, February 23, 2000 2:30 PMxviTABLE OF CONTENTSRing Configuration 418Operation: DQDB LayersImplementation 42013.2SMDS421SMDS ArchitectureFeatures 42313.313.413.5419421KEY TERMS AND CONCEPTSSUMMARY 424PRACTICE SET 425424Review Questions 425Multiple Choice 425Exercises 427Chapter 1414.1SwitchingCIRCUIT SWITCHING431432Space-Division Switches 434Time-Division Switches 436TDM Bus 438Space- and Time-Division Switching CombinationsPublic Switched Telephone Network (PSTN) 44014.2PACKET SWITCHING439441Datagram Approach 442Virtual Circuit Approach 443Circuit-Switched Connection versus Virtual-Circuit Connection14.314.414.514.6MESSAGE SWITCHING 446KEY TERMS AND CONCEPTSSUMMARY 448PRACTICE SET 449447Review Questions 449Multiple Choice 450Exercises 452Chapter 1515.115.2Point-to-Point Protocol (PPP)TRANSITION STATESPPP LAYERS 456455Physical Layer 456Data Link Layer 45715.3LINK CONTROL PROTOCOL (LCP)458LCP Packets 458Options 46015.4AUTHENTICATION460PAP 460CHAP 46115.5NETWORK CONTROL PROTOCOL (NCP)IPCP 463Other Protocols464462455444

FM Page xvii Wednesday, February 23, 2000 2:30 PMTABLE OF CONTENTS15.615.715.815.9AN EXAMPLE 464KEY TERMS AND CONCEPTSSUMMARY 466PRACTICE SET 466xvii465Review Questions 466Multiple Choice 467Exercises 469Integrated Services Digital Network (ISDN)Chapter 1616.1SERVICES471Bearer Services 471Teleservices 471Supplementary Services16.2HISTORY472472Voice Communication over Analog Networks 472Voice and Data Communication over Analog NetworksAnalog and Digital Services to Subscribers 473Integrated Digital Network (IDN) 473Integrated Services Digital Network (ISDN) 47416.3SUBSCRIBER ACCESS TO THE ISDNB Channels 476D Channels 476H Channels 476User Interfaces 476Functional Grouping 478Reference Points 48016.4THE ISDN LAYERS481Physical Layer 482Data Link Layer 487Network Layer 48816.5BROADBAND ISDN492Services 493Physical Specifications16.616.716.816.9494FUTURE OF ISDN 495KEY TERMS AND CONCEPTSSUMMARY 497PRACTICE SET 498Review Questions 498Multiple Choice 499Exercises 50317.1Chapter 17X.25X.25 LAYERS506Physical Layer 506Frame Layer 506505496475472471

FM Page xviii Wednesday, February 23, 2000 2:30 PMxviiiTABLE OF CONTENTSPacket Layer 508PLP Packets 51017.2OTHER PROTOCOLS RELATED TO X.25X.121 Protocol 516Triple-X Protocols 51617.317.417.5KEY TERMS AND CONCEPTSSUMMARY 518PRACTICE SET 518517Review Questions 518Multiple Choice 519Exercises 522Chapter 1818.1Frame RelayINTRODUCTION525Advantages 528Disadvantages 528Role of Frame Relay18.2529FRAME RELAY OPERATIONVirtual Circuits 530DLCIs Inside the NetworkSwitches 53218.3525FRAME RELAY LAYERS529532533Physical Layer 534Data Link Layer 53418.4CONGESTION CONTROLCongestion AvoidanceDiscarding 53718.518.6535536LEAKY BUCKET ALGORITHMTRAFFIC CONTROL 540Access Rate 541Committed Burst Size 541Committed Information RateExcess Burst Size 542User Rate 54218.7OTHER FEATURESExtended AddressFRADs 543VOFR 544LMI 54453754154354318.8 KEY TERMS AND CONCEPTS18.9 SUMMARY 54518.10 PRACTICE SET 545Review Questions 545Multiple Choice 546Exercises 555544516

FM Page xix Wednesday, February 23, 2000 2:30 PMTABLE OF CONTENTSChapter 1919.1ATMDESIGN GOALS553553Packet Networks 554Mixed Network Traffic 554Cell Networks 555Asynchronous TDM 55619.2ATM ARCHITECTURE557Virtual Connection 557Identifiers 558Cells 559Connection Establishment and Release19.3SWITCHING559561VP Switch 561VPC Switch 56219.4SWITCH FABRICS563Crossbar Switch 563Knockout Switch 563Banyan Switch 563Batcher-Banyan Switch19.5ATM LAYERS565566Application Adaptation Layer (AAL)ATM Layer 573Physical Layer 575Service Classes 576Quality of Service (QoS) 576Traffic Descriptors 57819.6ATM APPLICATIONS566578ATM WANs 578ATM LANs 57819.719.819.9KEY TERMS AND CONCEPTSSUMMARY 582PRACTICE SET 583581Review Questions 583Multiple Choice 584Exercises 589Chapter 2020.120.2SONET/SDHSYNCHRONOUS TRANSPORT SIGNALSPHYSICAL CONFIGURATION 595SONET Devices 595Sections, Lines, and Paths20.3593SONET LAYERS597Photonic Layer 597Section Layer 597Line Layer 597596594xix

FM Page xx Wednesday, February 23, 2000 2:30 PMxxTABLE OF CONTENTSPath Layer 598Device–Layer Relationships20.4SONET FRAME598598Frame Format 599Section Overhead 600Line Overhead 601Path Overhead 602Virtual Tributaries 603Types of VTs 60320.5MULTIPLEXING STS FRAMES604ATM Convergence to SONET/SDH20.620.720.820.9APPLICATIONS 606KEY TERMS AND CONCEPTSSUMMARY 607PRACTICE SET 607605606Review Questions 607Multiple Choice 608Exercises 61121.1Chapter 21Networking and Internetworking DevicesREPEATERS614Not an Amplifier21.2BRIDGES615616Types of Bridges 618Bridges Connecting Different LANs21.3ROUTERS62021.421.5GATEWAYS 624OTHER DEVICES 625Routing Concepts622Multiprotocol Routers 625Brouters 625Switches 627Routing Switches 62721.621.7ROUTING ALGORITHMS 628DISTANCE VECTOR ROUTING628Sharing Information 628Routing Table 63021.8LINK STATE ROUTING633Information Sharing 633The Dijkstra Algorithm 63721.9 KEY TERMS AND CONCEPTS21.10 SUMMARY 64021.11 PRACTICE SET 641Review Questions 641Multiple Choice 642Exercises 645640620613

FM Page xxi Wednesday, February 23, 2000 2:30 PMTABLE OF CONTENTSChapter 2222.1Transport Layer649DUTIES OF THE TRANSPORT LAYER650End-to-End Delivery 650Addressing 651Reliable Delivery 652Flow Control 655Multiplexing 65722.2CONNECTION658Connection Establishment 658Connection Termination 65922.3THE OSI TRANSPORT PROTOCOL659Transport Classes 659Transport Protocol Data Unit (TPDU) 660Connection-Oriented and Connectionless Services22.422.522.6KEY TERMS AND CONCEPTSSUMMARY 663PRACTICE SET 664661662Review Questions 664Multiple Choice 664Exercises 666Chapter 2323.1Upper OSI LayersSESSION LAYER669Session and Transport InteractionSynchronization Points 671Session Protocol Data Unit 67223.2669PRESENTATION LAYER670673Translation 673Encryption/Decryption 675Authentication 685Data Compression 68623.3APPLICATION LAYER688Message Handling System (MHS) 688File Transfer, Access, and Management (FTAM) 690Virtual Terminal (VT) 691Directory Services (DS) 692Common Management Information Protocol (CMIP) 69323.423.523.6KEY TERMS AND CONCEPTSSUMMARY 696PRACTICE SET 697Review Questions 697Multiple Choice 698Exercises 702695xxi

FM Page xxii Wednesday, February 23, 2000 2:30 PMxxiiTABLE OF CONTENTSChapter 2424.1TCP/IP Protocol Suite: Part 1OVERVIEW OF TCP/IP705TCP/IP and the InternetTCP/IP and OSI 706Encapsulation 70624.2NETWORK LAYER705707Internetwork Protocol (IP)24.3ADDRESSING707710Classes 710Dotted-Decimal Notation 711Nodes with More Than One AddressA Sample Internet 71424.4SUBNETTING713714Three Levels of Hierarchy 716Masking 716Finding the Subnetwork Address24.5703717OTHER PROTOCOLS IN THE NETWORK LAYER719Address Resolution Protocol (ARP) 719Reverse Address Resolution Protocol (RARP) 720Internet Control Message Protocol (ICMP) 721Internet Group Message Protocol (IGMP) 72124.6TRANSPORT LAYER721User Datagram Protocol (UDP) 722Transmission Control Protocol (TCP) 72324.724.824.9KEY TERMS AND CONCEPTSSUMMARY 726PRACTICE SET 727725Review Questions 727Multiple Choice 728Exercises 732Chapter 2525.1TCP/IP Protocol Suite: Part 2, ApplicationLayer 737CLIENT–SERVER MODEL737Client 738Server 73825.2BOOTSTRAP PROTOCOL (BOOTP) AND DYNAMIC HOSTCONFIGURATION PROTOCOL (DHCP) 739BOOTP 739DHCP 73925.3DOMAIN NAME SYSTEM (DNS)DNS in the Internet25.4TELNET742Network Virtual Terminal (NVT)25.525.6740740745FILE TRANSFER PROTOCOL (FTP) 745TRIVIAL FILE TRANSFER PROTOCOL (TFTP)746

FM Page xxiii Wednesday, February 23, 2000 2:30 PMTABLE OF CONTENTS25.7SIMPLE MAIL TRANSFER PROTOCOL (SMTP)User Agent (UA) 749Addresses 749Mail Transfer Agent (MTA) 749Multipurpose Internet Mail Extensions (MIME)Post Office Protocol (POP) 75025.8747750SIMPLE NETWORK MANAGEMENT PROTOCOL (SNMP)752Concept 752SMI 753MIB 753SNMP 75425.9HYPERTEXT TRANSFER PROTOCOL (HTTP)HTTP Transaction 755Messages 756Request Messages 756Response Message 756Uniform Resource Locator (URL)25.10WORLD WIDE WEB (WWW)756758Hypertext And Hypermedia 758Browser Architecture 758Static Documents 760HTML 760Dynamic Documents 762Common Gateway Interface (CGI)Active Documents 764Java 76525.1125.1225.13KEY TERMS AND CONCEPTSSUMMARY 766PRACTICE SET 768755763765Review Questions 768Multiple Choice 769Exercises 775Appendix A ASCII Code777Appendix B Numbering Systems and TransformationB.1NUMBERING SYSTEMS783Decimal Numbers 784Binary Numbers 784Octal Numbers 785Hexadecimal Numbers 786B.2TRANSFORMATION787From Other Systems to Decimal 788From Decimal to Other Systems 789From Binary to Octal or Hexadecimal 789From Octal or Hexadecimal to Binary 790783xxiii

FM Page xxiv Wednesday, February 23, 2000 2:30 PMxxivTABLE OF CONTENTSAppendix C Representation of Binary NumbersC.1C.2791UNSIGNED NUMBERS 791SIGNED NUMBERS 792Sign-and-Magnitude 792One’s Complement 794Two’s Complement 795C.3MORE ABOUT ONE’S COMPLEMENT796Finding the Complement 796Adding Two Numbers 797Appendix D Fourier AnalysisD.1D.2FOURIER SERIES 800FOURIER TRANSFORMAppendix EE.1799802Hardware Equipment for Error DetectionELECTRONIC DEVICES803XOR Gate 803NOT Gate 804Shift Register 804E.2VERTICAL REDUNDANCY CHECK (VRC)805VRC Generator 805VRC Checker 805E.3LONGITUDINAL REDUNDANCY CHECK (LRC)806LRC Generator 806LRC Checker 806E.4CYCLIC REDUNDANCY CHECK (CRC)807The CRC Generator 807The CRC Checker 807Appendix FF.1F.2F.3Huffman Coding811CHARACTER TREE 812ASSIGNING THE CODES 815DECODING 816Appendix G LZW (Lempel-Ziv-Welch) CompressionMethodG.1COMPRESSION817817Dictionary 817Buffer 818Compression Algorithm 818Example of Compression 819G.2DECOMPRESSION820Dictionary 820Buffers 821Decompression Algorithm 821Decompression Example 821803

FM Page xxv Wednesday, February 23, 2000 2:30 PMTABLE OF CONTENTSAppendix H Next Generation of TCP/IP Protocol Suite: IPv6and ICMPv6H.1825IPv6 826IPv6 Addresses 826IPv6 Packet Format 831H.2ICMPv6836Appendix II.1Spanning TreeSPANNING TREES AND BRIDGESAlgorithm 841Forming the Spanning TreeExample 842I.2839842SPANNING TREES AND MULTICAST ROUTINGGlossary845AcronymsIndex839000877844xxv

FM Page xxvi Wednesday, February 23, 2000 2:30 PM

FM Page xxvii Wednesday, February 23, 2000 2:30 PMPrefaceData communications and networking may be the fastest growing technologies in ourculture today. One of the ramifications of that growth is a dramatic increase in the number of professions where an understanding of these technologies is essential forsuccess—and a proportionate increase in the number and types of students takingcourses to learn about them. Today, students wanting to understand the concepts andmechanisms underlying telecommunications and networking come from a variety ofacademic and professional backgrounds. To be useful, a textbook on data communications and networking must be accessible to students without technical backgroundswhile still providing substance comprehensive enough to challenge more experiencedreaders. This text is written with this new mix of students in mind.Features of the BookSeveral features of this text are designed to make it particularly easy for students tounderstand data communications and networking.StructureWe have used the seven-layer OSI model as the framework for the text not only becausea thorough understanding of the model is essential to understanding most current networking theory but also because it is based on a structure of interdependencies: Eachlayer builds upon the layer beneath it and supports the layer above it. In the same way,each concept introduced in our text builds upon the concepts examined in the previoussections.The OSI model was chosen because it is a model, not a protocol. The model isindependent of any protocol such as TCP/IP, IPX/SPX (Novell), or AppleTalk. Webelieve that in an introductory course, the model should be understood before the actualprotocols are discussed. The OSI model shows the layered architecture necessary forthe design of network systems.This text is designed for students with little or no background in telecommunication or data communication. For this reason, we use a bottom-up approach. In thisapproach, students can learn first about telecommunications (lower layers) beforelearning about data communications (upper layers). For example, students can learnxxvii

FM Page xxviii Wednesday, February 23, 2000 2:30 PMxxviiiPREFACEabout signalling, encoding, modulating, and error detection before learning about datatransfer across the Internet. This eliminates the need for two courses: One for telecommunications and one for data communications.The first nine chapters emphasize the physical layer, which is essential for understanding the rest of the layers. These chapters are particularly needed for students withno background in networking and telecommunications.Chapters 10 through 12 describe all issues related to local area networks. Chapter 13discusses metropolitan area networks. Chapter 14 describes switching techniques asbackground preparation for wide area networks.Chapters 15 to 20 discuss topics associated with wide area networks. Chapter 21discusses the network layer function and the topic of internetworking local and widearea networks together. Chapters 22 and 23 focus on upper layer protocols (transport,session, presentation, and application layers).Chapters 24 and 25 are dedicated to the TCP/IP protocol suite. These two chaptersgive a brief introduction and prepare the students for a course on the TCP/IP protocolsuite.Visual ApproachThe book presents highly technical subject matter without complex formulas by using abalance of text and figures. The approximately 700 figures accompanying the text provide a visual and intuitive opportunity for understanding the material. Figures are particularly important in explaining networking concepts, which are based on connectionsand transmission. These are both often more easily grasped visually than verbally.For example, Figure 3.8 shows the encapsulation of a network-layer packet in adata-link-layer frame. The figure also shows how network-layer addresses areunchanged compared to the data-link-layer addresses that change from station to station. Another figure, Figure 5.36, shows how an 8-QAM signal can carry three bits ineach baud. Figure 8.4 clearly shows how FDM combines three modulated signals intoone composite signal. Figures 25.3, 25.4, 25.5, and 25.6 show how the domain namesystem is divided into three domains: country, generic, and inverse domains.Highlighted PointsWe have repeated important concepts in boxes for quick reference and immediateattention.Examples and ApplicationsWhenever appropriate, we have included examples that illustrate the concept introduced in the text. They also help students do the exercises at the end of each chapter.Also, we have added real-life applications throughout each chapter. For example,in Chapter 8, after a discussion of FDM, we give an application, the analog hierarchy ofthe telephone system. Similarly, after discussion of TDM, we give an application, theDS hierarchy of the telephone system.SummaryEach chapter ends with a summary of the material covered in that chapter. The summary is a brief overview of all the important points in the chapter.

FM Page xxix Wednesday, February 23, 2000 2:30 PMPREFACExxixKey TermsEach chapter includes a list of key terms used throughout the chapter for a quickreference.Practice SetEach chapter includes a practice set designed to reinforce salient concepts and encourage students to apply them. It consists of three parts: review questions, multiple-choicequestions, and exercises. Review questions are intended to test students for their firstlevel understanding of the material presented in the chapter. Multiple-choice questionstest students’ grasp of basic concepts and terminology. Exercises require deeper understanding of the material.AppendixesThe appendixes are intended to provide quick reference material or a review of materials needed to understand the concepts discussed in the book.Glossary and AcronymsThe book contains an extensive glossary and a list of acronyms.Changes in the Second EditionIn this edition, material on the newer technologies has been added, the contents of thechapters have been revised, and the end materials have been augmented and improved.New MaterialWe have added the following new material: 56K modems and cable modems (Chapter 6). Transmission impairment and transmission media performance (Chapter 7). Digital subscriber line (DSL) technology and fiber to the curb (FTTC) (Chapter 8). Switched and Gigabit Ethernet (Chapter 12). Point-to-Point Protocol (PPP) (Chapter 15). Traffic control (Chapter 18). Switching fabrics and ATM LANs (Chapter 19). Additional encryption methods (Chapter 23). Lempel-Ziv-Welch compression method (Appendix G). Spanning Tree algorithm (Appendix I).RevisionAll chapters have been revised, particularly Chapters 4, 9, 18, and 19 and Appendix H.End Material Augmentation and Improvement Several examples are added to many chapters to clarify the materials. Key terms are added at the end of each chapter.

FM Page xxx Wednesday, February 23, 2000 2:30 PMxxxPREFACE Review questions are added at the end of each chapter.The quality and quantity of the multiple-choice questions have been improved.The quality and quantity of the exercises have been improved. Most of the oldexercises have been revised and many exercises have been added.Online Supplementary MaterialOnline Learning CenterThe McGraw-Hill Online Learning Center is a “digital cartridge” that contains thebook’s pedagogy and supplements. As students read through Data Communicationsand Networking, they can go online to take self-grading quizzes. They also get appropriate access to lecture materials such as PowerPoint slides and animated figures fromthe book. Solutions are also available to instructors through this site.Additionally, McGraw-Hill makes it easy to create a website for your networkingcourse with an exclusive McGraw-Hill product called Pageout. It requires no priorknowledge of HTML, no long hours, and no design skills on your part. Instead, Pageout offers a series of templates. Simply fill them with your course information and clickon one of 16 designs. The process takes under an hour and leaves you with a professionally designed website.Although PageOut offers “instant” development, the finished website offers powerful features. An interactive course syllabus allows you to post content to coincidewith your lectures, so when students visit your PageOut website, your syllabus willdirect them to components of Forouzan’s Online Learning Center, or specific materialof your own.How to Use the BookThis book is written for both an academic and a professional audience. The book can beused as a self-study guide for interested professionals. As a textbook, it can be used fora one-semester or one-quarter course. The chapters are organized to provide a greatdeal of flexibility. The following are some guidelines: Chapters 1 through 12 are fundamental. Chapter 13 is optional. Chapters 14 through 18 can be covered in detail for a semester course or briefly fora quarter course. Chapters 19 through 25 are fundamental.AcknowledgmentsIt is obvious that the development of a book of this scope needs the support of manypeople. We must thank the De Anza students and staff; their encouragement and support enabled the project to materialize and contributed to its success. We especiallythank Claudia Gohler and Anastasia Mazharina for their tremendous assistance in preparing solutions to the end materials.

FM Page xxxi Wednesday, February 23, 2000 2:30 PMPREFACExxxiThe most important contribution to the development of a book such as this comesfrom peer reviews. We cannot express our gratitude in words to the many reviewerswho spent numerous hours reading the manuscript and providing us with

3.3 TCP/IP PROTOCOL SUITE 56 3.4 KEY TERMS AND CONCEPTS 57 3.5 SUMMARY 58 3.6 PRACTICE SET 59 Review Questions 59 Multiple Choice 60 Exercises 63 Chapter 4 Signals 65 4.1 ANALOG AND DIGITAL 65 Analog and Digital Data 66 Analog and Digital Signals 66 4.2 APERIODIC AND PERIODIC