Physical And Data Link Layers
-
Upload
tmavroidis -
Category
Documents
-
view
2.376 -
download
3
description
Transcript of Physical And Data Link Layers
Physical & Data Link Layers
Layers that TCP/IP rely on
February 4,2001Professor Tom Mavroidis
TCP/IP daemons
TCP/IP services are controlled by daemons The most important of these is the Internet
super server, inedt. It is used to dispatch other server daemons to
handle communications. /etc/rc.local file runs inetd at boot time inetd listens for socket connections and
decides on what service to provide
Physical Layer
Is the actual physical medium. May be copper wire or fiber optic cable or
the carrier wave in a wireless connection
Repeaters
Transmit messages between networks boosting the signal in the process thereby increasing the distance between nodes.
Maximum # of repeaters in a segment = 4 Maximum nodes in a segment for Thick
coax is 100 and for thin 30 Twisted pair supports 1024 nodes
Bridges
More intelligent than repeaters Operate at the Data Link layer. Deal with frames rather than signals Whole frame is read and retransmitted examines the address to determine if on the
same segment thereby reducing network traffic by not needlessly transmitting to another segment.
Switches
Modern replacement for bridges Perform better than bridges Operates at Data Link layer Accepts many different types of input Routes traffic between and broadcasts
between hosts in that group only Use where LAN performance is critical
Routers
Operates at the network layer Frames are passed up from the Data Link
layer Can route between different types of
networks I.E. Ethernet to token ring. When a router also acts as a bridge it is
known as a brouter
inetd
Referred to as the network super daemon Listens to several ports and dispatches other
server daemons to handle incoming service requests for other protocols
example of inetd.conf
Inetd - continued
If changes are made to this file you can have it reread by sending the daemon a HUP signal
# killall -HUP inetd inetd doesn’t work on all services such as
HTTP, SQL, and LDAP. Advantage is only one service has to be running
for services that are used infrequently
Data Link Layer
Addresses, controls and synchronizes data flow
Handles Data Addressing associated with each host
Controls data flow over the physical network Data integrity, ensuring data arrives at the
destination intact and in the right order
Data Addressing
Addresses must be unique across the Physical Layer otherwise traffic will not be directed to the correct host
Duplication of addresses can cause network slowdown and may even cause a network segment to be inoperative.
Flow Control
Ensures source host does not send faster than the destination host can receive otherwise the destination host will be overloaded.
Sets the maximum number of frames the source can send at once before waiting for the destination to let it continue
Flow Control - continued
Often implemented in the upper protocol layers but can also be implemented at the Data Link layer.
The mechanism for handling overload is called Source Quench.
Source Quench lies within the ICMP protocol which lives in the Network layer.
Data Integrity
Provided by dividing data into frames and adding a Cyclic Redundancy Check (CRC)
Electronic signature (mathematically computed) for the frame.
Computed at both ends, if differs retransmission is requested by the receiving end
Timers and Time Outs
Timer is started when frame is sent If no ack received in time frame is resent Each frame is numbered so acknowledging
frame can be identified Usually handled by higher layers although
can be implemented in the Data Link layer
Frames
A packet of information Many formats, sizes and encoding Three ways to delineate frames 1)Mark the end of the frame with a special
delimiter 2)Put the length in the frame header 3)Use fixed length packets
Frame Sizes
Maximum frame size determines maximum data payload
Known as Maximum Transmission Unit (MTU)
If data is larger than MTU it must be spread across more than one frame
Manchester encoding
Popular way to encode a string of data Surround each packet byte with start, stop,
and parity bits Based on transitions rather than simple
voltage Another method is differential Manchester
encoding - lack of transition denotes 1
CSMA/CD - Physical layer
CSMA/CD Carrier Sense Multiple Access with Collision Detect
host listens for a quiet period before sending frame (CS)
CD - host detects when a collision occurred waits a random amount of time and resends further retries use an exponential back-off
Variation of CSMA/CD
1-persistent - always sends a frame in response to a clear line (Ethernet uses this)
non-persistent - each station waits a random interval before checking the line
p-persistent - uses a variable probability scheme
Strength of CSMA/CD
Good at handling variable loads Minimizes collisions at low to medium
loads Easy to plug in or remove hosts Requires little admin Simple concept - easy to implement
Token Passing
Logical token is passed between hosts in a ring
Host can only send frames while it holds on to the token.
No Collisions Much more complex than CSMA/CD
Ethernet
Most common LAN in the TCP/IP environment
Connected in bus or star topology Uses CSMA/CD Three types of cable can be used 10Base5, 10Base2, 10BaseT
Token Ring
Designed by IBM standardized by IEEE (referred to as IEEE 802.5)
Uses a logical and physical ring topology Network is physically constructed into a star
shape connected by MSAUs Multistation Access Units.
Speed are 4 and 16 Mbps Uses differential Manchester encoding
Serial Protocols
Used when a connection is between two points only
Based on direct links, leased lines, or modem- based access through POTS
Relatively slow speeds Improvements have led to more sophisticated
protocols across serial lines called nomadic workstations
Slip
Early protocol to send IP over a serial link Never formalized into a standard Start and end of an IP datagram is detected by
reading bytes from a serial connection No longer predominant Limitations arise from its simplicity Fixed mapped IP - no dynamic address
allocation
PPP
Point to Point Protocol Modern implementation of SLIP Standardized Based on the HDLC standards Dynamic IP - many things can be
negotiated about the current session
Features of PPP
Error Checking Synchronous/asynchronous Provides weak (PAP) and strong (CHAP)
authentication
Three components to PPP
Encapsulation mechanism - includes and additional field that identifies the protocol using the link
Link Control Protocol - Link control protocol us used to establish, configure and test the data-link connection
Network Control Protocol - used to negotiate the network layer protocol
Things to review
IP Addressing Netmasks Reserved Addresses Broadcast Addresses Multicasting Network Interfaces