02computer Network Basics
02computer Network Basics
02computer Network Basics
An overview of computer networking which introduces many key concepts and terminology. Sets the stage for future topics.
Computer Processor Memory (active) (passive) Control (brain) (where programs, Datapath data live (brawn) when running) Devices Input
Output
Communication Devices
Synchronous communication uses a clock
signal separate from the data signalcommunication can only happen during the tick of the timing cycle Asynchronous communication does not use a clock signal- rather, it employs a start and stop bit to begin and end the irregular transmission of data
Operating systems
Developer or manufacturer Apple Computers Inc. AT&T Bell Laboratories Be Inc. Berkeley University Carnegie-Mellon University Cisco Systems Inc. HP IBM Linus Thorvald Microsoft Novell Siemens Silicon Graphics Sun Microsystems Operating system Mac OS 8/9/X Unix beOS BSD, FreeBSD Mach 3.0 IOS HP-UX AIX and OS/2 Linux Windows XP, Vista NetWare SINIX IRIX Solaris, SunOS, JavaOS
Santa Cruz Operation Inc. (SCO) SCO XENIX, SCO UNIX, SCO MPX
routers the fundamental question: how is data transferred through net? circuit switching: dedicated circuit per call: telephone net packet-switching: data sent thru net in discrete chunks
Connection of Networks
router or gateway
Network Topology
a) bus, b) star, c) ring, d) tree structure
a)
b)
c)
d)
Wired media
Telephone line Thin Coax Thick Coax Unshielded Twisted Pair (UTP) Shielded Twisted Pair (STP) Fibre
(Data) Reliability
A network service is (data) reliable
if the sender application can rely on the error-free and ordered delivery of the data to the destination In the Internet the reliability can obtained mainly by acknowledgements and retransmission In such a way the losses in the underlying layers can be retrieved
Congestion
prevention: to prevent
subnetwork in the same time, which prevent each other and in such a way the throughput decreases Congestion: the queues in the routers are too long, the buffers are full.
As a consequence some packages are dropped if the buffers of the routers are overloaded
In extreme case:
grid-lock, lock-up
Deadlock
congestion, the routers wait for each other Direct store and forward deadlock: the buffers of two neighbouring routers are full with the packets to be sent to the other router Indirect store and forward deadlock: the deadlock occurred not between two neighbouring routers but in a subnetwork, where any of the routers has not free buffer space for accepting packets
carries packets from on CPU to another Destination gets interrupt when packet arrives
information is to be transmitted Broadcast Network: Shared Communication Medium Delivery: How does a receiver know who packet is for?
Put
Arbitration: Act of negotiating use of shared medium Point-to-point network: a network in which every physical
header on front of packet: [ Destination | Packet ] Everyone gets packet, discards if not the target
wire is connected to only two computers Switch: a bridge that transforms a shared-bus (broadcast) configuration into a point-to-point network Router: a device that acts as a junction between two networks to transfer data packets among them
devices can be complex High degree of cooperation required between communicating systems
destination
addressing, path readiness to receive file formats, structure of data how commands are sent/received and acknowledged etc.
Each layer in stack: Performs related functions Relies on lower layer for more primitive functions Provides services to next higher layer Communicates with corresponding peer layer of neighboring system using a protocol
Network Layering
Each layer provides services needed by higher layers by utilizing services provided by lower layers
Packets are of limited size (called the Maximum Transfer Unit or MTU: often 200-1500 bytes in size) Routing is limited to within a physical link (wire) or perhaps through a switch
message service routed to anywhere: Physical Reality: Packets Limited Size Unordered (sometimes) Unreliable Machine-to-machine Only on local area net Asynchronous
Abstraction: Messages Arbitrary Size Ordered Reliable Process-to-process Routed anywhere Synchronous
blocks of formatted data Syntax: data format Semantics: control information (coordination, error handling) Timing: speed matching, sequencing Actions: what happens when an event occurs
Operation of Protocols
Host (n-1). layer protocol entity Host (n-1). layer protocol entity
...
layerprotocol
Physical Layer
Transmission of energy onto the
medium
Collection of energy from the medium This layer is concerned with the physical transmission of raw bits This bits are transmitted through mechanical, electrical, and procedural interfaces which include
interface card standard modem standards certain portions of the ISDN and LAN MAN standards
to frames
frame boundaries
that might have occurred during transmission across a link In addition this layer provides an error-free transmission channel to the next layer known as the network layer: error control
ARQ duplicates
Flow control
Network Layer I
The previous two layers were concerned with getting error-free data across a link The network layer establishes connections between nodes, routes data packets through the network, and accounts for them
End-to-end transmission of packets (possibly over multiple
Congestion control At this stage, there may be congestion due to many packets waiting to be routed Some packets may be lost during congestion
static dynamic
Network Layer II
Accounting packets bytes etc.
Internetworking
This layer is also concerned with internetworking where there is talking between technologies, such as the traditional Internet connected to ATM
Transport Layer I
This
layer presumes the ability to pass through a network and provides additional services to end-users, such as and-to-and packet reliability
(end-to-end communication path, usually reliable) Isolation from hardware Multiplexing/demultiplexing Divide message into packets Reassemble (possibly out of order packets) into the original message of the distant end
Transport Layer II
End-to-end flow control Acknowledgments Types of service
Session Layer
This layer enables users to establish sessions across a network between machines In addition, it offers session management services
Set up and management of end-to-end conversation Establish and terminate sessions superset of connections Assignment of logical ports Dialogue control Token management for critical operations Synchronization checkpoints/restarts
Presentation Layer
This layer is concerned with the syntax and semantics of messages, code conversions between machines, and other data conversion services Some of these services are data compression and data encryption
Interface between lower layers and application Formatting Syntax & semantics of messages
Authentication
Application Layer
Program youre running,applications file transfer, access & management e-mail virtual terminals WWW
Intermediate
Intermediate
Endsystem Application layer entity Presentation layer entity Session layer entity Transport layer entity
Session layer entity Transport layer entity Network layer entity Datalink layer entity Physical layer entity Network layer entity Datalink layer entity Physical layer entity Network layer entity Datalink layer entity Physical layer entity
Connectionless
Network Tools
Repeater: connects network segments
logically to one network Hub: multiport repeater Bridge: datalink level connection of two networks Switch: multiport bridge Router: connects networks that are compatible in transport level
Gateway
Routers
Provide link between networks
Accommodate network differences: Addressing schemes Maximum packet sizes Hardware and software interfaces Network reliability
Congestion/Traffic Management
(IEEE 802.3)
Access Method
Supporting Standard
IEEE 802.3
IEEE 802.3
IEEE 802.11
Internet
Ethernet (ring or star topology) Managed Leased Line Network (MLLN) ATM (Asynchronous Transfer Mode) Switched line ISDN line
State: the data collection, which are necessary for Hard state
Soft state
However Packets can experience delays, so not for real-time applications excessive congestion leads to packet delay and loss protocols (like TCP) are needed for reliable data transfer, and congestion control
Before continue, need some performance metrics Overhead: CPU time to put packet on wire Throughput: Maximum number of bytes per second
Latency:
Performance Considerations
Depends on wire speed, but also limited by slowest router (routing delay) or by congestion at routers Raw transfer time + overhead at each routing hop
A B
transmission
Queueing: time waiting at output link for transmission depends on congestion level of router
propagation
nodal processing
queueing
A B
transmission propagation
nodal processing
queueing
arrival rate
applications
source to destination
ppp, ethernet
reliability check info to form datagram send datagram to peer wait for peer to ack receipt analogy: post office
data application transport transport network link physical application transport network link physical ack data network link physical data application transport transport network link physical
Ht M Hn Ht M Hl Hn Ht M
IP over ATM
ATM Adaptation
application TCP/UDP IP AAL5 ATM physical application TCP/UDP IP AAL5 ATM physical ATM physical application TCP/UDP IP AAL5 ATM physical application TCP/UDP IP AAL5 ATM physical
switching Physical
Session
UDP Transport Network Data Link Physical
TCP IP
Network Access
Network Protocols
Protocol: Agreement between two parties as to how
information is to be transmitted
Example:
system calls are the protocol between the operating system and application Networking examples: many levels
Physical level: mechanical and electrical network (e.g. how are 0 and 1 represented) Link level: packet formats/error control (for instance, the CSMA/CD protocol) Network level: network routing, addressing Transport Level: reliable message delivery
NFS
RPC
WWW
ssh
Transport
Network Physical/Link
UDP
IP Ethernet ATM
TCP
Packet radio
Process to process communication Basic routing gets packets from machinemachine What we really want is routing from processprocess
Several
IP protocols include notion of a port, which is a 16-bit identifiers used in addition to IP addresses
A communication channel (connection) defined by 5 items: [source address, source port, dest address, dest port, protocol]
UDP: The User Datagram Protocol UDP layered on top of basic IP (IP Protocol 17)
Unreliable, unordered, user-to-user communication
IP Header (20 bytes) 16-bit source port 16-bit UDP length 16-bit destination port 16-bit UDP checksum
UDP Data
UDP: The Unreliable Datagram Protocol Datagram: an unreliable, unordered, packet sent from source user dest user (Call it UDP/IP) Important aspect: low overhead!
But we need ordered messages Create ordered messages on top of unordered ones
How
Often used for high-bandwidth video streams Many uses of UDP considered anti-social none of the wellbehaved aspects of (say) TCP/IP
Sequence
0,1,2,3,4.. If packets arrive out of order, reorder before delivering to user application For instance, hold onto #3 until #2 arrives, etc.
TCP Header
EHIP Data TCP data Message Ethernet Hdr
to network If Ethernet, broken into 1500B frames with headers, trailers (24B) All Headers, trailers have length field, destination, ...