Sie sind auf Seite 1von 162

Networking Basics

2009, Velocis Systems

How a LAN Is Built

2009, Velocis Systems

Local-Area NetworkLAN
What is a LAN?
A collection of computers, printers, and other devices that can communicate with each other in a small area.

What are the components?


Computers, operating system (OS), network interface card (NIC), and hubs

How is a LAN controlled?


ProtocolsFormal descriptions of sets of rules and conventions that govern how devices on a network exchange information
Networking Fundamentals 2009, Velocis Systems 1-3

Local-Area Networks
LANs are designed to:
Operate within a limited geographic area Allow multi-access to high-bandwidth media Control the network privately under local administration Provide full-time connectivity to local services Connect physically adjacent devices

Networking Fundamentals

2009, Velocis Systems

1-4

Network Operating System (OS)

Software that allows communicating and sharing of data and network resources Examples:
AppleTalk NetWare Win NT

PC or Workstation Loaded with NOS

Networking Fundamentals

2009, Velocis Systems

1-5

Network Interface Card


Amplifies electronic signals Packages data for transmission Physically connects computer to transmission media (cable)
Connector Port

PC or Workstation Loaded with NOS

Network Interface Card (NIC)


Networking Fundamentals 2009, Velocis Systems 1-6

1990sGlobal Internetworking

19921 major backbone, 3,000 networks, 200K computers 1995Multiple backbones, hundreds of regional nets, tens of thousands of LANs, millions of hosts, tens of millions of users

Doubling every year!


Networking Fundamentals 2009, Velocis Systems 1-7

The OSI Model


OSI Layer is meant for Networking manufacturers and developers to provide them a standard based on which they can make their products. All OSI Layers are independent from each other, which makes introducing changes easier as no other layers are effected. Ease of Troubleshooting.
Networking Fundamentals 2009, Velocis Systems 1-8

The Layered Model

2009, Velocis Systems

Why a Layered Network Model?


7 6 5 4 3 2 1 Application Presentation Session Transport Network Data Link Physical

Reduces complexity (one big problem to seven smaller ones) Standardizes interfaces Facilitates modular engineering Assures interoperable technology Accelerates evolution Simplifies teaching and learning

Networking Fundamentals

2009, Velocis Systems

1-10

Devices Function at Layers


7 6
NIC Card

Application Presentation Session

4 3 2 1

Transport Network Data Link Physical


Hub

Networking Fundamentals

2009, Velocis Systems

1-11

Host Layers
7 6 5 4 Application Presentation Session Transport Network 3 Data Link

Host layers: Provide


accurate data delivery between computers

Physical

Networking Fundamentals

2009, Velocis Systems

1-12

Media Layers
7 6 5 4 Transport 3 2 1 Network Data Link Physical Application Presentation Session

Host layers: Provide


accurate data delivery between computers

Media layers: Control


physical delivery of messages over the network

Networking Fundamentals

2009, Velocis Systems

1-13

Layer Functions
7 Application
Provides network services to application processes (such as electronic mail, file transfer, and terminal emulation)

Networking Fundamentals

2009, Velocis Systems

1-14

Layer Functions
7 6 Application Presentation Network services to applications Data representation Ensures data is readable by receiving system Format of data Data structures Negotiates data transfer syntax for application layer

Networking Fundamentals

2009, Velocis Systems

1-15

Layer Functions
7 6 5 Application Presentation Session Network services to applications Data representation Inter-host communication Establishes, manages, and terminates sessions between applications

Networking Fundamentals

2009, Velocis Systems

1-16

Layer Functions
7 6 5 4 Application Presentation Session Transport Network services to applications Data representation Inter-host communication End-to-end connection reliability
Concerned with data transport issues between hosts Data transport reliability Establishes, maintains, and terminates virtual circuits Fault detection and recovery Information flow control

Networking Fundamentals

2009, Velocis Systems

1-17

Layer Functions
7 6 5 4 3 Application Presentation Session Transport Network Network services to applications Data representation Inter-host communication End-to-end connection reliability Addresses and best path
Provides connectivity and path selection between two end systems Domain of routing

Networking Fundamentals

2009, Velocis Systems

1-18

Layer Functions
7 6 5 4 3 2 Application Presentation Session Transport Network Data Link Network services to applications Data representation Inter-host communication End-to-end connection reliability Addresses and best path Access to media
Provides reliable transfer of data across media Physical addressing, network topology, error notification, flow control
Networking Fundamentals 2009, Velocis Systems 1-19

Layer Functions
7 6 5 4 3 2 1 Application Presentation Session Transport Network Data Link Physical Network services to applications Data representation Inter-host communication End-to-end connection reliability Addresses and best path Access to media Binary transmission Wires, connectors, voltages, data rates
2009, Velocis Systems 1-20

Networking Fundamentals

Peer-to-Peer Communications
Host A 7 6 5 4 3 2 1 Application Presentation Session Transport Network Data Link Physical Segments Packets Frames Bits Host B Application Presentation Session Transport Network Data Link Physical

Networking Fundamentals

2009, Velocis Systems

1-21

Application Layer
This is where users communicate to the computer. This is where communication between two users are established. This is a point where user or application interfaces with the protocols to gain access to the network. Examples are WWW, Telnet, FTP, TFTP, E-mail, SNMP, DNS
Networking Fundamentals 2009, Velocis Systems 1-22

Presentation Layer
Tasks like Translation, Encryption, decryption, compression, decompression are associated with this layer. It receives the data in native format & converts in standard format or receives data in standard format and converts in native format, ie. EBCDIC to ASCII. It is mainly responsible for how the data is to be presented to the Application Layer. Examples are PICT, TIFF, JPEG, MIDI, MPEG, GIFF etc.
Networking Fundamentals 2009, Velocis Systems 1-23

Presentation Layer

login:

Text Data
ASCII EBCDIC Encrypted

Graphics Visual images


PICT TIFF JPEG GIF

Sound
MIDI

Video
MPEG QuickTime

Provides code formatting and conversion for applications


Networking Fundamentals 2009, Velocis Systems 1-24

PROTOCOLS OF PRESENTATION LAYER


PICT: This is picture format used by Macintosh or power PC program for transferring quick draw graphics. TIFF: Tagged image file format is a standard graphic format for high resolution, bitmapped images. JPEG: the joint photographic express group brings this photo standard to us. MIDI: the musical instrument digital interface is used for digitized music. Other standard guide movies and sound: MPEG: the moving picture experts groups standard for the compression and coding of motion video for the CDs increasingly popular. It provides digital storage and rates up to 1.5 Mbps. Quick time: this for use with Macintosh or PowerPC programs; it manages audio and video application.
Networking Fundamentals 2009, Velocis Systems 1-25

Session Layer

Session Establishment Establishes a session between two devices before actual transmission of data. Dialog Control Simplex Half Duplex Full Duplex

Networking Fundamentals

2009, Velocis Systems

1-26

Session Layer
Simplex Data travels only one way. Radio transmission is the best example of this.

Half Duplex Both way but one at a time. By default all LAN Cards (NICs) work on Half Duplex.

Full Duplex Both way at the same time.

Networking Fundamentals

2009, Velocis Systems

1-27

Session Layer
Network File System (NFS) Structured Query Language (SQL) Remote-Procedure Call (RPC) X Window System AppleTalk Session Protocol (ASP) DEC Session Control Protocol (SCP)

Service Request Service Reply

Coordinates applications as they interact on different hosts


Networking Fundamentals 2009, Velocis Systems 1-28

SESSION LAYER PROTOCOLS


Network File System (NFS): Was developed by Sun Microsystems and used with TCP/IP and Unix workstations to allow transparent access to remote resources. Structured Query Language (SQL): Was developed by IBM to provide users with a simple way to define their information requirements on both local and remote systems. Remote Procedure Call (RPC): A board client/server redirection tool used for disparate service environments. Its procedure are created on client and performed on servers. X Windows: Is widely used by intelligent terminals for communicating with remote Unix computers, allowing them as though they were locally attached monitors. Apple Talk special Protocol (ASP): Is another client /server mechanism, which both establishes and maintains session talks between apples talk client and sever machines. Digital Network Architecture Session control protocol (DNA SCP): Is DEC net session layer protocol
Networking Fundamentals 2009, Velocis Systems 1-29

Transport Layer
Segments upper-layer applications Establishes an end-to-end connection Sends segments from one end host to another Optionally, ensures data reliability

Networking Fundamentals

2009, Velocis Systems

1-30

Transport Layer
Transport Layer never actually transports the data but only prepares for transporting. Uses Socket to define the services running on a particular node, the data is associated with. Responsible for the following : Segmentation End-to-end Communication Flow Control Error Control Multiplexing of Applications TCP, UDP and SPX work at this layer
Networking Fundamentals 2009, Velocis Systems 1-31

Socket
Socket is a software component and points to a particular service running on a particular node. Structure of a socket IP Address + Port Address Each service has a unique Port address Max. Port Addresses can be 65,536 Port address 1-1023 is reserved for specific Services like WWW FTP SMTP 80 21 25

Port Addresses are reserved for standardization purpose.


Networking Fundamentals 2009, Velocis Systems 1-32

Port Numbers

Application Layer

F T P

T E L N E T
23 TCP

S M T P

D N S

T F T P

S N M P

R I P

21 Transport Layer
Networking Fundamentals

25

53

69
UDP

161

520

Port Numbers

2009, Velocis Systems

1-33

Segmentation
This is a mechanism wherein the data is divided into multiple segments and sent over the network. By doing this different segments can use different links for travelling across the network. If one segment is lost the only segment is required to be re-sent and not the entire data. Once all segments reach to the destination the received segments have to be sequenced back, which is also done at this layer.

Networking Fundamentals

2009, Velocis Systems

1-34

Transport Layer
Sends Segments with Flow Control
Transmit
Sender Receiver

Stop

Not Ready

Buffer Full Process Segments

Go

Ready Resume Transmission

Buffer OK

Networking Fundamentals

2009, Velocis Systems

1-35

Flow Control
Used while connection oriented communication It helps to have a control on over flow of Buffer. Advantages are: The segments delivered are acknowledged if received Any segment not acknowledged are retransmitted segments are sequenced back upon their arrival Congestion, Overloading and data loss are avoided To achieve all this it uses the technique of Sliding window or Windowing
Networking Fundamentals 2009, Velocis Systems 1-36

Transport Layer
Establishes Connection

Sender

Receiver

Synchronize Negotiate Connection Synchronize Acknowledge

Connection Established
Data Transfer (Send Segments)

Networking Fundamentals

2009, Velocis Systems

1-37

End-to-End Communication
Connection Less Transmission
UDP is used Not reliable Faster

Connection Oriented Transmission


TCP or SPX is used Reliable Slower
Networking Fundamentals 2009, Velocis Systems 1-38

Connection Oriented Protocol


These protocols relies on Acknowledgement. Positive acknowledgement means data has been received. Negative acknowledgement means data is lost no further data is sent till positive acknowledgement is received. It is slow but Reliable. Eg. TCP and SPX
Networking Fundamentals 2009, Velocis Systems 1-39

Transport Layer
Reliability with Windowing
Window Size = 1 Send 1
Sender

Receive 1 Ack 2 Receive 2 Ack 3 Window Size = 3


Receiver

Send 2

Sender

Send 1 Send 2 Send 3 Send 4

Receive 1 Receive 2 Receive 3 Ack 4

Receiver

Networking Fundamentals

2009, Velocis Systems

1-40

Transport Layer
An Acknowledgement Technique

Sender

Receiver

1 2 3 4 5 6 7
Send 1 Send 2 Send 3

1 2 3 4 5 6 7

Ack 4 Send 4 Send 5 Send 6 Ack 5 Send 5 Ack 7


Networking Fundamentals 2009, Velocis Systems 1-41

Connection Less Protocol


They do not provide acknowledgement neither sequence numbers. It is faster but not reliable Eg. UDP

Networking Fundamentals

2009, Velocis Systems

1-42

Network Layer

It is responsible for communicating Networks It recognizes Networks with the help of Netwok Addresses Network Address is a logical address like IP Address or IPX Address It is common for a group of computers It works only with Network IDs and has got nothing to do with host Ids. Path determination or Routing is performed at this layer. Router works at this layer.

Networking Fundamentals

2009, Velocis Systems

1-43

Network Layer: Path Determination

Which Which Path? Path?

Layer 3 functions to find the best path through the internetwork


Networking Fundamentals 2009, Velocis Systems 1-44

Network Layer: Communicate Path

2 4 1 3

5 6 8

9 10 7

11

Addresses represent the path of media connections

Networking Fundamentals

2009, Velocis Systems

1-45

Protocol Addressing Variations


General Example
Network 1 Node 1

TCP/IP Example

Network 10.

Host 8.2.48 (Mask 255.0.0.0)

Novell IPX Example


Networking Fundamentals

Network 1aceb0b.

Node 0000.0c00.6e25
2009, Velocis Systems 1-46

Network Layer Protocol Operations


X
A A C C

Each router provides its services to support upper layer functions

Networking Fundamentals

2009, Velocis Systems

1-47

Routed Versus Routing Protocol


Routed protocol used between routers to direct user traffic Examples: IP, IPX, AppleTalk Routing protocol used only between routers to maintain routing tables Examples: RIP, IGRP, OSPF
Networking Fundamentals 2009, Velocis Systems 1-48

Static Versus Dynamic Routes


Static Route Uses a protocol route that a network administrator enters into the router

Dynamic Route Uses a route that a network protocol adjusts automatically for topology or traffic changes

Networking Fundamentals

2009, Velocis Systems

1-49

Static Route Example

A A

Point-to-point or circuit-switched connection

Only a single network connection with no need for routing updates

B B Stub network

Fixed route to address reflects administrators knowledge


Networking Fundamentals

2009, Velocis Systems

1-50

Adapting to Topology Change

A A

B B

D D

C C

Can an alternate route substitute for a failed route?


Networking Fundamentals 2009, Velocis Systems 1-51

Adapting to Topology Change

A A

B B

X
D D C C

Networking Fundamentals

2009, Velocis Systems

1-52

Adapting to Topology Change

A A

B B

X
D D C C

Can an alternate route substitute for a failed route? YesWith dynamic routing enabled Yes
Networking Fundamentals 2009, Velocis Systems 1-53

Data Link Layer


It uniquely identifies each device in the Network. It translates data from Network Layer into bits for the Physical layer to transmit. It formats the messages into Data Frames Adds a customized header containing Source and Destination hardware address This layer works with Frames This layer is logically divided in two sub-layers: LLC (Logical Link Control) MAC (Media Access Control)
Networking Fundamentals 2009, Velocis Systems 1-54

DATA LINK LAYER

1) 2) 3) 4)

FUNCTIONS OF ETHERNET Arbitration: CSMA/CD algos Addressing: 6 byte-long MAC address Error detection: FCS in Ethernet trailer Identify the type of packet inside the frame

Networking Fundamentals

2009, Velocis Systems

1-55

Physical Layer
Electrical and Mechanical settings are provided at this layer. Transmits data in the form of bits. This layer communicates directly with actual communication media. At this layer DCE & DTE are identified DCE (Data Circuit-Terminating Equipment) Located at Service Providers side DTE (Data Terminal Equipment) The attached device at customer Place eg. Modem Services available to a DTE is most often accessed via a Modem or Channel Service Unit (CSU) Data Service Unit (DSU). HUBs & REPEATERS are working at this layer. Max. troubleshooting occurs at this layer.
2009, Velocis Systems 1-56

Networking Fundamentals

DOD MODEL

2009, Velocis Systems

The DoD

Model

The Process / Application Layer The Host-to-Host Layer The Internet Layer The Network Layer
Networking Fundamentals 2009, Velocis Systems 1-58

The DoD & OSI


DoD Model Application Host-to-Host Internet Network Access
Networking Fundamentals

OSI Model Application Presentation Session Transport Network Data Link Physical
2009, Velocis Systems 1-59

Process/Application Layer
The Process / Application layer defines protocols for node-to-node application communication and also controls userinterface specification. A vast array of protocols combine at this layer of DoDs Model to integrate the activities and duties of upper layer of OSI. Examples for this layer are : Telnet, FTP, TFTP, NFS, SMTP, SNMP, DNS DHCP, BootP etc.
Networking Fundamentals 2009, Velocis Systems 1-60

Host-to-Host Layer
The Host-to-Host layer parallels the functions of the OSIs Transport layer It performs the following: Defining protocols for setting up the level of transmission service for Applications It tackles issues like creating reliable ene-to-end communication. It ensures the error free delivery of data It handles packet sequencing and maintains data integrity.
Networking Fundamentals 2009, Velocis Systems 1-61

Internet Layer
Internet Layer corresponds to the OSIs Network Layer. It performs the following: Designating the protocols relating to the logical transmission of packets over the entire network. It takes care of the addressing of hosts by giving them an IP address. It handles routing of packets among multiple networks.
Networking Fundamentals 2009, Velocis Systems 1-62

Network Access Layer


This layer is equivalent of the Data Link and Physical Layer of OSI model. It performs the following It monitors the data exchange between the host and the network. Network Access Layer overseas hardware addressing and defines protocols for the physical transmission of the Data. Lets have a look on how TCP/IP Protocol suit relates to the DoD model layers.
Networking Fundamentals 2009, Velocis Systems 1-63

TCP/IP Protocol Suit at DoD


DoD Model Process / Application Host-to-Host
ICMP Telnet TFTP

TCP/IP Protocol Suit


FTP SMTP TCP BootP IP
Ethernet Fast Ethernet Token Ring

LPD NFS

SNMP X Window UDP

ARP

RARP

Internet Network Access


Networking Fundamentals

FDDI
2009, Velocis Systems 1-64

Ethernet

2009, Velocis Systems

Introduction
Ethernet is a methodology for accessing a media It allows all hosts on a network to share the same bandwidth of a link. It is popular because : It is easy to implement & Troubleshoot It is easy to add new technologies like Fast Ethernet and Gigabit Ethernet to existing infrastructure. Ethernet uses Data Link Layer and Physical Layer Specification It uses something called
Networking Fundamentals

CSMA/CD
2009, Velocis Systems 1-66

Ethernet Operation
A B C D

Networking Fundamentals

2009, Velocis Systems

1-67

Ethernet Operation
A B C D

D
Application Presentation Session Transport Network Data Link Physical

Networking Fundamentals

2009, Velocis Systems

1-68

Ethernet Operation
A B C D

D
Application Presentation Session Transport Network Data Link Physical

B and C
Application Presentation Session Transport Network Data Link Physical

Networking Fundamentals

2009, Velocis Systems

1-69

Ethernet LANs: How do they work?


Multiple workstations are connected to a segment Each station has to take turns sending traffic All stations listen to all traffic on their segment Stations can only send data (Ethernet Frames) when no one else is sending
Networking Fundamentals 2009, Velocis Systems 1-70

Ethernet LANs: MAC Addresses


0000.0c12.3456

0000.1018.321a

0000.0c12.1111

Every workstation has a Network Interface Card (NIC) Every NIC has a unique MAC address Stations use MAC addresses to send Ethernet Frames to a specific station

Networking Fundamentals

2009, Velocis Systems

1-71

Ethernet LANs: Unicast Frames


0000.0c12.3456

Frame To: 0000.0c12.3456

0000.1018.321a

0000.0c12.1111

Ethernet frames contain the MAC address of the station that the frame was sent to These are called unicast frames All stations receive the Ethernet frame, but ignore the frames that are not addressed to their MAC address
2009, Velocis Systems 1-72

Networking Fundamentals

Ethernet LANs: Broadcast Frames


0000.0c12.3456

Frame To: FFFF.FFFF.FFFF

Some Ethernet frames are sent to all stations These are called broadcast frames All stations process this frame

0000.1018.321a

0000.0c12.1111

Networking Fundamentals

2009, Velocis Systems

1-73

Ethernet LANs: Broadcast Frames


0000.0c12.3456

Frame To: FFFF.FFFF.FFFF

Some Ethernet frames are sent to all stations These are called broadcast frames All stations process this frame

0000.1018.321a

0000.0c12.1111

Networking Fundamentals

2009, Velocis Systems

1-74

Ethernet Collisions
Collision!
Packe Frame Packe Frame t t

Frame

Packet

Frame

Packet

Sometimes stations transmit simultaneously Two frames on the same segment collide Collisions require each station to wait and resend

Networking Fundamentals

2009, Velocis Systems

1-75

Ethernet Reliability
A
Figure 1

A
Figure 2

Collision
Networking Fundamentals 2009, Velocis Systems 1-76

Ethernet Reliability
A B C D

Collision

JAM

JAM

JAM

JAM

JAM

JAM

Networking Fundamentals

2009, Velocis Systems

1-77

Ethernet Reliability
A B C D

Collision

JAM

JAM

JAM

JAM

JAM

JAM

Carrier sense multiple access with collision detection (CSMA/CD)


Networking Fundamentals 2009, Velocis Systems 1-78

CSMA/CD
CSMA/CD stands for Carrier Sense Multiple Access / Collision Detect.

It is used by all NICs in Ethernet Networking

In this method all NICs first sense whether the cable is free or not.

If it is free the request is sent otherwise it waits.


Networking Fundamentals 2009, Velocis Systems 1-79

Half Duplex Ethernet


It is defined in 802.3 Ethernet specifications It uses only one wire pair for signals running in both direction. CSMA/CD is used to prevent collision. Half Duplex typically 10base T is 50-60 % efficient. (In CISCO views) In a large 10 base T network you only get 3 to 4 MBPS at most.
Networking Fundamentals 2009, Velocis Systems 1-80

Full Duplex
Full Duplex Ethernet uses two pairs of wires. It uses Point-to-Point connection There is no collision in Full Duplex Full Duplex is suppose to offer 100% efficiency in both direction Means you can get 20 MBPS in 10 MBPS or 200 MBPS in Fast Ethernet running Full Duplex.
Networking Fundamentals 2009, Velocis Systems 1-81

Ethernet Addressing
Ethernet Addressing uses MAC Address MAC addresses are burned on every NIC It is a 48-bit address It is written in the same format even if different LAN Technologies are used. 24 bits 24 bits

Organizationally Unique Identifier (OUI) (Assigned by IEEE)


Ethernet Addressing using MAC Addresses
Networking Fundamentals

Vender Assigned

2009, Velocis Systems

1-82

Ethernet and IEEE 802.3

Benefits and background


Ethernet is the most popular physical layer LAN technology because it strikes a good balance between speed, cost, and ease of installation Supports virtually all network protocols Xerox initiated, then joined by DEC & Intel in 1980

Revisions of Ethernet specification


Fast Ethernet (IEEE 802.3u) raises speed from 10 Mbps to 100 Mbps Gigabit Ethernet is an extension of IEEE 802.3 which increases speeds to 1000 Mbps, or 1 Gbps

Networking Fundamentals

2009, Velocis Systems

1-83

Ethernet and IEEE 802.3

Several framing variations exist for this common LAN technology

Networking Fundamentals

2009, Velocis Systems

1-84

Ethernet Frames

Frames are used at the Data Link Layer to encapsulate packets coming down for transmission on a type of Media Access Types of Media Access
Contention (Ethernet) Token Passing (Token Ring or FDDI)
We will be covering only Contention, as rest all are beyond the scope of our course.

Networking Fundamentals

2009, Velocis Systems

1-85

LAN FUNDAMENTALS

Ethernet It is a LAN protocol. Given by Xerox in early 1970s. Three companies modified it as E (II) DEC, Intel & Xerox (DIX). IEEE made it standard as 802.3 Header of Ethernet 8bytes 6byts 6byts 2 byts variable 4byts
Flag DA SA TYPE DATA Flag

Networking Fundamentals

2009, Velocis Systems

1-86

MAC SUB-LAYER
MAC Layer - 802.3
# Bytes 8 6 6 2 Length Variable Data 4 FCS Preamble Dest add Source add

0000.0C
IEEE assigned

xx.xxxx
Vendor assigned

Ethernet II uses Type here and does not use 802.2.

MAC Address
Networking Fundamentals 2009, Velocis Systems 1-87

Preamble
It allows the receiving devices to lock the incoming bit stream. The Peamble is used to indicate to the receiving station that the data portion of the message will follow.

Networking Fundamentals

2009, Velocis Systems

1-88

Destination Address (DA)


DA is used by receiving stations to determine if an incoming packet is addressed to a particular node. Uses LSB (Least Significant Bit) first Destination can be individual, multicast or broadcast
Broadcast will be all 1s or Fs and will be sent to all. Multicast will be sent to the specific subnet
Networking Fundamentals 2009, Velocis Systems 1-89

Source Address (SA)

SA is a 48 bit MAC Address supplied by the transmitting device. Broadcast and Multicast address formats are illegal within the SA fields. It uses LSB (Least significant bit first)
Networking Fundamentals 2009, Velocis Systems 1-90

Length or Type Field

802.3 uses length field where as Ethernet frame uses type field to identify the network layer protocol.

802.2 can identify upper-layer protocol and must be used with 802.3 frame.

Networking Fundamentals

2009, Velocis Systems

1-91

Data

This is the packet sent down to the Data Link Layer from the Network layer.

The size can vary from 46-1500 bytes.


Networking Fundamentals 2009, Velocis Systems 1-92

Frame Check Sequence (FCS)

FCS is a field at the end of the frame that is used to store the cyclic redundancy check.

Networking Fundamentals

2009, Velocis Systems

1-93

Data Link Layer Functions (cont.)


802.2 (SNAP)
# Bytes 1 1 1 or 2 3 2 Variable

Dest SAP Source SAP Ctrl OUI Type ID AA AA 03

Data

OR
# Bytes 1 1

802.2 (SAP)
1 or 2 Variable

Dest SAP

Source SAP

Ctrl

Data

Preamble Dest add Source add Length

Data

FCS

MAC Layer - 802.3


Networking Fundamentals 2009, Velocis Systems 1-94

802.2 Frame
802.2 Frame has two new fields
DSAP (Destination Service Access Pointer) SSAP (Source Service Access Pointer)

802.2 frame type is nothing but 802.3 frame with LLC information Because of the LLC information we know what upper layer protocol is.
Networking Fundamentals 2009, Velocis Systems 1-95

SNAP Frame
The SNAP Frame has its own protocol field to identify the upper layer protocol. To Identify SNAP Frame: DSAP and SSAP fields are always AA to indicate that this is a SNAP header coming up. it is an LLC data unit (sometimes called a Logical Protocol Data Unit (LPDU)) of Type 1 (indicated by 03) The SNAP header then indicates the vender via the Organisational Unique Identifier (OUI) and the protocol type via the Ethertype field CISCO uses SNAP frame with their proprietary protocol CDP (CISCO Discovery Protocol)
Networking Fundamentals 2009, Velocis Systems 1-96

EXAMPLE - SNAP

In the example above we have the OUI as 00-00-00 which means that there is an Ethernet frame, and the Ethertype of 08-00 which indicates IP as the protocol.

Networking Fundamentals

2009, Velocis Systems

1-97

ETHERNET CABLING

2009, Velocis Systems

Network Cabling
Media connecting network components
NIC cards take turns transmitting on the cable LAN cables only carry one signal at a time WAN cables can carry multiple signals simultaneously

Three primary types of cabling


Twisted-pair (or copper) Coaxial cable Fiber-optic cable
Networking Fundamentals 2009, Velocis Systems 1-99

Twisted-Pair (UTP and STP)


STP only: Shielded Insulation to Reduce EMI Twisted-Pair Outer Jacket Color-Coded Plastic Insulation

Speed and throughput: Relative cost: Maximum cable length:


Networking Fundamentals

10/100 Mbps Least costly 100 m

RJ-45 Connector

Media and connector size: Small

2009, Velocis Systems

1-100

Coaxial Cable
OuterJacket Braided Copper Shielding Plastic Insulation Copper Conductor

BNC Connector

Speed and throughput: Relative cost: Media and connector size: Maximum cable length:
Networking Fundamentals

10/100 Mbps More than UTP, but still low Medium 200/500 m
2009, Velocis Systems 1-101

Fiber-Optic Cable
Outer Jacket Kevlar Reinforcing Material Plastic Shield Glass Fiber and Cladding

Speed and throughput: Average cost per node: Media and connector size: Maximum cable length:

100+ Mbps Most expensive Small Up to 2 km

Networking Fundamentals

2009, Velocis Systems

1-102

UPPER LAYER PROTOCOLS

2009, Velocis Systems

What Is TCP/IP?

A suite of protocols Rules that dictate how packets of information are sent across multiple networks Addressing Error checking

Networking Fundamentals

2009, Velocis Systems

1-104

TCP/IP Protocol
The Transmission Control Protocol/Internet Protocol (TCP/IP) suit was created by the Department of Defense (DoD). The Internet Protocol can be used to communicate across any set of interconnected networks. TCP/IP supports both LAN and WAN communications. IP suite includes not only Layer 3 and 4 specifications but also specifications for common applications like email, remote login, terminal emulation and file transfer. The TCP/IP protocol stack maps closely to the OSI model in the lower layers.
Networking Fundamentals 2009, Velocis Systems 1-105

The DoD & OSI


DoD Model Application Host-to-Host Internet Network Access
Networking Fundamentals

OSI Model Application Presentation Session Transport Network Data Link Physical
2009, Velocis Systems 1-106

TCP/IP Protocol Suit at DoD


DoD Model Process / Application Host-to-Host
ICMP Telnet TFTP

TCP/IP Protocol Suit


FTP SMTP TCP BootP IP ARP LPD NFS UDP RARP SNMP

Internet Network Access


Networking Fundamentals

Ethernet

Fast Ethernet

Token Ring

FDDI
2009, Velocis Systems 1-107

TCP/IP Applications
Application layer
File Transfer Protocol (FTP) Remote Login (Telnet) E-mail (SMTP)

Transport layer
Transport Control Protocol (TCP) User Datagram Protocol (UDP)

Network layer
Internet Protocol (IP)

Data link & physical layer


LAN Ethernet, Token Ring, FDDI, etc. WAN Serial lines, Frame Relay, X.25, etc.
Networking Fundamentals 2009, Velocis Systems 1-108

Internet Layer Overview

Internet Internet Protocol Protocol (IP) (IP)


Application Transport Internet Data-Link Physical

Internet Internet Control Control Message Message Protocol Protocol (ICMP) (ICMP) Address Address Resolution Resolution Protocol Protocol (ARP) (ARP) Reverse Reverse Address Address Resolution Resolution Protocol Protocol (RARP) (RARP)

In the OSI reference model, the network layer corresponds to the TCP/IP Internet layer.

Networking Fundamentals

2009, Velocis Systems

1-109

Internet Protocol
Provides connectionless,best effort delivery routing of datagrams. IP is not concerned with the content of the datagrams. It looks for a way to move the datagrams to their destination.
Networking Fundamentals 2009, Velocis Systems 1-110

IP Datagram
Bit 1 0
Version (4) Header Length (4)

Bit 15 Type of Service (8)

Bit 16 Total Length (16) Flags (3)

Bit 31

Identification (16) Time-to-Live (8) Protocol (8)

Fragment Offset (13) Header Checksum (16) 20 Bytes

Source IP Address (32) Destination IP Address (32) Options (0 or 32 if Any) Data (Varies if Any)
Networking Fundamentals 2009, Velocis Systems 1-111

IP Datagram
Version Currently used IP version Header Length Datagram header length TOS Level of importance assigned by a particular upper-layer protocol Total Length- Length of packet in bytes including Data and Header Identification Identifies current datagram (Sequence Number) Flags Specifies whether the packet can be fragmented or not Fragment Offset Used to piece together datagram fragments TTL It maintains a counter that gradually decreases, in increments, to zero Protocol It indicates which upper-layer protocol receives incoming packets Header Checksum Calculated checksum of the header to check its integrity Source IP Address Sending node IP Address Destination IP Address Receiving node IP Address Options It allows IP to support various options like security
Networking Fundamentals

Data Upper layer information (maximum 64Kb)

2009, Velocis Systems

1-112

Protocol Field

Transport Layer

TCP 6

UDP 17 IP Protocol Numbers

Internet Layer

Determines destination upper-layer protocol


Networking Fundamentals 2009, Velocis Systems 1-113

Address Resolution Protocol (ARP)


ARP works at Internet Layer of DoD Model It is used to resolve MAC address with the help of a known IP address. All resolved MAC addresses are maintained in ARP cache table is maintained. To send a datagram this ARP cache table is checked and if not found then a broadcast is sent along with the IP address. Machine with that IP address responds and the MAC address is cached.
Networking Fundamentals 2009, Velocis Systems 1-114

Address Resolution Protocol


I need the Ethernet address of 176.16.3.2.

172.16.3.1

172.16.3.2

IP: IP: 172.16.3.2 172.16.3.2 = = ??? ???

Networking Fundamentals

2009, Velocis Systems

1-115

Address Resolution Protocol


I need the Ethernet address of 176.16.3.2. I heard that broadcast. The message is for me. Here is my Ethernet address. 172.16.3.1 172.16.3.2

IP: IP: 172.16.3.2 172.16.3.2 = = ??? ???

Networking Fundamentals

2009, Velocis Systems

1-116

Address Resolution Protocol


I need the Ethernet address of 176.16.3.2. I heard that broadcast. The message is for me. Here is my Ethernet address. 172.16.3.1 172.16.3.2

IP: IP: 172.16.3.2 172.16.3.2 = = ??? ??? IP: IP: 172.16.3.2 172.16.3.2 Ethernet: Ethernet: 0800.0020.1111 0800.0020.1111

Networking Fundamentals

2009, Velocis Systems

1-117

Address Resolution Protocol


I need the Ethernet address of 176.16.3.2. I heard that broadcast. The message is for me. Here is my Ethernet address. 172.16.3.1 172.16.3.2

IP: IP: 172.16.3.2 172.16.3.2 = = ??? ??? IP: IP: 172.16.3.2 172.16.3.2 Ethernet: Ethernet: 0800.0020.1111 0800.0020.1111

Map IP
Networking Fundamentals

Ethernet
2009, Velocis Systems 1-118

DHCP (Dynamic Host Configuration Protocol)

The DHCP server dynamically assigns IP address to hosts. All types of Hardware can be used as a DHCP server, even a Cisco Router. BootP can also send an operating system that a host can boot from. DHCP can not perform this function. Following information is provided by DHCP while host registers for an IP address: IP Address Subnet mask Domain name Default gateway (router) DNS

Networking Fundamentals

2009, Velocis Systems

1-119

Internet Control Message Protocol


ICMP messages are carried in IP datagrams and used to send error and control messages.
Application Transport

1
ICMP Internet

Destination Unreachable Echo (Ping) Other

Data-Link Physical

Networking Fundamentals

2009, Velocis Systems

1-120

ICMP Ping

Networking Fundamentals

2009, Velocis Systems

1-121

Transport Layer Overview

Application Transport Internet Data-Link Physical

Transmission Transmission Control Control Protocol Protocol (TCP) (TCP) User User Datagram Datagram Protocol Protocol (UDP) (UDP)

ConnectionOriented Connectionless

Networking Fundamentals

2009, Velocis Systems

1-122

Transmission Control Protocol (TCP)


TCP works at Transport Layer TCP is a connection oriented protocol. TCP is responsible for breaking messages into segments and reassembling them. Supplies a virtual circuit between end-user application.
Networking Fundamentals 2009, Velocis Systems 1-123

TCP Segment Format


Bit 0 Source Port (16) Bit 15 Bit 16 Destination Port (16) Bit 31

Sequence Number (32) Acknowledgment Number (32)


Header Length (4)

20 Bytes

Reserved (6) Code Bits (6) Checksum (16) Options (0 or 32 if Any) Data (Varies)

Window (16) Urgent (16)

Networking Fundamentals

2009, Velocis Systems

1-124

TCP Segment Format


Source port Number of the calling port Destination Port Number of the called port Sequence Number Number used to ensure correct sequencing of the arriving data Acknowledgement Number Next expected TCP octet Header Length Length of the TCP header Reserved Set to zero Code Bits Control Functions (setup and termination of a session) Window Number of octets that the sender is willing to accept Checksum Calculated checksum of the header and data fields Urgent Pointer Indication of the end of the urgent data Options One option currently defined (maximum TCP segment size) Data Upper layer protocol data
Networking Fundamentals 2009, Velocis Systems 1-125

Port Numbers

T E L N E T

S M T P

D N S

T F T P

S N M P

R I P

Application Layer

T P

21 Transport Layer

23 TCP

25

53

69
UDP

161

520

Port Numbers

Networking Fundamentals

2009, Velocis Systems

1-126

TCP Port Numbers


Source Source Port Port Destination Destination Port Port

Telnet Z
Host A Host Z

SP 1028 1028

DP 23 23

Destination port = 23. Send packet to my Telnet application.

Networking Fundamentals

2009, Velocis Systems

1-127

TCP Three-Way Handshake/Open Connection


Host A
Host B

Send SYN (seq = 100 ctl = SYN) SYN Received SYN Received Send SYN, ACK 2 (seq = 300 ack = 101 ctl = syn,ack)

Established (seq = 101 ack = 301 ctl = ack)

Networking Fundamentals

2009, Velocis Systems

1-128

TCP Simple Acknowledgment


Sender Send 1 Receive ACK 2 Send 2 Receive ACK 3 Send 3 Receive ACK 4

Networking Fundamentals

Receiver Receive 1 Send ACK 2

Receive 2 Send ACK 3 Receive 3 Send ACK 4


Window Size = 1
2009, Velocis Systems 1-129

TCP Sequence and Acknowledgment Numbers


Source Source Port Port Destination Destination Port Port Sequence Sequence Acknowledgment Acknowledgment

I just sent number 10

I just got number 10, now I need number 11.

Source Dest. Seq. Ack. 1028 10 1 1028 23 23 10 1 Source Dest. Seq. Ack. 23 1 11 23 1028 1 11 1028 Source Dest. Seq. Ack. 1028 1028 23 23 11 11 2 2 .

Networking Fundamentals

2009, Velocis Systems

1-130

TCP Windowing
Size = 3 Sender Window Send 1 Window Size = 3 Send 2 Window Size = 3 Send 3 ACK 3 Window Size = 2 Window Size = 3 Send 3 Window Size = 3 Send 4 ACK 5 Window Size = 2 Window Size = 3

Receiver

Packet 3 Is Dropped

Networking Fundamentals

2009, Velocis Systems

1-131

UDP (User Datagram Protocol)


A connectionless and unacknowledged protocol. UDP is also responsible for transmitting messages. But no checking for segment delivery is provided. UDP depends on upper layer protocol for reliability. TCP and UDP uses Port no. to listen to a particular services.

Networking Fundamentals

2009, Velocis Systems

1-132

UDP Segment Format


Bit 1 0 Source Port (16) Length (16) Data (if Any) Bit 15 Bit 16 Destination Port (16) Checksum (16) Bit 31 8 Bytes

No sequence or acknowledgment fields

Networking Fundamentals

2009, Velocis Systems

1-133

UDP Segment Format


Source port Number of the calling port Destination Port Number of the called port Length Number of bytes, including header and data Checksum Calculated checksum of the header and data fields Data Upper layer protocol data

Networking Fundamentals

2009, Velocis Systems

1-134

Application Layer Overview


File File Transfer Transfer -- TFTP* TFTP* -- FTP* FTP* -- NFS NFS E-Mail E-Mail -- SMTP SMTP Remote Remote Login Login -- Telnet* Telnet* -- rlogin* rlogin* Network Network Management Management -- SNMP* SNMP* Name Name Management Management -- DNS* DNS* *Used by the Router
Physical

Application Transport Internet Data-Link

Networking Fundamentals

2009, Velocis Systems

1-135

Telnet
Telnet is used for Terminal Emulation. It allows a user sitting on a remote machine to access the resources of another machine.
It allows you to transfer files from one machine to another. It also allows access to both directories and files. It uses TCP for data transfer and hence slow but reliable.

Networking Fundamentals

2009, Velocis Systems

1-136

Simple Network Management Protocol

SNMP enable a central management of Network. Using SNMP an administrator can watch the entire network. SNMP works with TCP/IP. IT uses UDP for transportation of the data.

Networking Fundamentals

2009, Velocis Systems

1-137

DNS (Domain Name Service)

DNS resolves FQDNs with IP address. DNS allows you to use a domain name to specify and IP address. It maintains a database for IP address and Hostnames. On every query it checks this database and resolves the IP.

Networking Fundamentals

2009, Velocis Systems

1-138

WAN Basics

2009, Velocis Systems

What Is a WAN?
A network that serves users across a broad geographic area Often uses transmission devices provided by public carriers (Pacific Bell, AT&T, etc.)
This service is commonly referred to as plain old telephone service (POTS)

WANs function at the lower three layers of the OSI reference model
Physical layer, data link layer, and network layer
Networking Fundamentals 2009, Velocis Systems 1-140

WAN Overview

Service Provider

WANs connect sites Connection requirements vary depending on user requirements and cost
Networking Fundamentals 2009, Velocis Systems 1-141

What is a WAN?

A WAN is a data communications network that covers a relatively broad geographic area and often uses transmission facilities provided by common carriers, such as telephone companies. WAN technologies function at the lower three layers of the OSI reference model: the physical layer, the data link layer, and the network layer.

Networking Fundamentals

2009, Velocis Systems

1-142

Serial Implementation of DTE versus DCE


Data Terminal Equipment
End of the users device on the WAN link

Data Communications Equipment


End of the WAN providers side of the communication facility DCE is responsible for clocking

Modem CSU/DSU DTE


S S S S S S S S S S

DCE

DTE

DCE

S S

DCE

DTE

Networking Fundamentals

2009, Velocis Systems

1-143

WAN Terminating Equipment


Physical Cable Types

Router
To Corporate Network

EIA/TIA-232 V.35 X.21 HSSI

WAN Provider (Carrier) Network


Modem
Usually on the Customers Premises

DTE

DCE

Data Terminal Equipment


The Customers Equipment
Networking Fundamentals

Data Circuit-Terminating Equipment


The Service Providers Equipment
2009, Velocis Systems 1-144

Serial Transmission
WAN Serial connectors use serial transmission Serial transmission uses one bit at time over a single channel. Parallel transmission can use 8 bits at a time, but all WANs use serial transmission. Cisco Routers use a proprietary 60 pin serial connector. Connector at the other end of the cable will depend on your service provider or end device requirements.
Networking Fundamentals 2009, Velocis Systems 1-145

LAN/WAN Devices

1999, Cisco Systems, Inc. 2009, Velocis Systems

LAN/WAN Devices

Hubs Bridges Switches Routers

Networking Fundamentals

2009, Velocis Systems

1-147

Hub

Device that serves as the center of a star topology network, sometimes referred to as a multiport repeater, no forwarding intelligence

Networking Fundamentals

2009, Velocis Systems

1-148

Hubs
123 126

124

127

Hub
125

Data

Data

128


Networking Fundamentals

Amplifies signals Propagates signals through the network Does not filter data packets based on destination No path determination or switching Used as network concentration point
2009, Velocis Systems 1-149

Hubs Operate at Physical layer

Physical

All devices in the same collision domain All devices in the same broadcast domain Devices share the same bandwidth
Networking Fundamentals 2009, Velocis Systems 1-150

Hubs: One Collision Domain

More end stations means more collisions CSMA/CD is used

Networking Fundamentals

2009, Velocis Systems

1-151

Bridge
Device that connects and passes packets between two network segments. More intelligent than hubanalyzes incoming packets and forwards (or filters) them based on addressing information.

Networking Fundamentals

2009, Velocis Systems

1-152

Bridge Example
123 126

124

Bridge
127

Hub
125

Hub
128

Segment 1

Corporate Intranet

Segment 2

More intelligent than a hubcan analyze incoming packets and forward (or filter) them based on addressing information Collects and passes packets between two network segments Maintains address tables

Networking Fundamentals

2009, Velocis Systems

1-153

Switches
Use bridging technology to forward traffic between ports. Provide full dedicated data transmission rate between two stations that are directly connected to the switch ports. Build and maintain address tables called content-addressable memory (CAM).
Networking Fundamentals 2009, Velocis Systems 1-154

SwitchingDedicated Media
Workstation

31

10-Mbps UTP Cable Dedicated

Switch

34 35

32

100 Mbps

100 Mbps Corporate Intranet

33

36

Uses bridging technology to forward traffic (i.e. maintains address tables, and can filter) Provides full dedicated transmission rate between stations that are connected to switch ports Used in both local-area and in wide-area networking All types availableEthernet, Token Ring, ATM
Networking Fundamentals 2009, Velocis Systems 1-155

Switches and Bridges Operate at Data Link Layer


Data Link

OR

Each segment has its own collision domain All segments are in the same broadcast domain
Networking Fundamentals 2009, Velocis Systems 1-156

Switches

Switch

Memory

Each segment has its own collision domain Broadcasts are forwarded to all segments

Networking Fundamentals

2009, Velocis Systems

1-157

Routers
Interconnect Interconnect LANs LANs and and WANs WANs Provide Provide path path determination determination using using metrics metrics Forward Forward packets packets from from one one network network to to another another Control Control broadcasts broadcasts to to the the network network
Networking Fundamentals 2009, Velocis Systems 1-158

Network Layer Functions (cont.)


1.1 1.0 4.0 4.1

1.2

1.3 E0

2.1 S0

2.2 S0

4.3 E0

4.2

Routing Table NET INT Metric 0 E0 1 0 S0 2 1 S0 4

Routing Table NET INT Metric 1 S0 1 0 S0 2 0 E0 4

Logical addressing allows for hierarchical network Configuration required Uses configured information to identify paths to networks
Networking Fundamentals 2009, Velocis Systems 1-159

Routers: Operate at the Network Layer


Broadcast control Multicast control Optimal path determination Traffic management Logical addressing Connects to WAN services

Networking Fundamentals

2009, Velocis Systems

1-160

Using Routers to Provide Remote Access


Modem or ISDN TA Telecommuter

Mobile User

Branch Office Main Office Internet

Networking Fundamentals

2009, Velocis Systems

1-161

Network Device Domains


Hub Bridge Switch Router

Collision Domains: 1 4 Broadcast Domains: 1


Networking Fundamentals

4 1

4 4
2009, Velocis Systems 1-162

Das könnte Ihnen auch gefallen