chapter 2 communicating over the network cis 81 networking fundamentals rick graziani cabrillo...
Post on 15-Jan-2016
263 views
TRANSCRIPT
Chapter 2Communicating Over the Network
CIS 81 Networking Fundamentals
Rick Graziani
Cabrillo College
Last Updated: 2/17/2008
2
This Presentation
For a copy of this presentation and access to my web site for other CCNA, CCNP, and Wireless resources please email me for a username and password. Email: [email protected] Web Site: www.cabrillo.edu/~rgraziani
The Platform for Communications
4
Elements of Communication
5
Communicating the Messages
Theoretically, single communication, such as a music video or an e-mail message, could be sent across a network from a source to a destination as one massive continuous stream of bits.
No other device would be able to send or receive messages on the same network.
Results in significant delays. Inefficient use of channel or link. Any loss in data, entire message would have to be resent.
00101010100101010101010101010101010
I have to wait…
Continuous stream of bits
6
Communicating the Messages
Better approach – segmentation. Division of the data stream into smaller pieces is called segmentation.
Segmentation has two benefits…
Segmentation
7
Communicating the Messages
Benefits of segmentation: Multiplexing:
Different conversations can be interleaved on the network.
Segmentation
8
Communicating the Messages
Reliability Increase the reliability of network communications. Separate pieces of each message can travel across different paths to
destination. Path fails or congested, alternate path can be used. Part of the message fails to make it to the destination, only the missing
parts need to be retransmitted.
X
9
Disadvantage of Segmentation
Disadvantage – added level of complexity. Like sending a 100 page letter one page at a time.
All of the separate envelopes needed Need to label the pages with a sequence number.
This extra overhead is handled by protocols used to format and address these messages (later).
10
Components of the Network
Devices (hardware) End devices, switch, router, firewall, hub
Media (wired, wireless) Cables, wireless mediums
Services (software) Network applications, routing protocols, processes, algorithms
11
End devices
End devices: Computers (work stations, laptops, file servers, web servers) Network printers VoIP phones Security cameras Mobile handheld devices (such as wireless barcode scanners, PDAs)
End devices are referred to as hosts. A host device is either the source or destination of a message.
12
Each host on a network is identified by an address. IP (Internet Protocol) address (later)
Source Address: 209.67.102.55
Destination Address: 107.16.4.21
209.67.102.55 107.16.4.21
13
Servers and Clients
A host can act as a client, a server, or both. Software installed on the host determines the role.
Servers are hosts that have software installed that enables them to provide information and services, like e-mail or web pages, to other hosts on the network.
Clients are hosts that have software installed that enables them to request and display the information obtained from the server.
Server
Client
14
Intermediary Devices
Intermediary devices: Provide connectivity to the network (switches/hubs) Connect individual networks (routers) Connect segments (links) within the same network (switches/hubs)
Examples: Network Access Devices (Hubs, switches, and wireless access points) Internetworking Devices (routers) Communication Servers and Modems Security Devices (firewalls)
routers
switch or hub
switch or hub
15
Network Media
Network media: The medium provides the channel over which the message travels from source to destination. Metallic wires - encoding into patterns of electrical impulses. Fiber optics – encoding into pulses of light (infrared or visible light ranges) Wireless – encoding patterns of electromagnetic waves.
(Later: OSI Physical Layer)
16
Network Media
Different media considerations: Distance it can carry the signal Environment it works in Bandwidth Cost of medium and installation Cost of connectors and equipment
17
Local Area Network (LAN)
Local Area Network (LAN) An individual network usually spans a single geographical area, providing
services and applications to people within a common organizational structure, such as a single business, campus or region.
LAN devices Switches (and hubs) Routers Multilayer switches
18
Wide Area Network (WAN)
Wide Area Networks (WANs) Leased connections through a telecommunications service provider
network. Networks that connect LANs in geographically separated locations
Telecommunications service provider (TSP) interconnect the LANs at the different locations.
TSPs transported voice and data communications on separate networks. Providers are now offering converged information network services to their
subscribers.
T1, DS3, OC3 PPP, HDLC Frame Relay, ATM ISDN, POTS
19
The Internet – A Network of Networks
ISPs (Internet Service Providers) are often also TSPs. Connect their customers to the Internet. The Internet is created by the interconnection of networks belonging to ISPs. ISPs cooperate with other ISPs and TSPs to make sure their customers have
access to all Internet networks. BGP peering and routing is used.
20
CENIC – ISP for K-12, Community Colleges, CSU and UC
ISPs route traffic within their own group of networks (autonomous system). ISPs connect their networks to other ISPs networks. Within the ISP’s networks are both WANs and customer LANs
21
Network Representations
Network Interface Card (NIC) - Provides the physical connection to the network at the PC or other host device.
Physical Port - A connector or outlet on a networking device where the media is connected to a host or other networking device.
Interface - Specialized ports on an internetworking device that connect to individual networks. Because routers are used to interconnect networks, the ports on a router
are referred to network interfaces.
Protocols
23
Protocol
Protocol – Rules that govern communications. Protocol suite - A group of inter-related protocols that are necessary to
perform a communication function.
24
Multiple protocols (encapsulated)
The message received by the host usually contains multiple protocols, plus the actual data.
Note: Application Header (HTTP) may or may not exist. Typically Application Header or Data. (later)
HTTP Header Data
Frame Header IP Header TCP HeaderApp Header Frame Trailer
Data
Protocols
25
Multiple protocols (encapsulated)
Encapsulation – Process of adding a header to the data or any previous set of headers.
Decapsulation – Process of removing a header. More later.
HTTP Header Data
Frame Header IP Header TCP HeaderApp Header Frame Trailer
Data
Protocols
26
Example: Protocol – IPv4
Example of IPv4 More later
Frame Header IP Header TCP Header Frame Trailer
Data
HTTP Header
27
209.67.102.55 107.16.4.21
Frame Header IP Header TCP Header Frame Trailer
Data
209.67.102.55107.16.4.21
HTTP Header
28
Protocols
Networking protocols suites describe processes such as: The format or structure of the message The process by which networking devices share information about
pathways with other networks How and when error and system messages are passed between devices The setup and termination of data transfer sessions
29
Early days – proprietary network equipment and protocols. Now – Industry standards Institute of Electrical and Electronics Engineers (IEEE)
Develops standards in telecommunications, information technology and power generation.
Examples: 802.3 (Ethernet), 802.11 (WLAN) Internet Engineering Task Force (IETF)
Internet standards RFCs (Request for Comments) Example: TCP, IP, HTTP, FTP
Protocol Suites and Standards
30
Interaction of Protocols
Hypertext Transfer Protocol (HTTP) Common protocol that governs interaction between web server and a web
client. Defines the content and formatting of the requests and responses between the
client and server. Both the client and the web server software implement the HTTP application. HTTP relies on other protocols to govern how the messages are transported
between client and server.
31
Interaction of Protocols
Transmission Control Protocol (TCP) Transport protocol that manages the individual conversations between servers
and clients (not just web servers and web clients) TCP divides the HTTP messages into smaller pieces, called segments Responsible for controlling the information exchanged between the server and
the client: Size of data Flow control – how much is sent and received Reliability – Sequence numbers in case lost or missing
segment
32
Internetwork Protocol (IP) Responsible for taking the formatted segments from TCP, encapsulating them
into packets. Assigns the appropriate source and destination addresses,
Original source address of host Final destination address of host Used by routers in selecting the best path to the destination host.
packet
33
Interaction of Protocols
Network access protocols (Data link and Physical layer protocols) Physical transmission of data on the media. Take the packets from IP and format them to be transmitted over the media.
frame
34
Interaction of Protocols
Network access protocols (Data link and Physical layer protocols) Responsible for addressing and sending the IP packet between two devices on
the same network. Host to router Router to router Router to host
209.67.102.55 107.16.4.21
35
Technology-Independent Protocols
Protocols are not dependent upon any specific technology. For example:
Our IP Packet (IP + TCP + HTTP + Data) can be delivered over various types of networks using a variety of data link frames.
More later! – Herding cats.
Frame Header IP Header TCP Header Frame TrailerHTTP Header
T1, DS3, OC3 PPP, HDLC Frame Relay, ATM ISDN, POTS
Ethernet Ethernet
IP PacketIP Packet
Using Layered Protocols
37
Layered Model
Layered Models separate the functions of specific protocols.
38
Using a layered model: Have defined information that they act upon and a defined interface to the
layers above and below. Fosters competition because products from different vendors can work
together. Prevents technology or capability changes in one layer from affecting other
layers above and below. Provides a common language to describe networking functions and
capabilities.
Benefits of a Layered Model
39
Protocol and Reference Models
A protocol model provides a model that closely matches the structure of a particular protocol suite.
A reference model provides a common reference for maintaining consistency within all types of network protocols and services. Not intended to be an implementation specification.
40
Protocol and Reference Models
The Open Systems Interconnection (OSI) model is the most widely known internetwork reference model. OSI is also a protocol suite or protocol model. OSI lost out to TCP/IP as the protocol suite of the Internet. OSI protocol suite includes layers 3 through 7
41
TCP/IP Model
TCP/IP Model and Protocol Suite is an open standard. No one company controls it.
Governed by IETF Working Groups with standards proposed using Request for Comments (RFCs).
42
Example: RFC 791 IPv4
43
The Communication Process - Encapsulation
Server
DataHTTP Header
TCP Header
IP Header
Data Link Header
Data Link Trailer
HTTP Data
Encapsulation – Process of adding control information as it passes down through the layered model.
Note: Application Header (HTTP) may or may not exist. (later)
44
The Communication Process - Decapsulation
DataHTTP Header
TCP Header
IP Header
Data Link Header
Data Link Trailer
Client
HTTP Data
Decapsulation – Process of removing control information as it passes upwards through the layered model.
45
Wireshark will let us examine protocols!
46
The Communication Process
Protocol Data Unit (PDU) - The form that a piece of data takes at any layer. At each stage of the process, a PDU has a different name to reflect its new
appearance. PDUs are named according to the protocols of the TCP/IP suite.
Data - The general term for the PDU used at the Application layer Segment - Transport Layer PDU Packet - Internetwork Layer PDU Frame - Network Access Layer PDU Bits - A PDU used when physically transmitting data over the medium
47
ISO and the OSI Model
The International Organization for Standardization (ISO) released the OSI reference model in 1984, was the descriptive scheme they created.
“ISO. A network of national standards institutes from 140 countries working in partnership with international organizations, governments, industry, business and consumer representatives. A bridge between public and private sectors.” www.iso.ch
48
OSI Model
It breaks network communication into smaller, more manageable parts.
It standardizes network components to allow multiple vendor development and support.
It allows different types of network hardware and software to communicate with each other.
It prevents changes in one layer from affecting other layers.
It divides network communication into smaller parts to make learning it easier to understand.
49
OSI Model
Presentation and Session layers are not commonly referred to in most instances.
50
Comparing OSI and TCP/IP Models
Network Addressing
52
Layer 3 addresses are primarily designed to move data from one local network to another local network within an internetwork.
Layer 2 addresses are only used to communicate between devices on a single local network,
53
Layer 2 Addresses (Data Link Layer) Includes the host physical address. Layer 2 is concerned with the delivery of messages on a single local network. The Layer 2 address is unique on the local network and represents the address
of the end device on the physical media. In a LAN using Ethernet, this address is called the Media Access Control (MAC)
address. When two end devices communicate on the local Ethernet network, the frames
that are exchanged between them contain the destination and source MAC addresses. (later)
54
Ethernet LAN - Multiaccess
On an Ethernet LAN there are usually more than just two devices.
There can be hundreds, even thousands of devices on a single LAN.
Need a way to send it to a specific device on the LAN.
Frame Header IP Header TCP Header Frame TrailerHTTP Header
Destination Address
Source Address InternetWho are you?
55
Ethernet LAN - Multiaccess
Ethernet LANs are multiaccess networks. Multiple devices can access the network
(even at the same time). Ethernet NICs have unique 48 bit MAC
addresses. (much more later)
Frame Header IP Header TCP Header Frame TrailerHTTP Header
Destination Address
Source Addressaaa
bbb
ccc
ddd
eee
111
222
333
444
555
666
777
888
999
000
123
These Ethernet addresses are abbreviated for brevity.
Internet
987
56
Layer 2 addresses, including Ethernet MAC addresses are used to get the IP packet from one device to another device on the same network.
Frame Header IP Header TCP Header Frame TrailerHTTP Header
Destination Address: 888
Source Address: aaaaaa
bbb
ccc
ddd
eee
111
222
333
444
555
666
777
888
999
000
123
These Ethernet addresses are abbreviated for brevity.
Internet
987
Sending an IP Packet to a device within the LAN
57
The Layer 2 destination address is always a layer 2 address within that network.
Disregarding using proxies which are uncommon.
Frame Header IP Header TCP Header Frame TrailerHTTP Header
Destination Address: 987
Source Address: aaaaaa
bbb
ccc
ddd
eee
111
222
333
444
555
666
777
888
999
000
123
These Ethernet addresses are abbreviated for brevity.
Internet
987
Sending an IP packet outside the LAN
58
What is the Address on my Ethernet NIC?
59
Serial vs Multiaccess NetworkSerial (PPP)
Multiaccess (Ethernet)
60
Serial point-to-point networks
PPP – Point-to-Point Protocol (later) Only two devices on this network. No need for unique layer 2 address. Can use anything. PPP uses an 8 bit broadcast address – FF - Hex (all 1’s binary)
61
IP: 192.168.4.10
IP: 172.16.35.5
MAC: DD-DD-DD-44-44-44
MAC: AA-AA-AA-11-11-11
PPP
MAC: CC-CC-CC-33-33-33
MAC: BB-BB-BB-22-22-22
PPP
PPP
What are the frame and packet addresses at every point from Host A to Host D?
A
D
Frame Header IP Header TCP Header Frame TrailerHTTP Header
L2 Destination Address?
L3 Source Address?L3 Destination Address?
L2 Source Address?
W X
YZ
62
Layer 3 Addresses (Network Layer) Layer 3 addresses are primarily designed to move data from one local network to
another local network within an internetwork. At the boundary of each LAN a router, decapsulates the frame to read the
destination host address contained in the header of the packet. Routers use the Layer 3 destination address to determine which path to use to
reach the destination host. Once the path is determined, the router encapsulates the packet in a new frame
and sends it on its way toward the destination end device. When the frame reaches its final destination, the frame and packet headers are
removed and the data moved up to Layer 4.
63
The sending host builds message with multiple encapsulations.
Dest. MAC 00-10
Source MAC 0A-10
Type 800
Trailer
Layer 2 Data Link Frame
Dest. IP 192.168.4.10
Source IP 192.168.1.10
IP fields
Data
Layer 3 IP Packet
Dest. MAC 0B-31
Source MAC 00-20
Type 800
TrailerDest. IP 192.168.4.10
Source IP 192.168.1.10
IP fields
DataDest. Add FF-FF
Source Add Type 800
TrailerDest. MAC 0B-20
Source MAC 0C-22
Type 800
Trailer
DataHTTP Header
TCP Header
IP Header
Data Link Header
Data Link Trailer
DataHTTP Header
TCP Header
IP Header
Data Link Header
Data Link Trailer
The receiving host receives the message with multiple decapsulations.
64
Getting Data to the Right Application
Layer 4 (TCP/UDP) contains a port number which represents the application or service carried in the IP packet. Destination port – destination application Source port – source application
More later.
65
Getting Data to the Right Application
Destination port number tells the OS (TCP/IP) stack which application to hand the data to.
Examples: 80 = HTTP (www) 23 = Telnet 20, 21 = FTP 25 = SMTP
Chapter 2Communicating Over the Network
CIS 81 Networking Fundamentals
Rick Graziani
Cabrillo College
Last Updated: 2/17/2008