Download SindhUIT_Unit_01

Document related concepts

Zero-configuration networking wikipedia , lookup

Internet protocol suite wikipedia , lookup

Recursive InterNetwork Architecture (RINA) wikipedia , lookup

Transcript
Computer Communication and
Networking
Abdul Wahab Yaqoob
B.E(Telecom)MUET,CCNA,CCNP,MCSA,CCDA
Department of Information Technology
Campus Dadu ,University of Sindh
[email protected]
Unit #01 Lecture#03
Protocols and Layered Models
Computer Communication and Networking
Title of Subject : Computer Communication and Networking
Effective : 2K13 Batch
Marks : 100(theory) + 50 (Practical)
Credit Hours : 2+1
This Class will meet at: 9:00-11:00 AM on Thursday
Recommended Books
 ” Data Communications & Networking”, by Behroz Forouzan
 ” Data and Computer Communications”, by William Stallings
 ” Computer Networks, 4th Edition”, by Andrew S Tanenbaum
Department of Information Technology Sindh U, Campus Dadu
2
Computer Communication and Networking
Protocol in Network Communication
 A protocol is a set of predetermined rules
 A set of instruction, manners b/w communication devices
 Implemented in software that is loaded on each host
and network device
 Network protocols are used to allow devices to communicate
successfully
 Protocols agree on structure of message (specific to PDU’s)
 Protocols agree on the process of sharing, error handling, and
termination procedures – all functions necessary for
communication
 Require layer dependent encapsulations
Department of Information Technology Sindh U, Campus Dadu
3
Computer Communication and Networking
Function of Protocol in Network Communication
Example includes
DHCP
TFTP
FTP
SMTP
POP
IP
TCP
UDP
Department of Information Technology Sindh U, Campus Dadu
4
Computer Communication and Networking
Why OSI Model
 Provides a layered structure model
 The model was developed by the International Organization
for Standardization (ISO) in 1984.
 The OSI model divides the tasks into seven smaller, more
manageable task groups
 Benefits of using a layered model
Assists in protocol design
Fosters competition (different vendors can work
together)
Changes in one layer do not affect other layers
Provides a common language
Department of Information Technology Sindh U, Campus Dadu
5
Computer Communication and Networking
Layers with OSI Model
DATA
segments
Packets
Frames
bits
Department of Information Technology Sindh U, Campus Dadu
6
Computer Communication and Networking
PDU : Layer Specification Data.
PDUs are
SPECIFIC to each
layer!
Department of Information Technology Sindh U, Campus Dadu
7
Computer Communication and Networking
Layers with TCP/IP Model
TCP/IP Model – created in early 1970s –
Department of Information Technology Sindh U, Campus Dadu
8
Computer Communication and Networking
Comparing TCP/IP and OSI Model
Know these layers and how they compare between
the two models
Department of Information Technology Sindh U, Campus Dadu
9
Computer Communication and Networking
APPLICATION LAYER
Department of Information Technology Sindh U, Campus Dadu
10
Computer Communication and Networking
Applications Layer – allows user to interface
with the network!
Provides the interface between the applications on either end of the network
Department of Information Technology Sindh U, Campus Dadu
11
Computer Communication and Networking
Application Layer Protocols
• DNS – Matches domain names with IP addresses
• HTTP – Used to transfer data between clients/servers using
a web browser
• SMTP & POP3 – used to send email messages from clients
to servers over the internet
• FTP – allows the download/upload of files between a
client/server
• Telnet – allows users to login to a host from a remote
location and take control as if they were sitting at the
machine (virtual connection)
• DHCP – assigns IP addresses, subnet masks, default
gateways, DNS servers, etcs. To users as they login the
network
Department of Information Technology Sindh U, Campus Dadu
12
Computer Communication and Networking
DHCP
Dynamic Host Configuration Protocol
• enables devices to obtain IP addresses, subnet masks, gateways,
DNS server information, etc. from a DHCP server.
• An IP address that is not being used is assigned from a range of
available addresses
• Not permanently assigned – only leased for a specific period of
time (usually 8 hours – 8 days)
• If the host logs off or the power is lost, the IP address they were
using is returned to the pool to be re-assigned to another host
when needed.
• This is how you are able to use Wi-Fi at various places in the world!
• Don’t use DHCP for devices such as servers, printers, routers,
switches, etc. These should be statically assigned.
Department of Information Technology Sindh U, Campus Dadu
13
Computer Communication and Networking
FTP
•
•
•
Commonly used application layer protocol
Allows for the transfer of files between clients/servers.
Requires 2 connections to the server
1) Commands – uses TCP port 21
2) Actual data – uses TCP port 20
Department of Information Technology Sindh U, Campus Dadu
14
Computer Communication and Networking
DNS Services
DNS Servers resolve names to IP addresses. It would be difficult
to remember the IP address of every website we like to visit, but
we can remember names.
THANK YOU DNS SERVER!
Department of Information Technology Sindh U, Campus Dadu
15
Computer Communication and Networking
PRESENTATION LAYER
Department of Information Technology Sindh U, Campus Dadu
16
Computer Communication and Networking
Presentation Layer
• Present the data to the Network in common format for
Communication
• Includes Alpha Numerical Code set ASCII,
Compression, file format, Encoding and Decoding
Department of Information Technology Sindh U, Campus Dadu
17
Computer Communication and Networking
SESSION LAYER
Department of Information Technology Sindh U, Campus Dadu
18
Computer Communication and Networking
Session Layer
• Establish, Terminate and Maintain sessions(Log in, Log out)
Authentication, Permission
Department of Information Technology Sindh U, Campus Dadu
19
Computer Communication and Networking
TRANSPORT LAYER
Department of Information Technology Sindh U, Campus Dadu
20
Computer Communication and Networking
Transport Layer Role and Services
Department of Information Technology Sindh U, Campus Dadu
21
Computer Communication and Networking
• Purpose:
Track individual communication between applications on
source/destination hosts
Segment data and manage each piece of data – prepares it
to be sent across the network (network layer).
Encapsulation is required on each piece of data including
information that will allow that data to be tracked.
WITHOUT SEGMENTATION, only ONE application would be
able to receive data.
Re-assemble segments back into streams of application
data at the receiving host. Prepares it to be passed back to
the application layer.
Identify the different applications using port numbers. Each
software process that needs to access the network is
assigned a port # that is unique in that host. Indicates
which application that piece of data is associated with.
Department of Information Technology Sindh U, Campus Dadu
22
Computer Communication and Networking
Transport Layer Role and Services
Department of Information Technology Sindh U, Campus Dadu
23
Computer Communication and Networking
Controlling conversations
• Segmentation and reassembly – Transport layer divides
application data into blocks of data that are the appropriate size.
At the destination, the transport layer reassembles the data
before sending it up to the application or service.
• Conversation multiplexing – Many applications or services might
be running on each host. Each is assigned a port # so that the
Transport layer can determine which application or service is
associated with that data.
• TCP at the transport layer also provide (see next slide for details)




Connection-oriented conversations
Reliable/accurate delivery
Ordered data reconstruction
Flow control
Department of Information Technology Sindh U, Campus Dadu
24
Computer Communication and Networking
Controlling Conversations (cont’d)
• Establish a session – connection-oriented (TCP) or
connectionless (UDP)
• Reliable delivery – ensures that all pieces reach their
destination by having the source device retransmit
any data that is lost
• Same order delivery – numbering and sequencing
segments ensures the transport layer segments are
reassembled in the proper order
• Flow control – hosts have limited resources (memory,
bandwidth, etc.) If these get over-taxed, transport
layer can request the flow of data be slowed. Why do
this? Prevent the receiver from being overwhelmed
with data!
Department of Information Technology Sindh U, Campus Dadu
25
Computer Communication and Networking
Reliable communication
Department of Information Technology Sindh U, Campus Dadu
26
Computer Communication and Networking
TCP vs. UDP - characteristics
UDP – Connectionless
Advantage – low overhead data delivery
pieces – datagrams
‘Best Effort’ delivery
Used by application that don’t require reliable delivery
Minimal delays
TCP – connection-oriented
More overhead
Same order delivery
Reliability
flow-control
Department of Information Technology Sindh U, Campus Dadu
27
Computer Communication and Networking
HEADERS OF TCP AND UDP
 Web browsers
 E-mail
 File transfers
 DNS
 VoIP
 Video
streaming
Department of Information Technology Sindh U, Campus Dadu
28
Computer Communication and Networking
3-way Handshake
• Steps to establish a connection
1) The sender sends an initial SEQ value (set by TCP) to
begin communication!
2) The receiver responds with an ACK value = to the SEQ
value + 1. The ACK should always be the NEXT
expected Byte.
3) Sender responds with an ACK value = to SEQ value it
received + 1.
Department of Information Technology Sindh U, Campus Dadu
29
Computer Communication and Networking
3-way Handshake – Session Termination
Department of Information Technology Sindh U, Campus Dadu
30
Computer Communication and Networking
Managing TCP Sessions
Department of Information Technology Sindh U, Campus Dadu
31
Computer Communication and Networking
Managing TCP Sessions
If an acknowledgement isn’t sent that data was received, the
host will RESEND the data because it has reached a
timeout.
Department of Information Technology Sindh U, Campus Dadu
32
Computer Communication and Networking
Managing TCP Sessions
• Window size –
the amount of data a source can
transmit before an ACK must be received. It enables the
management of lost data and flow control.
Department of Information Technology Sindh U, Campus Dadu
33
Computer Communication and Networking
UDP Protocol
• Go over characteristics of UDP – used by DNS, SNMP,
DHCP, RIP, TFTP, Online games, streaming video, etc.
Department of Information Technology Sindh U, Campus Dadu
34
Computer Communication and Networking
UDP Protocol
• UDP doesn’t care if datagrams are out of order!
Department of Information Technology Sindh U, Campus Dadu
35
Computer Communication and Networking
NETWORK LAYER
Department of Information Technology Sindh U, Campus Dadu
36
Computer Communication and Networking
Network Layer Protocols and Internet Protocol (IP)
Provides services
to exchange data
over the network
between end
devices.
4 Processes:
Addressing
Encapsulation
Routing
De capsulation
Department of Information Technology Sindh U, Campus Dadu
37
Computer Communication and Networking
Network Layer Protocols and Internet Protocol (IP)
Department of Information Technology Sindh U, Campus Dadu
38
Computer Communication and Networking
Network Layer Protocols and Internet Protocol (IP)
• Connectionless systems (IP, UDP)
• Receiving host is NOT contacted before the message is sent
Department of Information Technology Sindh U, Campus Dadu
39
Computer Communication and Networking
Network Layer Protocols and Internet Protocol (IP)
• Source/Destination IP addresses get added at the
network layer (layer 3).
Department of Information Technology Sindh U, Campus Dadu
40
Computer Communication and Networking
Why separate hosts in a network?
• Common issues with large networks: performance
degradation, security issues, and address management
(identifying hosts).
Discuss
Broadcast
domains..
Be able to
identify
how many
there are!
Department of Information Technology Sindh U, Campus Dadu
41
Computer Communication and Networking
DATALINK LAYER
Department of Information Technology Sindh U, Campus Dadu
42
Computer Communication and Networking
Data Link Layer – Accessing the Media
• 2 basic services –
– Allows upper layers to access the media
– Controls how data is placed onto the media using
media access control and error detection
Data link layer terms
Frame – PDU for layer 2
Node – device on a network
Media – physical means to
carry the signals
Network – 2 or more nodes
connected to a common
medium
Department of Information Technology Sindh U, Campus Dadu
43
Computer Communication and Networking
Data-link layer DIVIDED!
• Logical Link Control (LLC) – defines the software process
that provide services to the network layer protocols.
Places information in the frame that identifies which
protocol is being used (IP, IPX, Appletalk, etc.).
– closest to the Network Layer
• Media Access Control (MAC) – defines the media access
processes performed by the hardware. Will be specific to
the type of media being used.
– closest to the physical layer
Department of Information Technology Sindh U, Campus Dadu
44
Computer Communication and Networking
Data Link Layer – Accessing the Media
• Function – responsible for controlling the transfer of
frames across the media.
Department of Information Technology Sindh U, Campus Dadu
45
Computer Communication and Networking
Media Access Control Techniques
• Logical topology – way a network transfers frames from one node
to the next. This is what the data link layer ‘sees’ when controlling
media access. These are virtual connections
• Physical topology – physical arrangement of the nodes and
connections.
These 2 are not
usually the same!
Department of Information Technology Sindh U, Campus Dadu
46
Computer Communication and Networking
Media Access Control Techniques
• Very simple media access control
• Data can only travel to/from 1 other place. No need
to be complicated!
Department of Information Technology Sindh U, Campus Dadu
47
Computer Communication and Networking
Traveling frames
• As frames traverse the network, the source and
destination addresses may change.
• Source MAC – gets reset to the next device (routers) as
it travels
• Destination MAC – gets set to the next device in line
(router or pc)
• Source IP – NEVER CHANGES
• Destination IP – NEVER CHANGES
Department of Information Technology Sindh U, Campus Dadu
48
Computer Communication and Networking
PHYSICAL LAYER
Department of Information Technology Sindh U, Campus Dadu
49
Computer Communication and Networking
Physical layer tasks
• Takes frame from data link layer
• Sees the frame as bits – no structure
• Encodes the bits as signals to go on the medium
Department of Information Technology Sindh U, Campus Dadu
50
Computer Communication and Networking
Physical layer standards define:
• Physical and electrical properties of the media
• Mechanical properties (materials, dimensions,
pinouts) of the connectors and NICs
• Bit representation by the signals (encoding)
• Definition of control information signals
Department of Information Technology Sindh U, Campus Dadu
51
Computer Communication and Networking
Throughput and Goodput
• Throughput is the actual rate of transfer of bits
at a given time
• Varies with amount and type of traffic, devices
on the route etc.
• Always lower than bandwidth
• Goodput measures usable data transferred,
leaving out overhead. (headers etc.)
Department of Information Technology Sindh U, Campus Dadu
52
Computer Communication and Networking
Media
• Copper cable (twisted pair and coaxial)
• Fibre optic cable
• Wireless
Department of Information Technology Sindh U, Campus Dadu
53
Computer Communication and Networking
Coaxial cable
• Central conductor
• Insulation
• Copper braid acting as return path for current and
also as shield against interference (noise)
• Outer jacket
Department of Information Technology Sindh U, Campus Dadu
54
Computer Communication and Networking
Connectors for coaxial cable
Department of Information Technology Sindh U, Campus Dadu
55
Computer Communication and Networking
Coaxial cable
• Good for high frequency radio/video signals
• Used for antennas/aerials
• Used for cable TV and Internet connections, often
now combined with fibre optic.
• Formerly used in Ethernet LANs – died out as UTP
was cheaper and gave higher speeds
Department of Information Technology Sindh U, Campus Dadu
56
Computer Communication and Networking
Unshielded twisted pair (UTP) cable
• 8 wires twisted together into 4 pairs and with
an outer jacket.
• Wires have colour-coded plastic jackets
• Commonly used for Ethernet LANs
Department of Information Technology Sindh U, Campus Dadu
57
Computer Communication and Networking
Straight through cable
•
•
•
•
Both ends the same
Connect PC to switch or hub
Connect router to switch or hub
Installed cabling is straight
through
Department of Information Technology Sindh U, Campus Dadu
58
Computer Communication and Networking
Crossover cable
• Wire 1 swaps with 3
• Wire 2 swaps with 6
• Connect similar devices to
each other
• Connect PC direct to router
Department of Information Technology Sindh U, Campus Dadu
59
Computer Communication and Networking
Rollover cable
• Wire order completely reversed
• Console connection from PC serial
port to router – to configure
router
• Special cable or RJ45 to D9
adaptor.
Department of Information Technology Sindh U, Campus Dadu
60
Computer Communication and Networking
UTP cable
• EIA/TIA sets standards for cables
• Category 5 or higher can be used for 100Mbps
Ethernet. Cat 5e can be used for Gigabit Ethernet if
well installed.
• We have Cat 5e. A new installation now would
have Cat 6.
• The number of twists per metre is carefully
controlled.
Department of Information Technology Sindh U, Campus Dadu
61
Computer Communication and Networking
Shielded twisted pair (STP)
• Wires are shielded against noise
• Much more expensive than UTP
• Might be used for 10 Gbps Ethernet
Department of Information Technology Sindh U, Campus Dadu
62
Computer Communication and Networking
Noise
• Electrical signals on copper cable are subject to
interference (noise)
• Electromagnetic (EMI) from device such as
fluorescent lights, electric motors
• Radio Frequency (RFI) from radio transmissions
• Crosstalk from other wires in the same cable or
nearly cables
Department of Information Technology Sindh U, Campus Dadu
63
Computer Communication and Networking
Fibre optic cable
•
•
•
•
Transmits flashes of light
No RFI/EMI noise problem
Several fibres in cable
Paired for full
duplex
Department of Information Technology Sindh U, Campus Dadu
64
Computer Communication and Networking
Single mode fibre optic
•
•
•
•
Glass core 8 – 10 micrometres diameter
Laser light source produces single ray of light
Distances up to 100km
Photodiodes to convert light back to electrical
signals
Department of Information Technology Sindh U, Campus Dadu
65
Computer Communication and Networking
Multimode fibre optic
• Glass core 50 – 60 micrometres diameter
• LED light source produces many rays of light at
different angles, travel at different speeds
• Distances up to 2km, limited by dispersion
• Photodiode receptors
• Cheaper than
single mode
Department of Information Technology Sindh U, Campus Dadu
66
Computer Communication and Networking
Fibre optic connectors
Straight tip (ST) connector
single mode
Single mode lucent connector
Subscriber connector (SC)
multimode
Multimode lucent connector
Duplex multimode lucent connector (LC)
Department of Information Technology Sindh U, Campus Dadu
67
Computer Communication and Networking
Which cable for the LAN?
UTP copper
Fibre optic
Max 100 m length
100km or 2km
Noise problems
No noise problems
Within building only
Within/between buildings
Cheaper
More expensive
Easier to install
Harder to install
Department of Information Technology Sindh U, Campus Dadu
68
Computer Communication and Networking
Thanks
Department of Information Technology Sindh U, Campus Dadu