SlideShare a Scribd company logo
Chapter 9
Ethernet – Part 1
Ethernet Fundamentals
3
Part 1
 Introduction to Ethernet
Part 2
 Layer 2 and Ethernet Switches
 Cables, Duplex, and Troubleshooting
 Ethernet and the OSI Model – more detail
 Ethernet frames – more detail
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Introduction to Ethernet
Ethernet Local Area Networks (LANs)
5
 LAN (Local Area Network) - A computer network connected through a
wired or wireless medium by networking devices (hubs, switches, routers)
and administered by a single organization.
 Ethernet – A family of Layer 2 Data Link protocols for Local Area Networks
.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
IEEE Standards
6
Brief History:
 1970’s - Robert
Metcalfe and his
coworkers at Xerox
PARC
 1980 - Ethernet
protocol published
by Digital
Equipment
Corporation, Intel,
and Xerox (DIX)
 1985 - Institute of
Electrical and
Electronics
Engineers (IEEE)
published IEEE
802.2 and 802.3
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Our Focus is Ethernet
 History
 Roots in Aloha packet-radio network
 LAN standards define MAC and physical layer connectivity
 IEEE 802.3 (CSMA/CD - Ethernet) standard – originally 2Mbps
 IEEE 802.3u standard for 100Mbps Ethernet
 IEEE 802.3z standard for 1,000Mbps Ethernet
 CSMA/CD: Ethernet’s Media Access Control (MAC) policy
 CS = carrier sense
 Send only if medium is idle
 MA = multiple access
 CD = collision detection
 Stop sending immediately if collision is detected
7
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
8
LLC (Logical Link Control)
MAC (Media Access Control)
IEEE 802 Extension to the
OSI Model
 The Institute of Electrical and Electronic Engineers (IEEE) is a
professional organization that defines network standards.
 IEEE 802.3 “Ethernet” is the predominant and best known LAN
standards, along with 802.11 (WLAN).
 The IEEE divides the OSI data link layer into two separate sublayers.
Recognized IEEE sublayers are:
 Media Access Control (MAC) (transitions down to media)
 Logical Link Control (LLC) (transitions up to the network layer)
Data Link Sublayers
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Refresher: OSI Model
 Open Systems Interconnection model (OSI):
a conceptual model that characterizes and
standardizes the internal functions of
a communication system by partitioning it
into abstraction layers.
 The model is a product of the Open Systems
Interconnection project at the International
Organization for Standardization (ISO), maintained
by the identification ISO/IEC 7498-1.
9
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Refresher: OSI Model
 The model groups communication
functions into seven logical layers.
 A layer serves the layer above it
and is served by the layer below it.
 For example, a layer that provides
error-free communications across
a network provides the path
needed by applications above it,
while it calls the next lower layer to
send and receive packets that make
up the contents of that path.
 Two instances at one layer are
connected by a horizontal
connection on that layer.
10
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Refresher: OSI Model
11
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet Standard Defines Physical Layer
 802.3 standard defines both MAC and physical
layer details
12
Metcalfe’s original
Ethernet Sketch
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
13
LLC (Logical Link Control)
MAC (Media Access Control)
IEEE 802 Extension to the
OSI Model
 The Institute of Electrical and Electronic Engineers (IEEE) is a
professional organization that defines network standards.
 IEEE 802.3 “Ethernet” is the predominant and best known LAN
standards, along with 802.11 (WLAN).
 The IEEE divides the OSI data link layer into two separate sublayers.
Recognized IEEE sublayers are:
 Media Access Control (MAC) (transitions down to media)
 Logical Link Control (LLC) (transitions up to the network layer)
Again: Data Link Sublayers
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
LLC – Logical Link Sublayer
14
 Logical Link Control (LLC) defined in the IEEE 802.2 specification
 Provides versatility in services to network layer protocols that are above
it, while communicating effectively with the variety of technologies below
it.
 The LLC, as a sublayer, participates in the encapsulation process.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
802.2 LLC
15
IPX IP APPLE-
TALK
LLC
Layer 3
Layer 2 - LLC
MAC &Layer 1 Ethernet Token
Ring
FDDI
* *
**
* Legacy technologiesSoft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
A Quick Word about Token Ring
 Developed by IBM in early 80’s as a new LAN
architecture
 Consists of nodes connected into a ring (typically via
concentrators)
 Special message called a token is passed around the ring
 When nodes gets the token it can transmit for a limited time
 Every node gets an equal opportunity to send
 IEEE 802.5 standard for Token Ring
 Designed for predictability, fairness and reliability
 Originally designed to run at either 4Mbps and 16Mbps
 Still used and sold but beaten out by Ethernet
16
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
17
Application
Header + data
802.2 LLC Data Encapsulation Example
We will been focusing on the Layer 2, Data Link, Ethernet
Frame for now.
010010100100100100111010010001101000…
Application Layer
Layer 4: Transport Layer
Layer 3: Network Layer
Layer 2:
Data Link
Layer
Layer 1: Physical
Layer
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet Technologies: 10Base2
 10: 10Mbps; 2: under 185 (~200) meters cable length
 Thin coaxial cable in a bus topology
 Repeaters used to connect multiple segments
 Repeater repeats bits it hears on one interface to its other interfaces:
physical layer device only!
18
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
10BaseT and 100BaseT
 10/100 Mbps rate
 T stands for Twisted Pair
 Hub(s) connected by twisted pair facilitate “star topology”
 Distance of any node to hub must be < 100M
19
Location 1 Location 2 Location3
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Physical Layer Configurations for 802.3
 Physical layer configurations are specified in three parts
 Data rate (10, 100, 1,000)
 10, 100, 1,000Mbps
 Signaling method (base, broad)
 Baseband
 Digital signaling
 Broadband
 Analog signaling
 Cabling (2, 5, T, F, S, L)
 5 - Thick coax (original Ethernet cabling)
 F – Optical fiber
 S – Short wave laser over multimode fiber
 L – Long wave laser over single mode fiber
20
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet Overview
 Most popular packet-switched LAN technology
 Bandwidths: 10Mbps, 100Mbps, 1Gbps
 Max bus length: 2500m
 500m segments with 4 repeaters
 Bus and Star topologies are used to connect hosts
 Hosts attach to network via Ethernet transceiver or hub or switch
 Detects line state and sends/receives signals
 Hubs are used to facilitate shared connections
 All hosts on an Ethernet are competing for access to the medium
 Switches break this model
 Problem: Distributed algorithm that provides fair access
21
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet Overview (contd.)
 Ethernet by definition is a broadcast protocol
 Any signal can be received by all hosts
 Switching enables individual hosts to communicate
 Network layer packets are transmitted over an
Ethernet by encapsulating
 Frame Format
22
Dest
addr
64 48 32
CRCPreamble Src
addr
Type Body
1648
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet Frames
 Preamble is a sequence of 7 bytes,
each set to “10101010”
 Used to synchronize receiver before
actual data is sent
 Addresses
 unique, 48-bit unicast address
assigned to each adapter
 example: 8:0:e4:b1:2:af
 Each manufacturer gets their own
address range
 broadcast: all 1s
 multicast: first bit is 1
23
• Type field is a demultiplexing key
used to determine which higher
level protocol the frame should be
delivered to
• Body can contain up to 1500 bytes
of data
Soft Polynomials (I) Pvt. Ltd.
A Quick Word about Aloha Networks
 Developed in late 60’s by Norm Abramson at Univ. of
Hawaii (!!) for use with packet radio systems
 Any station can send data at any time
 Receiver sends an ACK for data
 Timeout for ACK signals that there was a collision
 What happens if timeout is poorly timed?
 If there is a collision, sender will resend data after a random backoff
 Utilization (fraction of transmitted frames avoiding
collision for N nodes) was pretty bad
 Max utilization = 18%
 Slotted Aloha (dividing transmit time into windows) helped
 Max utilization increased to 36%
24
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet’s MAC Algorithm
 In Aloha, decisions to transmit are made without paying
attention to what other nodes might be doing
 Ethernet uses CSMA/CD – listens to line before/during
sending
 If line is idle (no carrier sensed)
 send packet immediately
 upper bound message size of 1500 bytes
 must wait 9.6us between back-to-back frames
 If line is busy (carrier sensed)
 wait until idle and transmit packet immediately
 called 1-persistent sending
 If collision detected
 Stop sending and jam signal
 Try again later
25
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Collisions
 Collisions are caused when two adaptors transmit
at the same time (adaptors sense collision based on
voltage differences)
• Both found line to be idle
• Both had been waiting to for a busy line to become idle
26
A B
A B
A starts at
time 0
Message almost
there at time T when
B starts – collision!
How can we be sure A knows about the collision?
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Collision Detection
 How can A know that a collision has taken place?
 There must be a mechanism to insure retransmission on collision
 A’s message reaches B at time T
 B’s message reaches A at time 2T
 So, A must still be transmitting at 2T
 IEEE 802.3 specifies max value of 2T to be 51.2us
 This relates to maximum distance of 2500m between hosts
 At 10Mbps it takes 0.1us to transmit one bit so 512 bits (64B) take 51.2us to
send
 So, Ethernet frames must be at least 64B long
 14B header, 46B data, 4B CRC
 Padding is used if data is less than 46B
 Send jamming signal after collision is detected to insure all hosts see
collision
 48 bit signal
27
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Collision Detection contd.
 Video
28
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
State Diagram for CSMA/CD
29
Packet?
Sense
Carrier
Discard
Packet
Send Detect
Collision
Jam channel
b=CalcBackoff();
wait(b);
attempts++;
No
attempts < 16
attempts == 16
Yes
NoYes
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Exponential Backoff
 If a collision is detected, delay and try again
 Delay time is selected using binary exponential backoff
 1st time: choose K from {0,1} then delay = K * 51.2us
 2nd time: choose K from {0,1,2,3} then delay = K * 51.2us
 nth time: delay = K x 51.2us, for K=0..2n – 1
 Note max value for k = 1023
 give up after several tries (usually 16)
 Report transmit error to host
 If delay were not random, then there is a chance that
sources would retransmit in lock step
 Why not just choose from small set for K
 This works fine for a small number of hosts
 Large number of nodes would result in more collisions
30
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
CSMA/CD Operation
31
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
IEEE 802.3 CSMA/CD Flow Chart
32
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet is Best Effort Delivery
33
 Ethernet is best-
effort delivery, no
guarantee.
 Like a trucking
service, it doesn’t
really know or
care about the
what it is carrying.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
The IEEE Working Groups
34
802.1
802.2
802.3
802.4
802.5
802.6
802.7
802.8
802.9
Networking Overview and Architecture
Logical Link Control
Ethernet
Token Bus
Token Ring
MANs
Broadband
Fiber Optic
Isochronous LAN
...and more!
802.11 Wireless LAN
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
IEEE Identifiers
35
 3 part identifier
 Speed in Mbps
 Type of signaling used (Baseband or Broadband)
 Distance or Medium
 Early days: Cable Distance in meters, rounded to the nearest 100
meters
 Later days: Physical medium used
Early Standards Older Fiber
Standards
100 Mbps Media 1000 Mbps Media
10BASE5 10BASE-F 100BASE-T 1000BASE-X
10BASE2 10BASE-FB 100BASE-X 1000BASE-SX
FOIRL 10BASE-FP 100BASE-TX 1000BASE-LX
10BROAD36 10BASE-FL 100BASE-FX 1000BASE-CX
1BASE5 100BASE-T4 1000BASE-T
10BASE-T 100BASE-T2
Many of these standards were short lived or never implemented
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Physical Attributes
36
IEEE Identifiers
37
 10BASE5 (Thick Ethernet)
 10 refers to 10 Mbps
 Baseband: Dedicated to carrying one type of service
 Broadband: (Cable television) Designed to deliver multiple channels
 5 refers to 500 meter maximum distance
 100BASE-TX (Most widely used variety of Fast Ethernet)
 100 refers to 100 Mbps
 TX Two pairs of Category 5 Twisted-pair cable
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Network Interface Card (NIC)
38
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Network Interface Card (NIC)
39
Network Interface Card (NIC)
 Layer 2, Data Link Layer, device
 Connects the device (computer) to
the LAN
 Responsible for the local Layer 2
address (later)
 Common Layer 2 NICs:
 Ethernet
 Token Ring
 Common Bandwidth
 10 Mbps, 10/100 Mbps,
10/100/1000 Mbps
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Tracing the Physical Connection
NIC (Network Interface Card)
40
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Connecting the NIC to a Hub or Switch…
41
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
From PC to Ethernet Port…
42
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
From Ethernet Port to Patch Panel…
43
Back View Front View
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
From Patch Panel to Switch (or hub)
44
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
From PC to Switch
45
Soft Polynomials (I) Pvt. Ltd.
All of that is the same as these!
46
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Our focus!
47
 Ethernet protocol is only concerned with how the
information gets from one Ethernet host or device
to another.
 This is done at the MAC Sub-Layer
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Protocol Matters
48
Media Access Control Protocol
49
 Original Ethernet standard based on CSMA/CD media access control (MAC)
 Also known as Half-duplex mode
 No need for CSMA/CD in Full-duplex mode (later)
 Compete for a shared Ethernet channel in a fair and equitable manner
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Generic Data Link Frame Format
50
Preamble or Start Field
 When computers are connected to a physical medium, there must be a way
they can grab the attention of other computers to broadcast the message,
"Here comes a frame!"
 Various technologies have different ways of doing this process, but all
frames, regardless of technology, have a beginning signaling sequence of
bytes.
 Depending upon frame format: Preamble = 7 bytes, Start or Start of Frame
Delimiter (SFD) = 1 byte
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Generic Data Link Frame Format
51
Address Field
 We saw how IEEE 802.3 uses Destination and Source Addresses.
 Ethernet:
 Unicast address – MAC address of a single device
 Broadcast address – All devices (All 1 bits, All F’s in Hex)
 Multicast address – Specific group of devices
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Unicast, Multicast, Broadcast
Destination Addresses
52
 Unicast address: A single Ethernet frame to be received by a single
station.
 Unknown Unicast: This is from the perspective of a switch, when the
unicast address is not in its MAC Address Table
 Multicast address: A single Ethernet frame to be received by a group of
stations.
 Broadcast address: Special case of a multicast address, which is all 1’s.
This is an Ethernet frame to be received by all stations.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Generic Data Link Frame Format
53
Type Field
 Usually information indicating the layer 3 protocols in the data field, I.e. IP
Packet.
 Type field values of particular note for IEEE 802.3 frames include:
 0x0600 XNS (Xerox)
 0x0800 IP (Internet protocol)
 0x8137 Novell NetWare packet formatted for Ethernet II
 0x0806 ARP Message
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Generic Data Link Frame Format
54
Data Field
 Included along with this data, you must also send a few other bytes.
 They are called padding bytes, and are sometimes added so that the frames
have a minimum length for timing purposes.
 LLC bytes are also included with the data field in the IEEE standard frames.
(later)
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
55
 The fields of various Ethernet framing that are used for identifying the type of data
contained in a frame:
 Ethernet II or DIX (DEC, Intel, Xerox) – Most common
 IEEE Ethernet (802.3)
 IEEE 802.3 with SNAP header
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
IFG – Interframe Gap
56
 Ethernet devices must allow a minimum idle period between transmission of
frames known as the interframe gap (IFG) or interpacket gap (IPG).
 Note: Both half and full-duplex
 It provides a brief recovery time between frames to allow devices to prepare
for reception of the next frame.
 The minimum interframe gap is:
 10 Mbps Ethernet: 96 bit times, which is 9.6 microseconds (millionths
of a second)
 100 Mbps, Fast Ethernet: 960 nanoseconds (billionths of a second)
 1000 Mbps, Gigabit Ethernet: 96 nanoseconds
 Note: 802.11 (WLAN) uses similar
Ethernet
Frame
IFG Ethernet
Frame
IFG Ethernet
Frame
IFG Ethernet
Frame
IFG
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Collisions, Slot time and Minimum Frame Size
57
Notes
 Original Ethernet (802.3) designed as Half-duplex
 CSMA/CD is based on half-duplex and is NOT part of full-duplex
 Collisions are part of CSMA/CD and half-duplex Ethernet
 Collisions are a normal part of operation and are NOT errors
 Collisions are NOT part of full-duplex Ethernet
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Collision Domain
58
 Collision Domain: Refers to a single half-duplex Ethernet system whose
elements (cables, repeaters, hubs, station interfaces and other network
hardware) are all part of the same signal timing domain.
 If two or more devices transmit at the same time a collision will occur.
 If a collision is detected, the station will continue to transmit 32 bits called
the collision enforcement jam signal.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Collision Domain
59
 Switches do not forward collision signals
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Slot Time and Maximum Cable Length
60
 Slot time
 Time it takes for a signal to travel from one end of the maximum-sized
system to the other end and return (round trip propagation time) within a
collision domain.
 Maximum time required by collision enforcement.
 After this amount of time (or bits), device assumes no collision.
 Ethernet and Fast Ethernet
 Slot time = 512 bit times (the time it takes to transfer 512 bits)
If a collision occurs it will
be within the first 512
bits that I send.
If a collision occurs it will
be within the first 512
bits that I send.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Slot Time and Maximum Cable Length
61
 Slot time and maximum cable length are tightly coupled.
 Original 10 Mbps Ethernet: On coaxial cable, signals could travel 2,800
meters (9,186 feet) and back in 512 bit times.
 Maximum distance of collision domain is 2,800 meters.
 In other words, a station would know about a collision (rise in DC signal
level) before it transmitted the 513th bit.
 Fast Ethernet Twisted-pair maximum network diameter is 205 meters or
672 feet, but is limited by cabling standards of 100 meters or 328 feet.
(Remember, more bits per second, shorter bits, than Ethernet)
If a collision occurs it will
be within the first 512
bits that I send.
If a collision occurs it will
be within the first 512
bits that I send.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Slot Time and Maximum Cable Length
62
 512 bit Slot Time
 Destination Address = 48 bits
 Source Address = 48 bits
 Type = 16 bits
 Data = 368 bits or (46 bytes * 8 bits per byte)
 FCS = 32 bits
 This is why there is a minimum of 46 bytes of data!
If a collision occurs
it will be within the
first 512 bits that I
send.
512 bit minimum
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Slot Time and Maximum Cable Length
63
 A collision will be noticed within the first 512 bits transferred, so the minimum
frame size must be 512 bits.
 After 512 bits, the sending station assumes no collisions.
 At 513 bits, all stations on the entire Ethernet system, collision domain (cable,
repeaters, hubs) should have seen this frame by now before they begin
transmitting.
 This is why there is a maximum size to the Ethernet system. (Half-duplex
only!)
If a collision occurs
it will be within the
first 512 bits that I
send.
512 bit minimum
Soft Polynomials (I) Pvt. Ltd.
BREAK KE BAAD!!!!
Soft Polynomials (I) Pvt. Ltd.
64
Subhash Iyer, Program Head
MAC Sub-Layer
1
MAC – Media Access Control Sublayer
2
 The Media Access Control (MAC) sublayer deals with the protocols
that a host follows in order to access the physical media.
 Defined in IEEE 802.3 specification
 Responsible for the actual framing
 Builds the 1s and 0s to hand off to the physical layer.
 Responsible for media access (CSMA/CD)
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet and IEEE 802.3
3
 This standard includes the protocol used to “frame” the data by the
sending Ethernet host computer.
 Most of the time, the term “Ethernet” is used to mean IEEE 802.3
 Ethernet and IEEE 802.3 are used interchangeably, even though they
are not really the same thing. (more later)
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet “Data”
4
Data may be:
 IP Packet
 ARP Message
 Other
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
The MAC Address
5
 Part of the Ethernet protocol includes the MAC
(Media Access Control)
 Every Ethernet NIC card has a unique MAC address.
 MAC addresses provide a way for computers to
identify themselves.
 They give hosts a permanent, unique name.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
The MAC Address
6
 MAC addresses are:
 48 bits in length
 Expressed as 12 hexadecimal digits.
 The first 6 hexadecimal digits, which are administered by the IEEE,
identify the manufacturer or vendor and thus comprise the Organizational
Unique Identifier (OUI).
 The remaining 6 hexadecimal digits comprise the interface serial
number, or another value administered by the specific vendor.
 MAC addresses are sometimes referred to as burned-in addresses (BIAs)
because they are burned into read-only memory (ROM) and are copied into
random-access memory (RAM) when the NIC initializesSoft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
The MAC Address
7
 The Ethernet protocol uses MAC addresses to identify the source of the
Ethernet frame and the destination of the Ethernet frame.
 Whenever a computer sends an Ethernet frame, it includes the MAC address on
its NIC as the Source “MAC” Address.
 We will learn later how it learns the Destination “MAC” Address.
 We will see how all of this works in a moment.
MAC
Address
MAC
Address
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
MAC Address Format
8
OUI unique
 An Intel MAC address: 00-20-E0-6B-17-62
 0000 0000 - 0010 0000 – 1110 0000 - 0110 1011 – 0001 0111 – 0110 0010
 IEEE OUI FAQs: http://standards.ieee.org/faqs/OUI.html
Dec Bin Hex Dec Bin Hex
0 = 0000 = 0 8 = 1000 = 8
1 = 0001 = 1 9 = 1001 = 9
2 = 0010 = 2 10 = 1010 = A
3 = 0011 = 3 11 = 1011 = B
4 = 0100 = 4 12 = 1100 = C
5 = 0101 = 5 13 = 1101 = D
6 = 0110 = 6 14 = 1110 = E
7 = 0111 = 7 15 = 1111 = F
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
What is the Address on my NIC?
9
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
MAC Addresses Are Flat
10
 MAC addresses provide a way for computers to identify themselves.
 They give hosts a permanent, unique name.
 The number of possible MAC addresses is 16^12 (or over 2 trillion!).
 MAC addresses do have one major disadvantage:
 They have no structure, and is considered flat address space.
 Like using just a name when sending a letter instead of a structured address.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Generic Data Link Frame
11
 A message is “framed” (layer 2) and transmitted on the
cable (layer 1) by the Ethernet NIC.
 Framing provides order, or structure, to the stream of
bits, bitstream.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Bringing it all together…
12
 Let’s pause here for a moment and figure all of this
out!
 Let’s bring the following together:
 Ethernet Frames and MAC Addresses
 Sending and receiving Ethernet frames on a bus
 CSMA/CD
 Sending and receiving Ethernet frames via a hub
 Sending and receiving Ethernet frames via a switch
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Serial vs Multiaccess Network
13Serial
Multiaccess
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
14
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet: Multiaccess Network
15
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Bus Topology
16
A bus topology uses a single backbone segment (length of
cable) that all the hosts connect to directly.
Original Ethernet used a bus topology.
By the way, Ethernet hubs work the same as a “bus”.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames on a bus
17
 When an Ethernet frame is sent out on the “bus”
all devices on the bus receive it.
 What do they do with it?
1111 2222 3333 nnnn Abbreviated
MAC
Addresses
11113333
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames on a bus
18
 When information (frame) is transmitted, every PC/NIC on the shared media
copies part of the transmitted frame to see if the destination address
matches the address of the NIC.
 If there is a match, the rest of the frame is copied
 If there is NOT a match the rest of the frame is ignored.
 Unless you are running a protocol analyzer program such as Ethereal.
1111 2222 3333 nnnn Abbreviated
MAC
Addresses
11113333
Nope Nope
Hey, that’s
me!
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames on a bus
19
 So, what happens when multiple computers try to
transmit at the same time?
1111 2222 3333 nnnn Abbreviated
MAC
Addresses
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames on a bus
20
Collision!
1111 2222 3333 nnnn Abbreviated
MAC
Addresses
X
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Access Methods
21
Two common types of access methods for LANs include
 Non-Deterministic: Contention methods (Ethernet, IEEE
802.3)
 Only one signal can be on a network segment at
one time.
 Collisions are a normal occurrence on an
Ethernet/802.3 LAN
 Deterministic: Token Passing (Token Ring)
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
CSMA/CD (Carrier Sense Multiple Access
with Collision Detection)
22
CSMA/CD Common contention method used with Ethernet and
IEEE 802.3
 “Let everyone have access whenever they want and we will work it
out somehow.”
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
CSMA/CD and Collisions
23
CSMA/CD (Carrier Sense Multiple Access with Collision Detection)
 Listens to the network’s shared media to see if any other users on “on the
line” by trying to sense a neutral electrical signal or carrier.
 If no transmission is sensed, then multiple access allows anyone onto
the media without any further permission required.
 If two PCs detect a neutral signal and access the shared media at the exact
same time, a collision occurs and is detected.
 The PCs sense the collision by being unable to deliver the entire frame onto
the network. (This is why there are minimum frame lengths along with
cable distance and speed limitations. This includes the 5-4-3 rule.)
 When a collision occurs, a jamming signal is sent out by the first PC to
detect the collision.
 Using either a priority or random backoff scheme, the PCs wait
certain amount of time before retransmitting.
 If collisions continue to occur, the PCs random interval is doubled,
lessening the chances of a collision.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
CSMA/CD and Collisions
24
And as we said,
 When information (frame) is transmitted, every PC/NIC on the shared
media copies part of the transmitted frame to see if the destination
address matches the address of the NIC.
 If there is a match, the rest of the frame is copied
 If there is NOT a match the rest of the frame is ignored.
1111 2222 3333 nnnn Abbreviated
MAC
Addresses
11113333
Nope Nope
Hey, that’s
me!
Notice the
location of
the DA!
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames via a hub
25
 Only one device on
the hub can
communicate at a
time, otherwise
collisions occur.
 10 Mbps ports are the
most common.
 100/1000 Mbps also
“available”.
 The hub acts the same
as a “bus”.
Hub or
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames via a hub
26
 So, what does a hub
do when it receives
information?
 A hub is nothing
more than a
multiport repeater.
1111 2222
3333 4444
5555
?
11113333
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Repeaters
27
 Signals can only travel so far through media before
they weaken, and become garbled.
 This weakening of signals is called attenuation.
 Attenuation increases when:
 Media distances are lengthened
 Nodes are added to the media
 Repeaters:
 take in weakened signals
 clean them up
 regenerate them
 send them on their way along the network
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Repeater: Layer 1 Device
28
 Repeaters are Layer 1 devices.
 They do NOT look at:
 Layer 2, Data Link (MAC, Ethernet)
addresses
 Layer 3, IP Addresses.
Signal come in
… signal go out.
(after I amplify
it)
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Hub
29
 Hub is nothing but a multiport repeater.
 Hubs are Layer 1 devices.
 Data that comes in one port is sent out all other ports, except for the port
it came in on.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Hubs
30
 Hubs allow computers and other network devices to
communicate with each other, and use a star topology.
 Like a repeater, a hub regenerates the signal.
 Hubs have the same disadvantage as a repeater, anything it
receives on one port, it FLOODS out all other ports.
 Wherever possible, hubs should be replace by switches.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames via a hub
31
 The hub will flood it out all ports
except for the incoming port.
 Hub is a layer 1 device.
 A hub does NOT look at layer 2
addresses, so it is fast in
transmitting data.
 Disadvantage with hubs: A hub
or series of hubs is a single
collision domain (coming)
 A collision will occur if any two or
more devices transmit at the same
time within the collision domain.
1111 2222
3333 4444
5555
11113333
Nope
Nope
Nope
For me!Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames via a hub
32
 Another disadvantage with hubs
is that is take up unnecessary
bandwidth on other links.
1111 2222
3333 4444
5555
11112222
Nope Nope
Nope
For me!
Wasted
bandwidth
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames via a hub
33
 What happens when
two hosts on the
same hub, or when
multiple hubs are
connected, transmit
at the same time?
1111 2222
3333 4444
5555
?
11112222
33334444
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames via a hub
34
 Collision occurs.
 Although, hubs have
little latency,
CSMA/CD requires
resending of frames
and adds latency.
1111 2222
3333 4444
5555
Collision
11112222
33334444
X
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Half-duplex (Introduction)
35
 Hubs operate only in Half-duplex.
 Half-duplex means that only one end can send at a time.
 With half-duplex NICs, a host can only transmit or receive, not both at the same
time, or a collision will occur.
 When multiple devices are connected to a hub or series of hubs, only one device
can transmit.
 Uses CSMA/CD.
 If the a carrier is detected, then the NIC will not transmit.
 Ethernet hubs and repeaters can only operate in half-duplex mode.
Half-duplex
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Half-Duplex mode
36
 All of these Ethernet
NICs and ports on the
hubs are operating in
Half-Duplex mode.
 When multiple devices
are connected to a hub
or series of hubs, only
one device can
transmit.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Collision Domain: Shared Access
37
 Collision domain (Wikipedia): A group of
Ethernet or Fast Ethernet devices in a
CSMA/CD LAN that are connected by
repeaters/hubs and compete for access on the
network.
 Only one device in the collision domain may
transmit at any one time, and the other
devices in the domain listen to the network
in order to avoid data collisions.
 A collision domain is sometimes referred to
as an Ethernet segment.
 If you connect several computers to a single
medium that is only connected by repeaters
and hubs (Layer 1 devices), you have a
shared-access situation, and you have a single
collision domain.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Full-duplex
38
 Full-duplex is allows simultaneous communication between a pair of stations
or devices.
 Full-duplex allows devices to send and receive at the same time.
 Both ends of the link must be in full-duplex mode.
 In full-duplex, the station ignores any collision detect signals that come from
the transceiver.
 If a hub is connected to a switch, the switch port must be in half-duplex.
 The collision domain will end at the switch port.Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Where are the collision domains?
What would be the duplex settings?
39
hub hub hub hub hub hub
hub hub
router
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Where are the collision domains?
40
hub hub hub hub hub hub
hub hub
router
Single Collision Domain
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
What would be the duplex settings?
41
hub hub hub hub hub hub
hub hub
router
Half-duplex
Half-duplex
hub
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Where are the collision domains?
What would be the duplex settings?
42
hub hub hub hub hub hub
switch switch
router
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Switched Ethernet
 Switches forward and filter frames based on LAN addresses
 It’s not a bus or a router (although simple forwarding tables are
maintained)
 Very scalable
 Options for many interfaces
 Full duplex operation (send/receive frames simultaneously)
 Connect two or more “segments” by copying data frames
between them
 Switches only copy data when needed
 key difference from repeaters
 Higher link bandwidth
 Collisions are completely avoided
 Much greater aggregate bandwidth
 Separate segments can send at once
43
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Sending and receiving Ethernet frames via a switch
44
 Layer 2 device (also includes
layer 1) which examines and
bases its decisions on the
information in layer 2 frames
 Switch ports typically operate in
full-duplex.
 Multiple devices on the switch
can communicate at a time,
otherwise collisions occur.
 10/100 Mbps ports are the most
common.
 1000 Mbps also are also
common, usually connecting to
another switch or router.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Where are the collision domains?
What would be the duplex settings?
45
hub hub hub hub hub hub
switch switch
router
Collision Domains Collision Domains
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
What would be the duplex settings?
46
hub hub hub hub hub hub
switch switch
router
Half-duplex
Half-duplex
Full-duplex
hub
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Where are the collision domains?
What would be the duplex settings?
47
switch hub hub switch switch switch
switch switch
router
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Where are the collision domains?
48
switch hub hub switch switch switch
switch switch
router
Collision Domains
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
What would be the duplex settings?
49
switch hub hub switch switch switch
switch switch
router
Full-duplex
Half-duplex
Full-duplex
switch
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
All scenarios are
multiaccess networks
50
switch hub hub switch switch switch
switch switch
router
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Full-Duplex
52
11 22 33 44 55 66
Hub Hub
Half-duplex
CSMA/CD
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
53
11 22 33 44 55 66
Switch Switch
MAC Address Table
Port Source MAC Add. Port Source MAC Add.
MAC Address Table
Port Source MAC Add. Port Source MAC Add.
Full-duplex
No CSMA/CD
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Full-duplex
54
 Full-duplex is an optional mode of operation allowing simultaneous
communication between a pair of stations or devices.
 Specified in IEEE 802.3x in March 1997
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Full-duplex
55
 Full-duplex Ethernet allows the transmission of a packet and the reception
of a different packet at the same time.
 The full-duplex Ethernet switch takes advantage of the two pairs of wires in
the cable by creating a direct connection between the transmit (TX) at one
end of the circuit and the receive (RX) at the other end.
 Half Duplex Ethernet usually can only use 50%-60% of the available 10
Mbps of bandwidth because of collisions and latency.
 Full-duplex Ethernet offers 100% of the bandwidth in both
directions.
 10 Mbps Ethernet: This produces a potential 20 Mbps throughput, which
results from 10 Mbps TX and 10 Mbps RX.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Full-duplex
56
 IEEE 802.3x full-duplex
standard requires:
 The medium must have
independent transmit and
receive data paths that can
operate simultaneously.
 There are exactly two
stations connected with a full-
duplex point-to-point link.
 There is no CSMA/CD
multiple access algorithm,
since there is no contention
for a shared medium.
 Both stations on the LAN are
capable of, and have been
configured to use, the full-
duplex mode of operation.
 Ethernet hubs and repeaters
can only operate in half-duplex
mode.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Half-duplex Controller
57
 With half-duplex NICs,a host can only transmit or receive.
 If the a carrier is detected, then the NIC will not transmit.
 In full-duplex the station ignores the carrier sense and does not defer to
traffic being received on the channel.
 In full-duplex, the station ignores any collision detect signals that come from
the transceiver.
 Ethernet hubs and repeaters can only operate in half-duplex mode.
Half-duplex
controllers
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Full-duplex
58
 Both half-duplex and full-duplex Ethernet uses an interframe gap (IFG).
 Full-duplex uses the IFG to ensure that the interfaces at each end of the link
can keep up with the full frame rate of the link.
 CSMA/CD not used in full-duplex Ethernet:
 No CS (Carrier Sense) – In full-duplex the station ignores carrier
sense since it can send whenever it likes.
 No MA (Multiple Access) – Since there is only one station at the other
end of the link and the Ethernet channel between them is not the subject
of access contention.
 No CD (Collision Detect) – Since there is no access contention, there
will be no collisions, and station can ignore CD.
Ethernet
Frame
IFG Ethernet
Frame
IFG Ethernet
Frame
IFG Ethernet
Frame
IFG
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Full-duplex
59
 There are exactly two stations connected with
a full-duplex point-to-point link.
 Both stations on the LAN are capable of, and
have been configured to use, the full-duplex
mode of operation.
 Typically:
 Host-to-Switch
 Switch-to-Switch
 Switch-to-Router
Full-duplex
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Learning Switches
60
Learning Switches: Learns Source MAC Address
61MAC Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111
switch
1111
2222
3333
4444
Abbreviated
MAC
addresses
11113333
 Switches are also known as
learning bridges or learning
switches.
 A switch has a source address
table (or MAC Address Table) in
cache (RAM) where it stores a
source MAC address after it learns
about them.
 How does it learn source MAC
addresses?
 Whenever a frame enters a switch,
it will first see if the Source
Address (1111) is in it’s table.
 If it is, it resets the timer
(more in a moment).
 If it is NOT in the table it adds
it, with the port number.Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Destination MAC Address: Filter or Flood
62MAC Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111
switch
1111
2222
3333
4444
Abbreviated
MAC
addresses
11113333
 Next, the switch examines the
source address table for the
Destination MAC address.
 If it finds a match, it filters the
frame by only sending it out that
port.
 If there is not a match if floods it
out all ports.
 In this scenario, the switch will
flood the frame out all other ports,
because the Destination Address
is not in the source address table.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Learning Switches: Learns, Filter or Flood
63MAC Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111 6 3333
switch
1111
2222
3333
4444
Abbreviated
MAC
addresses
33331111
 Most communications involve some
sort of client-server
relationship or exchange of
information. (You will understand
this more as you learn about
TCP/IP.)
 Now 3333 sends data back to 1111.
 The switch sees if it has the Source
Address stored.
 It does NOT so it adds it. (This will
help next time 1111 sends to 3333.)
 Next, it checks the Destination
Address and in our case it can
filter the frame, by sending it only
out port 1.
Soft Polynomials (I) Pvt. Ltd.
Destination Address in table, Filter
64MAC Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111 6 3333
switch
1111
2222
3333
4444
Abbreviated
MAC
addresses
11113333
33331111
 Now, because both MAC addresses
are in the switch’s table, any
information exchanged between
1111 and 3333 can be sent
(filtered) out the appropriate port.
 What happens when two
devices send to same
destination?
 What if this was a hub?
 Where is (are) the collision
domain(s) in this example?
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
 Unlike a hub, a collision does
NOT occur, which would cause the
two PCs to have to retransmit the
frames.
 Collision domains end at the switch
 Instead the switch buffers the
frames and sends them out port #6
one at a time.
 The sending PCs have no idea that
their was another PC wanting to
send to the same destination.
No Collisions in Switch, Buffering
65MAC Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111 6 3333
9 4444
switch
1111
2222
3333
4444
Abbreviated
MAC
addresses
11113333
44443333
Soft Polynomials (I) Pvt. Ltd.
MAC Duplex – No collisions
66
 When there is only one device on a
switch port, the collision domain is
only between the PC and the switch,
which is non-existent with full-
duplex.
 With a full-duplex PC and switch
port, there will be no collision, since
the devices and the medium can
send and receive at the same time.
MAC Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111 6 3333
9 4444
switch
1111
2222
3333
4444
Abbreviated
MAC
addresses
11113333
44443333
No Collision Domains
Soft Polynomials (I) Pvt. Ltd.
Other Information
67
 How long are addresses kept in the
Source Address Table?
 5 minutes is common on most
vendor switches.
 How do computers know the
Destination MAC address?
 ARP Caches and ARP
Requests (later)
 How many addresses can be kept in
the table?
 Depends on the size of the cache,
but 1,024 addresses is common.
 What about Layer 2 broadcasts?
 Layer 2 broadcasts (DA = all
1’s) is flooded out all ports.
MAC Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111 6 3333
9 4444
switch
1111
2222
3333
4444
Abbreviated
MAC
addresses
Soft Polynomials (I) Pvt. Ltd.
What happens here?
68
 Notice the Source
Address Table has
multiple entries for
port #1.
33331111
3333
1111
MAC Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111 6 3333
1 2222 1 5555
2222 5555
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
What happens here?
69
 The switch resets the 5
minute timer on the
source port entry.
 The switch filters the
frame out port #1.
 But the hub is only a
layer 1 device, so a hub
floods it out all ports.
 Where is the collision
domain?
33331111
3333
1111
MAC Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111 6 3333
1 2222 1 5555
2222 5555
Reset timer
Filter
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
What happens here?
70
33331111
3333
1111
Source Address Table
Port Source MAC Add. Port Source MAC Add.
1 1111 6 3333
1 2222 1 5555
2222 5555
Collision Domain
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Cables, Troubleshooting
71
Unshielded Twisted Pair (UTP)
72
Straight-through Cross-over Rollover
www.cisco.com/warp/ public/701/14.html
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
UTP Straight-through Cable
73
 The cable that connects from the switch port to the
computer NIC port is called a straight-through cable.
 Connects unlike devices.
Host or RouterHub or Switch
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
UTP Straight-through Cable
74
Host or RouterHub or Switch
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
UTP Cross-over Cable
75
 The cable that connects from one switch port to
another switch port is called a crossover cable.
 Connects like devices.
Hub or Switch Hub or Switch
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
UTP Cross-over Cable
76
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Cabling – Show the straight-through and cross-over cables
77
hub hub hub hub hub hub
switch switch
router
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Cabling – Show the straight-through and cross-over cables
78
hub hub hub hub hub hub
switch switch
router
Straight-through cable
Cross-over cable
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Configuring Speed and Duplex
79
 Negotiation between NIC and
switch port.
 Duplex: Full-duplex or Half-
duplex
 Speed: 10/100/1000 Mbps
 Autonegotiation
 Both sides of a link should have
auto-negotiation on, or both sides
should have it off.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
When to Use Ethernet 10/100Mb Auto-
Negotiation – From www.cisco.com
80
 Auto-negotiation is an optional function of the IEEE 802.3u Fast
Ethernet standard that enables devices to automatically exchange
information over a link about speed and duplex abilities.
 Auto-negotiation is targeted at ports which are allocated to areas where
transient users or devices connect to a network.
 For example, many companies provide shared offices or cubes for Account
Managers and System Engineers to use when they are in the office rather
than on the road.
 Each office or cube will have an Ethernet port permanently connected to
the office's network.
 Because it may not be possible to ensure that every user has either a 10Mb, a
100Mb Ethernet, or a 10/100Mb card in their laptop, the switch ports that
handle these connections must be able to negotiate their speed and
duplex mode.
 The alternative would be to provide both a 10Mb and a 100Mb port in each
office or cube and label them accordingly.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
When to Use Ethernet 10/100Mb Auto-
Negotiation – From www.cisco.com
81
 One of the most common causes of performance issues on
10/100Mb Ethernet links is when one port on the link is operating at half-
duplex while the other port is operating at full-duplex.
 This occasionally happens when one or both ports on a link are reset and
the auto-negotiation process doesn't result in both link partners having
the same configuration.
 It also happens when users reconfigure one side of a link and forget to
reconfigure the other side.
 Both sides of a link should have auto-negotiation on, or both sides should
have it off.
 Our current recommendation is to leave auto-negotiation on for those
devices compliant with 802.3u.
 Many performance-related support calls will be avoided by correctly
configuring auto-negotiation.
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Half-duplex, Full-duplex Issue
82
 Switch A, the half-duplex end will sense a neutral carrier and send frames
 Switch B, the full-duplex end, senses the non-neutral carrier and since it doesn’t
care because it is configured as full-duplex, it transmits anyways.
 Switch A senses a collision (the half-duplex side) and stops sending the frame.
 Switch B (the full-duplex side) doesn’t care and keeps on sending frames.
 Data ends up being transmitted only one-way most of the time, with collisions
constantly happening on Switch A, causing performance issues on the network.
(Remember, most network communications is bi-directional.
 This is also a common cause for late collisions (a collision that occurs after the
first 512 bits (slot time) have been sent and the sender believes it has acquired the
channel.
Half-duplex Full-duplex
Switch A or Hub
A
Switch B
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Real World Troubleshooting - Symptom
83
switch switch switch switch switch switch
switch switch
router
A
B C D
W
X Y Z
 Hosts connected to switches B, C and D can reach each other and the Internet
with no problems.
 However, hosts on X, Y, and Z can either not access hosts on B, C, and D or
the Internet, or if they can it is extremely slow.
Internet
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Lights and indicators
84
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Real World Troubleshooting – Diagnostics
85
switch switch switch switch switch switch
switch switch
router
A
B C D
W
X Y Z
 You notice that a collision light (or looking at some diagnostic output) on Switch
W, port 1 is always on indicating a very large number of collisions detected on
that port.
Internet
Port 1
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Real World Troubleshooting – Problem
86
switch switch switch switch switch switch
switch switch
router
A
B C D
W
X Y Z
 The problem is that
 Switch A, Port 8 is in Full-duplex mode
 Switch W, Port 1 is in Half-duplex mode
 Switch A sends whenever it wants to without listening first to see if Switch W is
sending.
Internet
Half
Duplex
Port 1
Full
Duplex
Port 8
I’m half-duplex and I
keep seeing
collisions
I’m full-duplex so I
don’t see any
collisions
X
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Real World Troubleshooting – Solution
87
switch switch switch switch switch switch
switch switch
router
A
B C D
W
X Y Z
 Configure Switch W, Port 1 to be in full duplex, the same as Switch A, Port A.
Internet
Full Duplex
Transmissions
Full
Duplex
Port 8
Full
Duplex
Port 1
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Tit-Bits
88
Fast and Gigabit Ethernet
 Fast Ethernet (100Mbps) has technology very similar to
10Mbps Ethernet
 Uses different physical layer encoding (4B5B)
 Many NIC’s are 10/100 capable
 Can be used at either speed
 Gigabit Ethernet (1,000Mbps)
 Compatible with lower speeds
 Uses standard framing and CSMA/CD algorithm
 Distances are severely limited
 Typically used for backbones and inter-router connectivity
 Becoming cost competitive
 How much of this bandwidth is realizable
89
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Experiences with Ethernet
 Ethernets work best under light loads
 Utilization over 30% is considered heavy
 Network capacity is wasted by collisions
 Most networks are limited to about 200 hosts
 Specification allows for up to 1024
 Most networks are much shorter
 5 to 10 microsecond RTT
 Transport level flow control helps reduce load (number of
back to back packets)
 Ethernet is inexpensive, fast and easy to administer!
90
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Ethernet Problems
 Ethernet’s peak utilization is pretty low (like Aloha)
 Peak throughput worst with
 More hosts
 More collisions needed to identify single sender
 Smaller packet sizes
 More frequent arbitration
 Longer links
 Collisions take longer to observe, more wasted bandwidth
 Efficiency is improved by avoiding these conditions
91
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
Why did Ethernet Win?
 There are LOTS of LAN protocols
 Price
 Performance
 Availability
 Ease of use
 Scalability
92
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
T H A N K Y O U
Done – Lets Network to the
Real World NOW
93
Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head

More Related Content

PDF
Session 8,9 PCI Express
PPTX
AMBA 3 APB Protocol
PDF
Verification of amba axi bus protocol implementing incr and wrap burst using ...
PDF
Amba bus
ODP
PPTX
AMBA AHB 5
PDF
UVM TUTORIAL;
PPTX
SPI introduction(Serial Peripheral Interface)
Session 8,9 PCI Express
AMBA 3 APB Protocol
Verification of amba axi bus protocol implementing incr and wrap burst using ...
Amba bus
AMBA AHB 5
UVM TUTORIAL;
SPI introduction(Serial Peripheral Interface)

What's hot (20)

PPTX
bus and memory tranfer (computer organaization)
PDF
CPU Verification
PDF
SPI Protocol
PDF
Pcie basic
PPTX
PCIe Gen 3.0 Presentation @ 4th FPGA Camp
PPTX
Ambha axi
ODP
APB protocol v1.0
PPTX
Chapter 03 arithmetic for computers
PPTX
PPTX
PDF
Pci express modi
PPTX
Addressing modes
PPT
AMBA_APB_pst
PPTX
PCI express
PPTX
Advance Peripheral Bus
PDF
I2C Bus (Inter-Integrated Circuit)
PPTX
AMBA BUS.pptx
PPTX
Computer arithmetic
PPT
Axi protocol
bus and memory tranfer (computer organaization)
CPU Verification
SPI Protocol
Pcie basic
PCIe Gen 3.0 Presentation @ 4th FPGA Camp
Ambha axi
APB protocol v1.0
Chapter 03 arithmetic for computers
Pci express modi
Addressing modes
AMBA_APB_pst
PCI express
Advance Peripheral Bus
I2C Bus (Inter-Integrated Circuit)
AMBA BUS.pptx
Computer arithmetic
Axi protocol
Ad

Similar to Sessions 6,7 Ethernet (20)

PPT
Chapter 4ver2
PPT
Capitulo 9 Exploration Network
PPTX
Ethernet Computer network
PPT
NET1.PPT
PPT
IEEE Standards
PPT
Networking and Data Communications
PPTX
Advanced Network Chapter I: Which is very best lecture note
PDF
Introduction to networking
PDF
Ccent notes part 1
PDF
Ethernet_Networks
PPT
813 Ieeestds 090330072026 Phpapp01
PPTX
IEEE presentation
PPTX
Westermo webinar: Learning the Basics of Ethernet Networking
PPTX
Ethernet - LAN
PPTX
Local Area Network – Wired LAN
PPTX
local and wide area network--IN dats communication1) ch 5$6.pptx
PDF
I017554954
PPTX
M5 L4 Ethernet-Wired LAN.pptx communication
PDF
www.ijerd.com
Chapter 4ver2
Capitulo 9 Exploration Network
Ethernet Computer network
NET1.PPT
IEEE Standards
Networking and Data Communications
Advanced Network Chapter I: Which is very best lecture note
Introduction to networking
Ccent notes part 1
Ethernet_Networks
813 Ieeestds 090330072026 Phpapp01
IEEE presentation
Westermo webinar: Learning the Basics of Ethernet Networking
Ethernet - LAN
Local Area Network – Wired LAN
local and wide area network--IN dats communication1) ch 5$6.pptx
I017554954
M5 L4 Ethernet-Wired LAN.pptx communication
www.ijerd.com
Ad

Sessions 6,7 Ethernet

  • 2. Ethernet Fundamentals 3 Part 1  Introduction to Ethernet Part 2  Layer 2 and Ethernet Switches  Cables, Duplex, and Troubleshooting  Ethernet and the OSI Model – more detail  Ethernet frames – more detail Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 4. Ethernet Local Area Networks (LANs) 5  LAN (Local Area Network) - A computer network connected through a wired or wireless medium by networking devices (hubs, switches, routers) and administered by a single organization.  Ethernet – A family of Layer 2 Data Link protocols for Local Area Networks . Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 5. IEEE Standards 6 Brief History:  1970’s - Robert Metcalfe and his coworkers at Xerox PARC  1980 - Ethernet protocol published by Digital Equipment Corporation, Intel, and Xerox (DIX)  1985 - Institute of Electrical and Electronics Engineers (IEEE) published IEEE 802.2 and 802.3 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 6. Our Focus is Ethernet  History  Roots in Aloha packet-radio network  LAN standards define MAC and physical layer connectivity  IEEE 802.3 (CSMA/CD - Ethernet) standard – originally 2Mbps  IEEE 802.3u standard for 100Mbps Ethernet  IEEE 802.3z standard for 1,000Mbps Ethernet  CSMA/CD: Ethernet’s Media Access Control (MAC) policy  CS = carrier sense  Send only if medium is idle  MA = multiple access  CD = collision detection  Stop sending immediately if collision is detected 7 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 7. 8 LLC (Logical Link Control) MAC (Media Access Control) IEEE 802 Extension to the OSI Model  The Institute of Electrical and Electronic Engineers (IEEE) is a professional organization that defines network standards.  IEEE 802.3 “Ethernet” is the predominant and best known LAN standards, along with 802.11 (WLAN).  The IEEE divides the OSI data link layer into two separate sublayers. Recognized IEEE sublayers are:  Media Access Control (MAC) (transitions down to media)  Logical Link Control (LLC) (transitions up to the network layer) Data Link Sublayers Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 8. Refresher: OSI Model  Open Systems Interconnection model (OSI): a conceptual model that characterizes and standardizes the internal functions of a communication system by partitioning it into abstraction layers.  The model is a product of the Open Systems Interconnection project at the International Organization for Standardization (ISO), maintained by the identification ISO/IEC 7498-1. 9 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 9. Refresher: OSI Model  The model groups communication functions into seven logical layers.  A layer serves the layer above it and is served by the layer below it.  For example, a layer that provides error-free communications across a network provides the path needed by applications above it, while it calls the next lower layer to send and receive packets that make up the contents of that path.  Two instances at one layer are connected by a horizontal connection on that layer. 10 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 10. Refresher: OSI Model 11 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 11. Ethernet Standard Defines Physical Layer  802.3 standard defines both MAC and physical layer details 12 Metcalfe’s original Ethernet Sketch Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 12. 13 LLC (Logical Link Control) MAC (Media Access Control) IEEE 802 Extension to the OSI Model  The Institute of Electrical and Electronic Engineers (IEEE) is a professional organization that defines network standards.  IEEE 802.3 “Ethernet” is the predominant and best known LAN standards, along with 802.11 (WLAN).  The IEEE divides the OSI data link layer into two separate sublayers. Recognized IEEE sublayers are:  Media Access Control (MAC) (transitions down to media)  Logical Link Control (LLC) (transitions up to the network layer) Again: Data Link Sublayers Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 13. LLC – Logical Link Sublayer 14  Logical Link Control (LLC) defined in the IEEE 802.2 specification  Provides versatility in services to network layer protocols that are above it, while communicating effectively with the variety of technologies below it.  The LLC, as a sublayer, participates in the encapsulation process. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 14. 802.2 LLC 15 IPX IP APPLE- TALK LLC Layer 3 Layer 2 - LLC MAC &Layer 1 Ethernet Token Ring FDDI * * ** * Legacy technologiesSoft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 15. A Quick Word about Token Ring  Developed by IBM in early 80’s as a new LAN architecture  Consists of nodes connected into a ring (typically via concentrators)  Special message called a token is passed around the ring  When nodes gets the token it can transmit for a limited time  Every node gets an equal opportunity to send  IEEE 802.5 standard for Token Ring  Designed for predictability, fairness and reliability  Originally designed to run at either 4Mbps and 16Mbps  Still used and sold but beaten out by Ethernet 16 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 16. 17 Application Header + data 802.2 LLC Data Encapsulation Example We will been focusing on the Layer 2, Data Link, Ethernet Frame for now. 010010100100100100111010010001101000… Application Layer Layer 4: Transport Layer Layer 3: Network Layer Layer 2: Data Link Layer Layer 1: Physical Layer Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 17. Ethernet Technologies: 10Base2  10: 10Mbps; 2: under 185 (~200) meters cable length  Thin coaxial cable in a bus topology  Repeaters used to connect multiple segments  Repeater repeats bits it hears on one interface to its other interfaces: physical layer device only! 18 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 18. 10BaseT and 100BaseT  10/100 Mbps rate  T stands for Twisted Pair  Hub(s) connected by twisted pair facilitate “star topology”  Distance of any node to hub must be < 100M 19 Location 1 Location 2 Location3 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 19. Physical Layer Configurations for 802.3  Physical layer configurations are specified in three parts  Data rate (10, 100, 1,000)  10, 100, 1,000Mbps  Signaling method (base, broad)  Baseband  Digital signaling  Broadband  Analog signaling  Cabling (2, 5, T, F, S, L)  5 - Thick coax (original Ethernet cabling)  F – Optical fiber  S – Short wave laser over multimode fiber  L – Long wave laser over single mode fiber 20 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 20. Ethernet Overview  Most popular packet-switched LAN technology  Bandwidths: 10Mbps, 100Mbps, 1Gbps  Max bus length: 2500m  500m segments with 4 repeaters  Bus and Star topologies are used to connect hosts  Hosts attach to network via Ethernet transceiver or hub or switch  Detects line state and sends/receives signals  Hubs are used to facilitate shared connections  All hosts on an Ethernet are competing for access to the medium  Switches break this model  Problem: Distributed algorithm that provides fair access 21 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 21. Ethernet Overview (contd.)  Ethernet by definition is a broadcast protocol  Any signal can be received by all hosts  Switching enables individual hosts to communicate  Network layer packets are transmitted over an Ethernet by encapsulating  Frame Format 22 Dest addr 64 48 32 CRCPreamble Src addr Type Body 1648 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 22. Ethernet Frames  Preamble is a sequence of 7 bytes, each set to “10101010”  Used to synchronize receiver before actual data is sent  Addresses  unique, 48-bit unicast address assigned to each adapter  example: 8:0:e4:b1:2:af  Each manufacturer gets their own address range  broadcast: all 1s  multicast: first bit is 1 23 • Type field is a demultiplexing key used to determine which higher level protocol the frame should be delivered to • Body can contain up to 1500 bytes of data Soft Polynomials (I) Pvt. Ltd.
  • 23. A Quick Word about Aloha Networks  Developed in late 60’s by Norm Abramson at Univ. of Hawaii (!!) for use with packet radio systems  Any station can send data at any time  Receiver sends an ACK for data  Timeout for ACK signals that there was a collision  What happens if timeout is poorly timed?  If there is a collision, sender will resend data after a random backoff  Utilization (fraction of transmitted frames avoiding collision for N nodes) was pretty bad  Max utilization = 18%  Slotted Aloha (dividing transmit time into windows) helped  Max utilization increased to 36% 24 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 24. Ethernet’s MAC Algorithm  In Aloha, decisions to transmit are made without paying attention to what other nodes might be doing  Ethernet uses CSMA/CD – listens to line before/during sending  If line is idle (no carrier sensed)  send packet immediately  upper bound message size of 1500 bytes  must wait 9.6us between back-to-back frames  If line is busy (carrier sensed)  wait until idle and transmit packet immediately  called 1-persistent sending  If collision detected  Stop sending and jam signal  Try again later 25 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 25. Collisions  Collisions are caused when two adaptors transmit at the same time (adaptors sense collision based on voltage differences) • Both found line to be idle • Both had been waiting to for a busy line to become idle 26 A B A B A starts at time 0 Message almost there at time T when B starts – collision! How can we be sure A knows about the collision? Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 26. Collision Detection  How can A know that a collision has taken place?  There must be a mechanism to insure retransmission on collision  A’s message reaches B at time T  B’s message reaches A at time 2T  So, A must still be transmitting at 2T  IEEE 802.3 specifies max value of 2T to be 51.2us  This relates to maximum distance of 2500m between hosts  At 10Mbps it takes 0.1us to transmit one bit so 512 bits (64B) take 51.2us to send  So, Ethernet frames must be at least 64B long  14B header, 46B data, 4B CRC  Padding is used if data is less than 46B  Send jamming signal after collision is detected to insure all hosts see collision  48 bit signal 27 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 27. Collision Detection contd.  Video 28 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 28. State Diagram for CSMA/CD 29 Packet? Sense Carrier Discard Packet Send Detect Collision Jam channel b=CalcBackoff(); wait(b); attempts++; No attempts < 16 attempts == 16 Yes NoYes Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 29. Exponential Backoff  If a collision is detected, delay and try again  Delay time is selected using binary exponential backoff  1st time: choose K from {0,1} then delay = K * 51.2us  2nd time: choose K from {0,1,2,3} then delay = K * 51.2us  nth time: delay = K x 51.2us, for K=0..2n – 1  Note max value for k = 1023  give up after several tries (usually 16)  Report transmit error to host  If delay were not random, then there is a chance that sources would retransmit in lock step  Why not just choose from small set for K  This works fine for a small number of hosts  Large number of nodes would result in more collisions 30 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 30. CSMA/CD Operation 31 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 31. IEEE 802.3 CSMA/CD Flow Chart 32 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 32. Ethernet is Best Effort Delivery 33  Ethernet is best- effort delivery, no guarantee.  Like a trucking service, it doesn’t really know or care about the what it is carrying. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 33. The IEEE Working Groups 34 802.1 802.2 802.3 802.4 802.5 802.6 802.7 802.8 802.9 Networking Overview and Architecture Logical Link Control Ethernet Token Bus Token Ring MANs Broadband Fiber Optic Isochronous LAN ...and more! 802.11 Wireless LAN Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 34. IEEE Identifiers 35  3 part identifier  Speed in Mbps  Type of signaling used (Baseband or Broadband)  Distance or Medium  Early days: Cable Distance in meters, rounded to the nearest 100 meters  Later days: Physical medium used Early Standards Older Fiber Standards 100 Mbps Media 1000 Mbps Media 10BASE5 10BASE-F 100BASE-T 1000BASE-X 10BASE2 10BASE-FB 100BASE-X 1000BASE-SX FOIRL 10BASE-FP 100BASE-TX 1000BASE-LX 10BROAD36 10BASE-FL 100BASE-FX 1000BASE-CX 1BASE5 100BASE-T4 1000BASE-T 10BASE-T 100BASE-T2 Many of these standards were short lived or never implemented Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 36. IEEE Identifiers 37  10BASE5 (Thick Ethernet)  10 refers to 10 Mbps  Baseband: Dedicated to carrying one type of service  Broadband: (Cable television) Designed to deliver multiple channels  5 refers to 500 meter maximum distance  100BASE-TX (Most widely used variety of Fast Ethernet)  100 refers to 100 Mbps  TX Two pairs of Category 5 Twisted-pair cable Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 37. Network Interface Card (NIC) 38 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 38. Network Interface Card (NIC) 39 Network Interface Card (NIC)  Layer 2, Data Link Layer, device  Connects the device (computer) to the LAN  Responsible for the local Layer 2 address (later)  Common Layer 2 NICs:  Ethernet  Token Ring  Common Bandwidth  10 Mbps, 10/100 Mbps, 10/100/1000 Mbps Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 39. Tracing the Physical Connection NIC (Network Interface Card) 40 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 40. Connecting the NIC to a Hub or Switch… 41 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 41. From PC to Ethernet Port… 42 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 42. From Ethernet Port to Patch Panel… 43 Back View Front View Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 43. From Patch Panel to Switch (or hub) 44 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 44. From PC to Switch 45 Soft Polynomials (I) Pvt. Ltd.
  • 45. All of that is the same as these! 46 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 46. Our focus! 47  Ethernet protocol is only concerned with how the information gets from one Ethernet host or device to another.  This is done at the MAC Sub-Layer Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 48. Media Access Control Protocol 49  Original Ethernet standard based on CSMA/CD media access control (MAC)  Also known as Half-duplex mode  No need for CSMA/CD in Full-duplex mode (later)  Compete for a shared Ethernet channel in a fair and equitable manner Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 49. Generic Data Link Frame Format 50 Preamble or Start Field  When computers are connected to a physical medium, there must be a way they can grab the attention of other computers to broadcast the message, "Here comes a frame!"  Various technologies have different ways of doing this process, but all frames, regardless of technology, have a beginning signaling sequence of bytes.  Depending upon frame format: Preamble = 7 bytes, Start or Start of Frame Delimiter (SFD) = 1 byte Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 50. Generic Data Link Frame Format 51 Address Field  We saw how IEEE 802.3 uses Destination and Source Addresses.  Ethernet:  Unicast address – MAC address of a single device  Broadcast address – All devices (All 1 bits, All F’s in Hex)  Multicast address – Specific group of devices Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 51. Unicast, Multicast, Broadcast Destination Addresses 52  Unicast address: A single Ethernet frame to be received by a single station.  Unknown Unicast: This is from the perspective of a switch, when the unicast address is not in its MAC Address Table  Multicast address: A single Ethernet frame to be received by a group of stations.  Broadcast address: Special case of a multicast address, which is all 1’s. This is an Ethernet frame to be received by all stations. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 52. Generic Data Link Frame Format 53 Type Field  Usually information indicating the layer 3 protocols in the data field, I.e. IP Packet.  Type field values of particular note for IEEE 802.3 frames include:  0x0600 XNS (Xerox)  0x0800 IP (Internet protocol)  0x8137 Novell NetWare packet formatted for Ethernet II  0x0806 ARP Message Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 53. Generic Data Link Frame Format 54 Data Field  Included along with this data, you must also send a few other bytes.  They are called padding bytes, and are sometimes added so that the frames have a minimum length for timing purposes.  LLC bytes are also included with the data field in the IEEE standard frames. (later) Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 54. 55  The fields of various Ethernet framing that are used for identifying the type of data contained in a frame:  Ethernet II or DIX (DEC, Intel, Xerox) – Most common  IEEE Ethernet (802.3)  IEEE 802.3 with SNAP header Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 55. IFG – Interframe Gap 56  Ethernet devices must allow a minimum idle period between transmission of frames known as the interframe gap (IFG) or interpacket gap (IPG).  Note: Both half and full-duplex  It provides a brief recovery time between frames to allow devices to prepare for reception of the next frame.  The minimum interframe gap is:  10 Mbps Ethernet: 96 bit times, which is 9.6 microseconds (millionths of a second)  100 Mbps, Fast Ethernet: 960 nanoseconds (billionths of a second)  1000 Mbps, Gigabit Ethernet: 96 nanoseconds  Note: 802.11 (WLAN) uses similar Ethernet Frame IFG Ethernet Frame IFG Ethernet Frame IFG Ethernet Frame IFG Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 56. Collisions, Slot time and Minimum Frame Size 57 Notes  Original Ethernet (802.3) designed as Half-duplex  CSMA/CD is based on half-duplex and is NOT part of full-duplex  Collisions are part of CSMA/CD and half-duplex Ethernet  Collisions are a normal part of operation and are NOT errors  Collisions are NOT part of full-duplex Ethernet Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 57. Collision Domain 58  Collision Domain: Refers to a single half-duplex Ethernet system whose elements (cables, repeaters, hubs, station interfaces and other network hardware) are all part of the same signal timing domain.  If two or more devices transmit at the same time a collision will occur.  If a collision is detected, the station will continue to transmit 32 bits called the collision enforcement jam signal. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 58. Collision Domain 59  Switches do not forward collision signals Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 59. Slot Time and Maximum Cable Length 60  Slot time  Time it takes for a signal to travel from one end of the maximum-sized system to the other end and return (round trip propagation time) within a collision domain.  Maximum time required by collision enforcement.  After this amount of time (or bits), device assumes no collision.  Ethernet and Fast Ethernet  Slot time = 512 bit times (the time it takes to transfer 512 bits) If a collision occurs it will be within the first 512 bits that I send. If a collision occurs it will be within the first 512 bits that I send. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 60. Slot Time and Maximum Cable Length 61  Slot time and maximum cable length are tightly coupled.  Original 10 Mbps Ethernet: On coaxial cable, signals could travel 2,800 meters (9,186 feet) and back in 512 bit times.  Maximum distance of collision domain is 2,800 meters.  In other words, a station would know about a collision (rise in DC signal level) before it transmitted the 513th bit.  Fast Ethernet Twisted-pair maximum network diameter is 205 meters or 672 feet, but is limited by cabling standards of 100 meters or 328 feet. (Remember, more bits per second, shorter bits, than Ethernet) If a collision occurs it will be within the first 512 bits that I send. If a collision occurs it will be within the first 512 bits that I send. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 61. Slot Time and Maximum Cable Length 62  512 bit Slot Time  Destination Address = 48 bits  Source Address = 48 bits  Type = 16 bits  Data = 368 bits or (46 bytes * 8 bits per byte)  FCS = 32 bits  This is why there is a minimum of 46 bytes of data! If a collision occurs it will be within the first 512 bits that I send. 512 bit minimum Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 62. Slot Time and Maximum Cable Length 63  A collision will be noticed within the first 512 bits transferred, so the minimum frame size must be 512 bits.  After 512 bits, the sending station assumes no collisions.  At 513 bits, all stations on the entire Ethernet system, collision domain (cable, repeaters, hubs) should have seen this frame by now before they begin transmitting.  This is why there is a maximum size to the Ethernet system. (Half-duplex only!) If a collision occurs it will be within the first 512 bits that I send. 512 bit minimum Soft Polynomials (I) Pvt. Ltd.
  • 63. BREAK KE BAAD!!!! Soft Polynomials (I) Pvt. Ltd. 64 Subhash Iyer, Program Head
  • 65. MAC – Media Access Control Sublayer 2  The Media Access Control (MAC) sublayer deals with the protocols that a host follows in order to access the physical media.  Defined in IEEE 802.3 specification  Responsible for the actual framing  Builds the 1s and 0s to hand off to the physical layer.  Responsible for media access (CSMA/CD) Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 66. Ethernet and IEEE 802.3 3  This standard includes the protocol used to “frame” the data by the sending Ethernet host computer.  Most of the time, the term “Ethernet” is used to mean IEEE 802.3  Ethernet and IEEE 802.3 are used interchangeably, even though they are not really the same thing. (more later) Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 67. Ethernet “Data” 4 Data may be:  IP Packet  ARP Message  Other Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 68. The MAC Address 5  Part of the Ethernet protocol includes the MAC (Media Access Control)  Every Ethernet NIC card has a unique MAC address.  MAC addresses provide a way for computers to identify themselves.  They give hosts a permanent, unique name. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 69. The MAC Address 6  MAC addresses are:  48 bits in length  Expressed as 12 hexadecimal digits.  The first 6 hexadecimal digits, which are administered by the IEEE, identify the manufacturer or vendor and thus comprise the Organizational Unique Identifier (OUI).  The remaining 6 hexadecimal digits comprise the interface serial number, or another value administered by the specific vendor.  MAC addresses are sometimes referred to as burned-in addresses (BIAs) because they are burned into read-only memory (ROM) and are copied into random-access memory (RAM) when the NIC initializesSoft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 70. The MAC Address 7  The Ethernet protocol uses MAC addresses to identify the source of the Ethernet frame and the destination of the Ethernet frame.  Whenever a computer sends an Ethernet frame, it includes the MAC address on its NIC as the Source “MAC” Address.  We will learn later how it learns the Destination “MAC” Address.  We will see how all of this works in a moment. MAC Address MAC Address Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 71. MAC Address Format 8 OUI unique  An Intel MAC address: 00-20-E0-6B-17-62  0000 0000 - 0010 0000 – 1110 0000 - 0110 1011 – 0001 0111 – 0110 0010  IEEE OUI FAQs: http://standards.ieee.org/faqs/OUI.html Dec Bin Hex Dec Bin Hex 0 = 0000 = 0 8 = 1000 = 8 1 = 0001 = 1 9 = 1001 = 9 2 = 0010 = 2 10 = 1010 = A 3 = 0011 = 3 11 = 1011 = B 4 = 0100 = 4 12 = 1100 = C 5 = 0101 = 5 13 = 1101 = D 6 = 0110 = 6 14 = 1110 = E 7 = 0111 = 7 15 = 1111 = F Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 72. What is the Address on my NIC? 9 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 73. MAC Addresses Are Flat 10  MAC addresses provide a way for computers to identify themselves.  They give hosts a permanent, unique name.  The number of possible MAC addresses is 16^12 (or over 2 trillion!).  MAC addresses do have one major disadvantage:  They have no structure, and is considered flat address space.  Like using just a name when sending a letter instead of a structured address. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 74. Generic Data Link Frame 11  A message is “framed” (layer 2) and transmitted on the cable (layer 1) by the Ethernet NIC.  Framing provides order, or structure, to the stream of bits, bitstream. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 75. Bringing it all together… 12  Let’s pause here for a moment and figure all of this out!  Let’s bring the following together:  Ethernet Frames and MAC Addresses  Sending and receiving Ethernet frames on a bus  CSMA/CD  Sending and receiving Ethernet frames via a hub  Sending and receiving Ethernet frames via a switch Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 76. Serial vs Multiaccess Network 13Serial Multiaccess Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 77. 14 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 78. Ethernet: Multiaccess Network 15 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 79. Bus Topology 16 A bus topology uses a single backbone segment (length of cable) that all the hosts connect to directly. Original Ethernet used a bus topology. By the way, Ethernet hubs work the same as a “bus”. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 80. Sending and receiving Ethernet frames on a bus 17  When an Ethernet frame is sent out on the “bus” all devices on the bus receive it.  What do they do with it? 1111 2222 3333 nnnn Abbreviated MAC Addresses 11113333 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 81. Sending and receiving Ethernet frames on a bus 18  When information (frame) is transmitted, every PC/NIC on the shared media copies part of the transmitted frame to see if the destination address matches the address of the NIC.  If there is a match, the rest of the frame is copied  If there is NOT a match the rest of the frame is ignored.  Unless you are running a protocol analyzer program such as Ethereal. 1111 2222 3333 nnnn Abbreviated MAC Addresses 11113333 Nope Nope Hey, that’s me! Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 82. Sending and receiving Ethernet frames on a bus 19  So, what happens when multiple computers try to transmit at the same time? 1111 2222 3333 nnnn Abbreviated MAC Addresses Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 83. Sending and receiving Ethernet frames on a bus 20 Collision! 1111 2222 3333 nnnn Abbreviated MAC Addresses X Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 84. Access Methods 21 Two common types of access methods for LANs include  Non-Deterministic: Contention methods (Ethernet, IEEE 802.3)  Only one signal can be on a network segment at one time.  Collisions are a normal occurrence on an Ethernet/802.3 LAN  Deterministic: Token Passing (Token Ring) Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 85. CSMA/CD (Carrier Sense Multiple Access with Collision Detection) 22 CSMA/CD Common contention method used with Ethernet and IEEE 802.3  “Let everyone have access whenever they want and we will work it out somehow.” Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 86. CSMA/CD and Collisions 23 CSMA/CD (Carrier Sense Multiple Access with Collision Detection)  Listens to the network’s shared media to see if any other users on “on the line” by trying to sense a neutral electrical signal or carrier.  If no transmission is sensed, then multiple access allows anyone onto the media without any further permission required.  If two PCs detect a neutral signal and access the shared media at the exact same time, a collision occurs and is detected.  The PCs sense the collision by being unable to deliver the entire frame onto the network. (This is why there are minimum frame lengths along with cable distance and speed limitations. This includes the 5-4-3 rule.)  When a collision occurs, a jamming signal is sent out by the first PC to detect the collision.  Using either a priority or random backoff scheme, the PCs wait certain amount of time before retransmitting.  If collisions continue to occur, the PCs random interval is doubled, lessening the chances of a collision. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 87. CSMA/CD and Collisions 24 And as we said,  When information (frame) is transmitted, every PC/NIC on the shared media copies part of the transmitted frame to see if the destination address matches the address of the NIC.  If there is a match, the rest of the frame is copied  If there is NOT a match the rest of the frame is ignored. 1111 2222 3333 nnnn Abbreviated MAC Addresses 11113333 Nope Nope Hey, that’s me! Notice the location of the DA! Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 88. Sending and receiving Ethernet frames via a hub 25  Only one device on the hub can communicate at a time, otherwise collisions occur.  10 Mbps ports are the most common.  100/1000 Mbps also “available”.  The hub acts the same as a “bus”. Hub or Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 89. Sending and receiving Ethernet frames via a hub 26  So, what does a hub do when it receives information?  A hub is nothing more than a multiport repeater. 1111 2222 3333 4444 5555 ? 11113333 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 90. Repeaters 27  Signals can only travel so far through media before they weaken, and become garbled.  This weakening of signals is called attenuation.  Attenuation increases when:  Media distances are lengthened  Nodes are added to the media  Repeaters:  take in weakened signals  clean them up  regenerate them  send them on their way along the network Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 91. Repeater: Layer 1 Device 28  Repeaters are Layer 1 devices.  They do NOT look at:  Layer 2, Data Link (MAC, Ethernet) addresses  Layer 3, IP Addresses. Signal come in … signal go out. (after I amplify it) Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 92. Hub 29  Hub is nothing but a multiport repeater.  Hubs are Layer 1 devices.  Data that comes in one port is sent out all other ports, except for the port it came in on. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 93. Hubs 30  Hubs allow computers and other network devices to communicate with each other, and use a star topology.  Like a repeater, a hub regenerates the signal.  Hubs have the same disadvantage as a repeater, anything it receives on one port, it FLOODS out all other ports.  Wherever possible, hubs should be replace by switches. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 94. Sending and receiving Ethernet frames via a hub 31  The hub will flood it out all ports except for the incoming port.  Hub is a layer 1 device.  A hub does NOT look at layer 2 addresses, so it is fast in transmitting data.  Disadvantage with hubs: A hub or series of hubs is a single collision domain (coming)  A collision will occur if any two or more devices transmit at the same time within the collision domain. 1111 2222 3333 4444 5555 11113333 Nope Nope Nope For me!Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 95. Sending and receiving Ethernet frames via a hub 32  Another disadvantage with hubs is that is take up unnecessary bandwidth on other links. 1111 2222 3333 4444 5555 11112222 Nope Nope Nope For me! Wasted bandwidth Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 96. Sending and receiving Ethernet frames via a hub 33  What happens when two hosts on the same hub, or when multiple hubs are connected, transmit at the same time? 1111 2222 3333 4444 5555 ? 11112222 33334444 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 97. Sending and receiving Ethernet frames via a hub 34  Collision occurs.  Although, hubs have little latency, CSMA/CD requires resending of frames and adds latency. 1111 2222 3333 4444 5555 Collision 11112222 33334444 X Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 98. Half-duplex (Introduction) 35  Hubs operate only in Half-duplex.  Half-duplex means that only one end can send at a time.  With half-duplex NICs, a host can only transmit or receive, not both at the same time, or a collision will occur.  When multiple devices are connected to a hub or series of hubs, only one device can transmit.  Uses CSMA/CD.  If the a carrier is detected, then the NIC will not transmit.  Ethernet hubs and repeaters can only operate in half-duplex mode. Half-duplex Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 99. Half-Duplex mode 36  All of these Ethernet NICs and ports on the hubs are operating in Half-Duplex mode.  When multiple devices are connected to a hub or series of hubs, only one device can transmit. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 100. Collision Domain: Shared Access 37  Collision domain (Wikipedia): A group of Ethernet or Fast Ethernet devices in a CSMA/CD LAN that are connected by repeaters/hubs and compete for access on the network.  Only one device in the collision domain may transmit at any one time, and the other devices in the domain listen to the network in order to avoid data collisions.  A collision domain is sometimes referred to as an Ethernet segment.  If you connect several computers to a single medium that is only connected by repeaters and hubs (Layer 1 devices), you have a shared-access situation, and you have a single collision domain. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 101. Full-duplex 38  Full-duplex is allows simultaneous communication between a pair of stations or devices.  Full-duplex allows devices to send and receive at the same time.  Both ends of the link must be in full-duplex mode.  In full-duplex, the station ignores any collision detect signals that come from the transceiver.  If a hub is connected to a switch, the switch port must be in half-duplex.  The collision domain will end at the switch port.Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 102. Where are the collision domains? What would be the duplex settings? 39 hub hub hub hub hub hub hub hub router Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 103. Where are the collision domains? 40 hub hub hub hub hub hub hub hub router Single Collision Domain Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 104. What would be the duplex settings? 41 hub hub hub hub hub hub hub hub router Half-duplex Half-duplex hub Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 105. Where are the collision domains? What would be the duplex settings? 42 hub hub hub hub hub hub switch switch router Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 106. Switched Ethernet  Switches forward and filter frames based on LAN addresses  It’s not a bus or a router (although simple forwarding tables are maintained)  Very scalable  Options for many interfaces  Full duplex operation (send/receive frames simultaneously)  Connect two or more “segments” by copying data frames between them  Switches only copy data when needed  key difference from repeaters  Higher link bandwidth  Collisions are completely avoided  Much greater aggregate bandwidth  Separate segments can send at once 43 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 107. Sending and receiving Ethernet frames via a switch 44  Layer 2 device (also includes layer 1) which examines and bases its decisions on the information in layer 2 frames  Switch ports typically operate in full-duplex.  Multiple devices on the switch can communicate at a time, otherwise collisions occur.  10/100 Mbps ports are the most common.  1000 Mbps also are also common, usually connecting to another switch or router. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 108. Where are the collision domains? What would be the duplex settings? 45 hub hub hub hub hub hub switch switch router Collision Domains Collision Domains Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 109. What would be the duplex settings? 46 hub hub hub hub hub hub switch switch router Half-duplex Half-duplex Full-duplex hub Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 110. Where are the collision domains? What would be the duplex settings? 47 switch hub hub switch switch switch switch switch router Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 111. Where are the collision domains? 48 switch hub hub switch switch switch switch switch router Collision Domains Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 112. What would be the duplex settings? 49 switch hub hub switch switch switch switch switch router Full-duplex Half-duplex Full-duplex switch Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 113. All scenarios are multiaccess networks 50 switch hub hub switch switch switch switch switch router Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 115. 52 11 22 33 44 55 66 Hub Hub Half-duplex CSMA/CD Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 116. 53 11 22 33 44 55 66 Switch Switch MAC Address Table Port Source MAC Add. Port Source MAC Add. MAC Address Table Port Source MAC Add. Port Source MAC Add. Full-duplex No CSMA/CD Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 117. Full-duplex 54  Full-duplex is an optional mode of operation allowing simultaneous communication between a pair of stations or devices.  Specified in IEEE 802.3x in March 1997 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 118. Full-duplex 55  Full-duplex Ethernet allows the transmission of a packet and the reception of a different packet at the same time.  The full-duplex Ethernet switch takes advantage of the two pairs of wires in the cable by creating a direct connection between the transmit (TX) at one end of the circuit and the receive (RX) at the other end.  Half Duplex Ethernet usually can only use 50%-60% of the available 10 Mbps of bandwidth because of collisions and latency.  Full-duplex Ethernet offers 100% of the bandwidth in both directions.  10 Mbps Ethernet: This produces a potential 20 Mbps throughput, which results from 10 Mbps TX and 10 Mbps RX. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 119. Full-duplex 56  IEEE 802.3x full-duplex standard requires:  The medium must have independent transmit and receive data paths that can operate simultaneously.  There are exactly two stations connected with a full- duplex point-to-point link.  There is no CSMA/CD multiple access algorithm, since there is no contention for a shared medium.  Both stations on the LAN are capable of, and have been configured to use, the full- duplex mode of operation.  Ethernet hubs and repeaters can only operate in half-duplex mode. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 120. Half-duplex Controller 57  With half-duplex NICs,a host can only transmit or receive.  If the a carrier is detected, then the NIC will not transmit.  In full-duplex the station ignores the carrier sense and does not defer to traffic being received on the channel.  In full-duplex, the station ignores any collision detect signals that come from the transceiver.  Ethernet hubs and repeaters can only operate in half-duplex mode. Half-duplex controllers Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 121. Full-duplex 58  Both half-duplex and full-duplex Ethernet uses an interframe gap (IFG).  Full-duplex uses the IFG to ensure that the interfaces at each end of the link can keep up with the full frame rate of the link.  CSMA/CD not used in full-duplex Ethernet:  No CS (Carrier Sense) – In full-duplex the station ignores carrier sense since it can send whenever it likes.  No MA (Multiple Access) – Since there is only one station at the other end of the link and the Ethernet channel between them is not the subject of access contention.  No CD (Collision Detect) – Since there is no access contention, there will be no collisions, and station can ignore CD. Ethernet Frame IFG Ethernet Frame IFG Ethernet Frame IFG Ethernet Frame IFG Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 122. Full-duplex 59  There are exactly two stations connected with a full-duplex point-to-point link.  Both stations on the LAN are capable of, and have been configured to use, the full-duplex mode of operation.  Typically:  Host-to-Switch  Switch-to-Switch  Switch-to-Router Full-duplex Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 124. Learning Switches: Learns Source MAC Address 61MAC Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 switch 1111 2222 3333 4444 Abbreviated MAC addresses 11113333  Switches are also known as learning bridges or learning switches.  A switch has a source address table (or MAC Address Table) in cache (RAM) where it stores a source MAC address after it learns about them.  How does it learn source MAC addresses?  Whenever a frame enters a switch, it will first see if the Source Address (1111) is in it’s table.  If it is, it resets the timer (more in a moment).  If it is NOT in the table it adds it, with the port number.Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 125. Destination MAC Address: Filter or Flood 62MAC Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 switch 1111 2222 3333 4444 Abbreviated MAC addresses 11113333  Next, the switch examines the source address table for the Destination MAC address.  If it finds a match, it filters the frame by only sending it out that port.  If there is not a match if floods it out all ports.  In this scenario, the switch will flood the frame out all other ports, because the Destination Address is not in the source address table. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 126. Learning Switches: Learns, Filter or Flood 63MAC Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 6 3333 switch 1111 2222 3333 4444 Abbreviated MAC addresses 33331111  Most communications involve some sort of client-server relationship or exchange of information. (You will understand this more as you learn about TCP/IP.)  Now 3333 sends data back to 1111.  The switch sees if it has the Source Address stored.  It does NOT so it adds it. (This will help next time 1111 sends to 3333.)  Next, it checks the Destination Address and in our case it can filter the frame, by sending it only out port 1. Soft Polynomials (I) Pvt. Ltd.
  • 127. Destination Address in table, Filter 64MAC Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 6 3333 switch 1111 2222 3333 4444 Abbreviated MAC addresses 11113333 33331111  Now, because both MAC addresses are in the switch’s table, any information exchanged between 1111 and 3333 can be sent (filtered) out the appropriate port.  What happens when two devices send to same destination?  What if this was a hub?  Where is (are) the collision domain(s) in this example? Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 128.  Unlike a hub, a collision does NOT occur, which would cause the two PCs to have to retransmit the frames.  Collision domains end at the switch  Instead the switch buffers the frames and sends them out port #6 one at a time.  The sending PCs have no idea that their was another PC wanting to send to the same destination. No Collisions in Switch, Buffering 65MAC Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 6 3333 9 4444 switch 1111 2222 3333 4444 Abbreviated MAC addresses 11113333 44443333 Soft Polynomials (I) Pvt. Ltd.
  • 129. MAC Duplex – No collisions 66  When there is only one device on a switch port, the collision domain is only between the PC and the switch, which is non-existent with full- duplex.  With a full-duplex PC and switch port, there will be no collision, since the devices and the medium can send and receive at the same time. MAC Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 6 3333 9 4444 switch 1111 2222 3333 4444 Abbreviated MAC addresses 11113333 44443333 No Collision Domains Soft Polynomials (I) Pvt. Ltd.
  • 130. Other Information 67  How long are addresses kept in the Source Address Table?  5 minutes is common on most vendor switches.  How do computers know the Destination MAC address?  ARP Caches and ARP Requests (later)  How many addresses can be kept in the table?  Depends on the size of the cache, but 1,024 addresses is common.  What about Layer 2 broadcasts?  Layer 2 broadcasts (DA = all 1’s) is flooded out all ports. MAC Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 6 3333 9 4444 switch 1111 2222 3333 4444 Abbreviated MAC addresses Soft Polynomials (I) Pvt. Ltd.
  • 131. What happens here? 68  Notice the Source Address Table has multiple entries for port #1. 33331111 3333 1111 MAC Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 6 3333 1 2222 1 5555 2222 5555 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 132. What happens here? 69  The switch resets the 5 minute timer on the source port entry.  The switch filters the frame out port #1.  But the hub is only a layer 1 device, so a hub floods it out all ports.  Where is the collision domain? 33331111 3333 1111 MAC Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 6 3333 1 2222 1 5555 2222 5555 Reset timer Filter Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 133. What happens here? 70 33331111 3333 1111 Source Address Table Port Source MAC Add. Port Source MAC Add. 1 1111 6 3333 1 2222 1 5555 2222 5555 Collision Domain Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 135. Unshielded Twisted Pair (UTP) 72 Straight-through Cross-over Rollover www.cisco.com/warp/ public/701/14.html Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 136. UTP Straight-through Cable 73  The cable that connects from the switch port to the computer NIC port is called a straight-through cable.  Connects unlike devices. Host or RouterHub or Switch Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 137. UTP Straight-through Cable 74 Host or RouterHub or Switch Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 138. UTP Cross-over Cable 75  The cable that connects from one switch port to another switch port is called a crossover cable.  Connects like devices. Hub or Switch Hub or Switch Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 139. UTP Cross-over Cable 76 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 140. Cabling – Show the straight-through and cross-over cables 77 hub hub hub hub hub hub switch switch router Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 141. Cabling – Show the straight-through and cross-over cables 78 hub hub hub hub hub hub switch switch router Straight-through cable Cross-over cable Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 142. Configuring Speed and Duplex 79  Negotiation between NIC and switch port.  Duplex: Full-duplex or Half- duplex  Speed: 10/100/1000 Mbps  Autonegotiation  Both sides of a link should have auto-negotiation on, or both sides should have it off. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 143. When to Use Ethernet 10/100Mb Auto- Negotiation – From www.cisco.com 80  Auto-negotiation is an optional function of the IEEE 802.3u Fast Ethernet standard that enables devices to automatically exchange information over a link about speed and duplex abilities.  Auto-negotiation is targeted at ports which are allocated to areas where transient users or devices connect to a network.  For example, many companies provide shared offices or cubes for Account Managers and System Engineers to use when they are in the office rather than on the road.  Each office or cube will have an Ethernet port permanently connected to the office's network.  Because it may not be possible to ensure that every user has either a 10Mb, a 100Mb Ethernet, or a 10/100Mb card in their laptop, the switch ports that handle these connections must be able to negotiate their speed and duplex mode.  The alternative would be to provide both a 10Mb and a 100Mb port in each office or cube and label them accordingly. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 144. When to Use Ethernet 10/100Mb Auto- Negotiation – From www.cisco.com 81  One of the most common causes of performance issues on 10/100Mb Ethernet links is when one port on the link is operating at half- duplex while the other port is operating at full-duplex.  This occasionally happens when one or both ports on a link are reset and the auto-negotiation process doesn't result in both link partners having the same configuration.  It also happens when users reconfigure one side of a link and forget to reconfigure the other side.  Both sides of a link should have auto-negotiation on, or both sides should have it off.  Our current recommendation is to leave auto-negotiation on for those devices compliant with 802.3u.  Many performance-related support calls will be avoided by correctly configuring auto-negotiation. Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 145. Half-duplex, Full-duplex Issue 82  Switch A, the half-duplex end will sense a neutral carrier and send frames  Switch B, the full-duplex end, senses the non-neutral carrier and since it doesn’t care because it is configured as full-duplex, it transmits anyways.  Switch A senses a collision (the half-duplex side) and stops sending the frame.  Switch B (the full-duplex side) doesn’t care and keeps on sending frames.  Data ends up being transmitted only one-way most of the time, with collisions constantly happening on Switch A, causing performance issues on the network. (Remember, most network communications is bi-directional.  This is also a common cause for late collisions (a collision that occurs after the first 512 bits (slot time) have been sent and the sender believes it has acquired the channel. Half-duplex Full-duplex Switch A or Hub A Switch B Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 146. Real World Troubleshooting - Symptom 83 switch switch switch switch switch switch switch switch router A B C D W X Y Z  Hosts connected to switches B, C and D can reach each other and the Internet with no problems.  However, hosts on X, Y, and Z can either not access hosts on B, C, and D or the Internet, or if they can it is extremely slow. Internet Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 147. Lights and indicators 84 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 148. Real World Troubleshooting – Diagnostics 85 switch switch switch switch switch switch switch switch router A B C D W X Y Z  You notice that a collision light (or looking at some diagnostic output) on Switch W, port 1 is always on indicating a very large number of collisions detected on that port. Internet Port 1 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 149. Real World Troubleshooting – Problem 86 switch switch switch switch switch switch switch switch router A B C D W X Y Z  The problem is that  Switch A, Port 8 is in Full-duplex mode  Switch W, Port 1 is in Half-duplex mode  Switch A sends whenever it wants to without listening first to see if Switch W is sending. Internet Half Duplex Port 1 Full Duplex Port 8 I’m half-duplex and I keep seeing collisions I’m full-duplex so I don’t see any collisions X Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 150. Real World Troubleshooting – Solution 87 switch switch switch switch switch switch switch switch router A B C D W X Y Z  Configure Switch W, Port 1 to be in full duplex, the same as Switch A, Port A. Internet Full Duplex Transmissions Full Duplex Port 8 Full Duplex Port 1 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 152. Fast and Gigabit Ethernet  Fast Ethernet (100Mbps) has technology very similar to 10Mbps Ethernet  Uses different physical layer encoding (4B5B)  Many NIC’s are 10/100 capable  Can be used at either speed  Gigabit Ethernet (1,000Mbps)  Compatible with lower speeds  Uses standard framing and CSMA/CD algorithm  Distances are severely limited  Typically used for backbones and inter-router connectivity  Becoming cost competitive  How much of this bandwidth is realizable 89 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 153. Experiences with Ethernet  Ethernets work best under light loads  Utilization over 30% is considered heavy  Network capacity is wasted by collisions  Most networks are limited to about 200 hosts  Specification allows for up to 1024  Most networks are much shorter  5 to 10 microsecond RTT  Transport level flow control helps reduce load (number of back to back packets)  Ethernet is inexpensive, fast and easy to administer! 90 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 154. Ethernet Problems  Ethernet’s peak utilization is pretty low (like Aloha)  Peak throughput worst with  More hosts  More collisions needed to identify single sender  Smaller packet sizes  More frequent arbitration  Longer links  Collisions take longer to observe, more wasted bandwidth  Efficiency is improved by avoiding these conditions 91 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 155. Why did Ethernet Win?  There are LOTS of LAN protocols  Price  Performance  Availability  Ease of use  Scalability 92 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head
  • 156. T H A N K Y O U Done – Lets Network to the Real World NOW 93 Soft Polynomials (I) Pvt. Ltd. Subhash Iyer, Program Head