You are on page 1of 29

Chapter 6: Book 2 : Medium Access Sublayer

MAC:
• Medium Access Control Layer.
• Between DLL and Physical Layer.
• This section deals with broadcast networks and their protocols.
• The basic idea behind broadcast networks is how to determine who gets to use the channel when many users
want to transmit over it.
• The protocols used to determine who goes next on a multiaccess channel belong to a sublayer of the data link
layer called MAC.

MAC Functions:
• receive/transmit normal frames
• half-duplex retransmission and backoff functions
• append/check FCS (frame check sequence)
• Inter-frame gap enforcement
• discard malformed frames
• append(tx)/remove(rx) preamble, SFD(Start Frame Delimiter), and padding
• half-duplex compatibility: append(tx)/remove(rx) MAC address
What is the need for arbitration?
• Introduction and need for MAC layer
– Shared Channel Concept
– Collision detection and avoidance
– Channel acquisition issues
– Ad-hoc and Infrastructure modes
• When shared channel is used to communicate, issue of who will transmit arise.
• Rules to allocate each a fair chance to communicate:
– One should not dominate the communication for more than appropriate time.
– Whenever somebody is communicating, others should keep quiet.
– There must be some arbitration mechanism to allow only one from that lot of communicating parties.
• Suppose no arbitration mechanism:
– Two or more person starts communication.
– Collision realized and they stop abruptly.
– Retry after some time.
– This process continues until one of them gets the chance.
• Arbitrator:
– The one who unambiguously determine to the order speakers.
– Must have clear cut arbitration policy.
– Conscious about his role and must be unbiased.
• MAC:
– In networks, this job is performed by MAC Medium Access Control sub layer.
– This layer sits between physical and data link layer.

Asst. Prof. Riddhi Joshi


Page 1
Chapter 6: Book 2 : Medium Access Sublayer
– DLL has two parts : 1) LLC, logical link layer control 2) MAC.

Collision Detection & Avoidance:


• Collision garble the frames.
• Collision Detection:
– Let collision happen and then solve it.
– If sender detects collision, it can stop sending and restart later by following „binary back-off
algorithm‟.
– Need a mechanism to listen to channel.
– Used by classic Ethernet.
• Collision Avoidance:
– See that collision do not occur by carefully avoiding it.
– Here, it is possible to extract any component signal from collided signal. So retransmission is not
needed. We just extract what we need from the received signals.
– Preferred by 802.11 wireless LANs.
– CDMA Code Division Multiple Access is used in Mobile phones.

Channel Acquisition Solutions:


• Sender transmit whenever wishes to
– First version of Ethernet and 802.11 or WiFi
• Using token as a prerogative to transmit
• Reservation before sending
– Two phase strategy
– Phase 1: Sending parties get reservation
– Phase 2: Data transmission takes place
• The sender sends only if receiver confirms, intimates neighbor to remain quite.
– in wireless 802.11 case, ad-hoc mode
• Central authority to decide who acquired the channel
– 802.11 using access points

Network Classification: Ad-hoc & Infrastructure Mode


• Infrastructure Mode:
– Access point works as arbitrator.
– All communication happens with access point‟s permission.
– So no probability of collision.
– Called PCF, Point Co-ordination Function.
• Ad-hoc Mode:
– Directly communicates, so chance of collision.
– Has problem of Hidden Station and Exposed Station problem.
– Uses RTS and CTS(Request To Send and Clear To Send)
– Called DCF, Distributed Co-ordination Function.
• By standard, DCF is compulsory, while PCF is not.
• Almost all 802.11 LANs implement both.
• Wired MAC is easy and has less collision issue like hidden and exposed station problem, whereas, Wireless
MAC is a bit complex.

Asst. Prof. Riddhi Joshi


Page 2
Chapter 6: Book 2 : Medium Access Sublayer

Infrastructure or PCF(Point Coordination Function) mode:

Ad hoc Mode, DCF (Distributed Coordination Function):

Both modes together in same network:

Asst. Prof. Riddhi Joshi


Page 3
Chapter 6: Book 2 : Medium Access Sublayer

Q. Wired MAC Layer: Topic List

• ALOHA and Slotted ALOHA


• Ethernet
– Fast Ethernet
– Gigabit Ethernet
– The 10 Gb Ethernet
– Future versions
• Dual speed cards, auto-negotiation and upgrades
• 802.2, the LLC layer

Q.ALOHA
• Norman Abramson at University of Hawaii, in 70‟s wanted to connect computer centers of all the islands of
Hawaii.
• Hawaii is a collection of islands and it was not possible to connect them with telephone lines.
• Joining islands with wires laid on seabed was very expensive, so they started thinking about wireless solution.
• Solution: ALOHA
– Using short range radios.
– Half duplex by nature. At a time, only can send or receiver. Switching also takes time.
– Two different frequencies, one for sending, another for receiving.
– But, problem of collision, how to solve it?
– Solution: Let the users communicate, if signals collide, not acknowledged and so, sender resends data.
– Adding randomness reduces the chance of collision.
– Algorithm is called Binary Exponential Back-off Algorithm.
– Also had problem: While transmitting, sender can not sense collision.
– In ALOHA, maximum 18 out of 100 packets pass without collision if ALOHA works with optimum
speed.

Asst. Prof. Riddhi Joshi


Page 4
Chapter 6: Book 2 : Medium Access Sublayer
The collision Problem in ALOHA

Slotted ALOHA:
• Solution: Slotted ALOHA
– Robert, in 1972 proposed a scheme.
– Packets are vulnerable to collide with only those packets which were transmitted before, but not
during the lifetime.
– He divided timeslots equal to lifetime of packets.
– Packet can be transmitted only in beginning of next slot only.
– Slotted ALOHA introduces additional delay.
– Eg : B is to be transmitted during A‟s lifetime, B will be delayed till next slot.
– Thus, reducing collision probability to half and performance is doubled.
– In slotted ALOHA, 36 out of 100 packets are delivered without collision at optimum speed.
– In slotted ALOHA time is divided into discrete intervals, each corresponding to one frame.
– A computer is not permitted to send whenever it has data to send.
– Instead it is required to wait for the next available slot.
• Well, it still needs improvement.
• See next figures that explain Slotted ALOHA.

Asst. Prof. Riddhi Joshi


Page 5
Chapter 6: Book 2 : Medium Access Sublayer

Q.Ethernet:
• Bob Metcalfe and David Boggs are the master mind behind Ethernet design.
• All system is connected to single central bus using vampire tap and T-connector.
• Bus is made up of co-axial cable having capacity of 2.94 Mbps.
• Later intel and DEC joined and offered upto 10Mbps.
• This standard was named as DIX By Digital Equipment Co-operation, Intel and Xerox.
• Later it joined with Compaq and HP.
• This model was found far superior than design of Aloha.
• Characteristics:
– Sender can listen to every node before transmitting and so can stop if somebody is already
transmitting.
– If channel is idle, can start transmitting. If more than 1 sender started transmission, sender
immediately realize collision, stop.
– Then it follows binary exponential back-off algorithm and try after random amount of time.
– Collision occur only if the first sender‟s signal has not reached the second sender.
– If collision occurred, start with min 64 bytes pkt size and less than 2500meters distance covering
limit. This limits loss and bandwidth wastage.
– To inform others that collision has occurred, sender sends JAM Signals.
• Poor design for heavy traffic.
• The design was corrected by evolving Fast Ethernet (100 Mbps) and Gigabit Ethernet (1000 Mbps, i.e 1Gbps)
and now 10G (10 Gbps).
Ethernet First Version with Bus Topology:

A. Classic Ethernet 802.3


 Two standards, DIX(DEC, Intel and Xerox) which later became 802.3 (IEEE).
 IEEE assigns a unique number to every standard. Ethernet is assigned 802.3.
 Initially Bus and Hubs were used
 Later switches took over
 Simple Principle: „Let everyone transmit whenever they wish to without any formalities.‟
 Classic Ethernet provide 10Mb communication using Manchester Encoding Technique.
 Types of connection: See next table.
– Cat-3 Twisted Pair
– Thin Co-ax
– Thick Co-ax
– Fiber Optics
 Problems: Twisted Pair
– It is difficult to attach nodes using coaxial or cat-3 cables.

Asst. Prof. Riddhi Joshi


Page 6
Chapter 6: Book 2 : Medium Access Sublayer
– A machine cannot be added or removed without affecting others.
– Total capacity is shared which reduces overall capacity for single user.
– Maintenance is difficult.
 Problems: Co-axial
– Difficult to locate where the fault is.
 Solution: Fiber Optics Cable
– More immune to error
– Support long distance transmission
 Cat 3 has limited its use with star topology with following advantages:
– A node can be added or replaced without disturbing other nodes.
– When switches are deployed, node can enjoy complete 10Mb bandwidth.
– Maintenance is simpler as it is easy to detect faulty node.
 Fiber Optics Cable:
– Best distance, 10 Mbps for 100s of KM without the help of repeaters.
– Can minimize the errors.
– Less affected by disturbance and magnetism.
– Initially costly but later bulk production reduced cost too.
– Better immunity to noise.
– Only Problem: Shortage of trained manpower.
 Manchester Encoding:
– Digital Signalling
– Also called Baseband Signalling.
– Hence base is added to the names.
– Name carry the features “10 Base 5” means 10 Mbps bandwidth digital signal with 500 m distance
covered by co-ax cable.
Length
Name Type Advantage
(Max)
10Base5 Thick coax 500 m Good interconnection option.
Flexible and easy to maneuver. It can bend
10Base2 Thin coax 200 m
easily than the thicker cable.
10BaseT UTP (cat-3) 100 m Best for Star topology.
Best option for interconnection. Best noise
10BaseF Fiber optics 2 km
immunity.

Ethernet Topology Bus and Ring:


• Traditionally bus topology is used with co-oxial cables. Unique problems related to maintenance:
– Thicker coaxial cables use vampire taps for connection. The taps need to be inserted carefully in wire.
Unexperienced engineer may fail to do it with perfection. See next 2 fig.
– Thinner version use BNC connector which require network shut down before joining individual cable.
Inconvenient for existing users.

Asst. Prof. Riddhi Joshi


Page 7
Chapter 6: Book 2 : Medium Access Sublayer
– Bandwidth shared among all users. Thicker cables accommodating 100 users getting 10Mbps. Thin cables
can support 30 users who share 10Mbps.
– A malfunctioning node may disrupt entire network in form of bus or ring.

BNC Connector and Vampire Taps

Star Topology:
• Better solution for maintenance if used with hub or switch.
• Hub broadcast data to all other nodes.
• Switch is selective in receiver.
• Disadvantage of hub:
– It is more prone to collision when multiple senders are transmitting.
– Also, broadcast consume bandwidth.
• Solution Switch.
• See next figure depicting logical and physical view.

Star Topology Logical View: Star Topology Physical View:

Cascading the network:


• Practically, most implementations are cascaded.
• Here central device is connected to another central device.
• It is interesting to see some of the ports are not connected to any machine.
• Such ports help network to grow.
• Whenever a new node is required to be added, such empty ports are handy.

Asst. Prof. Riddhi Joshi


Page 8
Chapter 6: Book 2 : Medium Access Sublayer

Using Switch instead of Hub:


• Hub is like repeater hence called multi port repeater.
• Switch has storage capacity and provides point to point transmission.
• Assume in next fig, A is transmitting to B and C is transmitting to D using different path.
• Gives benefit of bandwidth but a bit costly which replaced hubs.
• Is there a chance of collision?
• Yes. If user sends and receive at same time, using same port, it may collide with itself. So, collision domain is
reduced to itself.
• Solution?
• Use different path for sending and receiving.
• Switch improved the performance by reducing collision domain

Ethernet Frame Structure DIX and IEEE:

Asst. Prof. Riddhi Joshi


Page 9
Chapter 6: Book 2 : Medium Access Sublayer

(a) DIX Ethernet (original DEC, Intel, Xerox)


(b) IEEE 802.3 – two changes to DIX:
1. Reduce preamble to 7 bytes and include a Start-Of-Frame (SOF) delimiter (compatible with 802.4
and 802.5)
2. Change Type field into Length field
 Preamble contains 8 bytes having bit pattern 10101010 in DIX and 1010101 SOP:1 in IEEE 802.3.
 Two address fields source and destination has:
o 0 for ordinary address
o 1 for group address (multicast, all 1‟s then broadcast)
 Type specifies what to do with frame, specifies that which process should be given to frame.
 Data field contains upto 1500 bytes.
 If data portion of frame is less than 46 bytes, Pad field is used to fill out frame to minimize chances of
collision.
 Final field is checksum which contains #code of 32 bits.

Y valid frame must be at least 64 bytes long?


• Two reasons:
1. When transceiver detects collision, it truncates current frame.
o Means, stray bits & piece of frames appear on cable all the time.
o To make easily distinguish valid frames from garbage frames, valid frames must be at least 64 bytes long.
2. At time =0, station A transmit a frame to station B.
o Just before frame reaches another end, station B starts transmitting.
o When B detects collision, it generates 48bit Noise Burst to warn all other stations.
o That means all station are jammed for random amount of time to start trying again for transmission.
o If, station tries to transmit shorter frames, & if collision occurs, transmission gets completed before noise
burst reaches sender station.
o And sender wrongly conclude that frame was successfully sent.

Multiplexing at Ethernet:

Asst. Prof. Riddhi Joshi


Page 10
Chapter 6: Book 2 : Medium Access Sublayer

Q.CSMA:
TYPES:
1. Persistent CSMA
2. Non Persistent CSMA
3. P Persistent CSMA
4. CSMA/CD

Carrier Sense Multiple Access (CSMA):


 Protocols in which stations listen for a carrier (i.e. transmission) and act accordingly are called carrier sense
protocols.
 1-persistent CSMA
o Channel Busy  Continue sensing until free and then grab.
o Channel Idle  Transmit with probability 1.
o Collision  Wait for a random length of time and try again.
 Non-persistent CSMA:
o Channel Busy  Does not continually sense the channel. Wait for a random length of time and try
again.
o Channel Idle  Transmit.
o Collision  Wait for a random length of time and try again.
 P-persistent CSMA:
o Channel Busy  Continue sensing until free (same as idle).
o Channel Idle  Transmit with probability p, and defer transmitting until the next slot with probability
q = 1-p.
o Collision  Wait for a random length of time and try again.
 Analysis:
o The non-persistent CSMA has better channel utilization but longer delays than 1-persistent CSMA.
o CSMA are an improvement over ALOHA because they ensure that no station begins to transmit when
it senses the channel busy.
o Another improvement is for stations to abort their transmissions as soon as they detect a collision.
o Quickly terminating damaged frames saves time and bandwidth.
o This protocol is called CSMA/CD (CSMA with Collision Detection).
 Carrier Sense: Ethernet card listen to channel before transmission and differ to transmit if somebody else is
already transmitting.
 Multiple Access: More than one user needs channel access.
 Collision Detection: Protocol listen when transmission is going on and find stop transmitting when it finds
colliding.
 Interframe gap: As soon as channel becomes free, it waits for small interframe gap and then transmits.
Interframe gap is idle time between frames. After a frame has been sent, transmitters are required to transmit a
minimum of 96 bits (12 octets) of idle line state before transmitting the next frame.
 Maximum distance limitation: Frame size min 64 bytes.
 Minimum frame size limitation: Frame length min 250 m.
 Both, distance and size can not be increased together.
 More bandwidth deteriorates performance.
 If first 64 bytes are successfully received, means later there would be no collision.

Q.Binary Exponential Backoff:


 Sender sends immediately with idle channel
 Continues to listen while transmitting
 In case of a collision, the sender waits for a random period (maximum of two time slots)
 In case they collide again, the interval is just doubled every time it experiences a collision,
 When doubling is repeated to the slot size to 0–1023 it will not increase further
 Time is divided into discrete slots whose length is equal to the worst-case round-trip propagation time on the
either (2τ).

Asst. Prof. Riddhi Joshi


Page 11
Chapter 6: Book 2 : Medium Access Sublayer
 minimum frame is 64 bytes (header + 46 bytes of data) = 512 bits
 Channel capacity 10 Mbps, 512/10 M = 51.2µ
 After 1st collision, each station waits for 0 or 1 time slot before trying again.
 After 2nd collision, each station picks up either 0,1,2 or 3 at random and waits for that much time slots.
 If 3rd collision occurs, then next time number of slots to wait is chosen randomly from interval 0 to 23 -1.
 In general, after ith collision, random number between 0 to 2i -1 is chosen, that number of time slot is skipped.
 After 10th collision, randomized interval is frozen at max of 1023 slots.
 After 16th collision, controller reports failure back to computer sending and further recovery is upto higher
layers.
 This algorithm is called Binary Exponential Back off Algorithm.
 Advantage: Ensures a low delay when only a few stations collide, but also assures that the collision is resolved
in a reasonable interval when many stations collide.
 Disadvantage: Could introduce significant delay.

B. Fast Ethernet
 100 Mb version of Ethernet (802.3u).
 The frame structure is same.
 Only change is bit length. 10bits are sent now which were sent only 1 before. Data speed increased to 100
Mbps from 10 Mbps.
 Permits only star topology.
 Hubs or switches are a must.
 The bus topology and coaxial cables are not used now.
 FDDI (Fiber Distributed Data Interface) and Frame relay were very complex to maintain and was used for
Fibre Channel.
 Fiber Channel restricted its use to SNA (Storage Network Architecture).

Length
Name Type Advantage
(Max)
100 Base T4 UTP (cat-3) 100 m Existing setup can be used. 100 Mbps outgoing 33.3 Mbps
incoming or viceversa
100 Base TX UTP (cat-5) 100 m 100 Mbps to and fro is possible.
100 Base FX Fiber optics 2 km Best option for interconnection. Best noise immunity.

100Base-T4:
• Category 3 UTP scheme, easily available, backward compatibility, increased carrying capacity.
• Uses a signalling speed of 25 MHz, only 25 percent faster than standard Ethernet's 20 MHz Manchester
Encoding.
• Requires four twisted pairs.
– one is always to the hub,
– one is always from the hub, and
– the other two are switchable to the current transmission direction.
• Ternary signals are sent, so that during a single clock period the wire can contain a 0, a 1, or a 2.
• 33 =27 possible symbols can be transmitted.
Asst. Prof. Riddhi Joshi
Page 12
Chapter 6: Book 2 : Medium Access Sublayer
• 8B/6T (8 bits map to 6 traits) works well.
100Base-TX:
• category 5 wiring.
• can handle clock rates of 125 MHz.
• Two twisted pairs per station are used,
– one to the hub and
– one from it.
• A scheme used is called 4B/5Bis (2 for sending 2 for receiving and 1 extra may be used for controlling).
• It is taken from FDDI and compatible with it.
• Five clock periods, each containing one of two signal values, yields 32 combinations.
• Clock synchronization is taken care by selecting proper combination of available 32 combinations.
• The 100Base-TX system is full duplex.
• 100Base-TX and 100Base-T4 are collectively referred to as 100Base-T.
100Base-FX:
• Uses two strands of multimode fiber.
• One for each direction.
• Is full duplex with 100 Mbps in each direction.
• In addition, the distance between a station and the hub can be up to 2 km.
• Limited to be used for SNA (Storage Network Architecture).
• Survived for 40 years and competed with developing and transiting technology.
100Base-T2:
• 100Base-T2 is allowing fast Ethernet to run over two pairs of existing category 3 wiring.
• However, a sophisticated digital signal processor is needed to handle the encoding scheme required.
• This option is fairly expensive.
• Rarely used due to its complexity, cost, and the fact that many office buildings have already been rewired with
category 5 UTP.
• Solution: EFM (Ethernet First Mile), Deployed as large networking solution, interconnecting continents. All
Ethernet connection from sender to receiver for first mile, use only Ethernet and then may opt for other option
for long distance coverage.
The DC Component of a signal:
 DC component is the positive energy in signal.
 DC Component can not pass through devices like transformers and thus avoided in transmission.
 Reduction of DC component is an important aspect for data Communication.

A signal central around a positive value is equal to a signal centered at zero plus a positive continuous voltage signal
(DC Component).

Asst. Prof. Riddhi Joshi


Page 13
Chapter 6: Book 2 : Medium Access Sublayer

The Paradigm Shift: PtoP from shared:


• Coaxial cable and multi-drop(more than one machine attached to same wire using T connections of Vampire
Tap and BNC connectors) is discouraged.
• Point to Point and full duplex transmissions
• Reducing collision domain. So performance increased.
• Distance limit is lifted, Ethernet is used for first mile now (EFM).
• Ethernet remain unfazed after 40 years

C. Gigabit Ethernet:
 Even faster Ethernet 1000 MHz (802.3z)
 Full and Half Duplex operations.
 Full duplex mode avoid collision and channel sensing. Use switch and support frame storage in switch buffers
to avoid collision.
 If Half Duplex, hubs are used and have issues of collision.
 Prefer switches with little additional cost.
 Speed of 1 Gbps.
 Only use UTP and Fiber Optics. Doesn‟t use co-ax as it uses dedicated cables for upstream and downstream
which is not supported by co-ax.
 The 1000Base-CX option uses short shielded copper cables.
 The 1000Base-T is bundles of four category 5 UTP wires working together.
 New encoding scheme, called 8B/10B, was chosen, based on fibre channel. Each 8-bit byte is encoded on the
fiber as 10 bits, hence the name 8B/10B.
 But rules are:
 No codeword may have more than four identical bits in a row.
 No codeword may have more than six 0s or six 1s.
 A speed of 1 Gbps is quite fast.
 Ethernet, buffer overruns are very likely.

Asst. Prof. Riddhi Joshi


Page 14
Chapter 6: Book 2 : Medium Access Sublayer

Max
Name Cable Advantage
dist
1000Base-T Cat-5 or cat-5e or cat-6 100 m Cheapest solution.
1000Base-CX Balanced copper cabling 25 m More reliable than UTP.
Good choice for
1000Base-SX Multimode fiber 220 to 550 m connecting nearby
buildings or networks.
Good for connecting
1000Base-LX Multimode fiber 550 m
nearby buildings.
Good for long-haul
communication or
1000Base-LX Single-mode fiber 5 to 10 km
connecting larger set of
networks.
1000Base-BX10 Single strand having two
Single-mode single-strand fiber: communications in either
over 10 km
(Non-standard) 1490 –1310 nm upstream direction over a large
distance.

Gigabit Ethernet Frame structure

7 1 6 6 2 0–1500 0–46 4 0–448

Preamble SOF Dest. Src. Add. Lngth Data Pad Checksum Extension
Add.

Handling Long Range Transmission:


• How to reduce collision:
– Reduce Distance to 25m(so small!!) or
– Enlarge Frame Size.
• In Gbps speed, frame size is at least 512 bytes.
• If we change the frame size, we may face two problems:
• 1. Hardware Extension :
– Extend smaller frames and make it 512 bits by padding.
– Frame extension : “Extension” last.
– Sender adds and receiver removes using network card.
– Big overhead introduced.
• 2. Frame Bursting :
– Sender club frames making it large enough.
– Only possible in half duplex mode.
– After successful transmission of first frame without collision, sender can send clubbed frames one
after the other successfully.
– Max burst frame size : 2 16 = 65536

8B/10B and 4B/5B Coding:


• 8B/10B
– 8 bits are sent as 10 bits excluding other options as they are poor for synchronization or having higher
DC components.
– Rule 1: More than six 0s or 1s are not allowed in a 10-bit word
– Rule 2: Four identical bits are not permitted in a sequence
– The same coding scheme is also used in fiber channel
– All fiber-based mechanisms use 8B/10B

Asst. Prof. Riddhi Joshi


Page 15
Chapter 6: Book 2 : Medium Access Sublayer
• 4B/5B
– Cat cables use 4B/5B which is different.
– IEEE 802.3ab uses cat-5 or cat-6 (cat-5e, e for extension) wires.
– Converts 4 bits into 5 bits.
– Symbols used here are very different.
– Difference lies in copper (4B/5B) and fiber (8B/10B).
– All four pairs of wire are working on single direction to provide 1Gbps speed, remaining one for
controlling and framing.
– Also named PAM/5 (Pulse Amplitude Modulation)
The Pause Frame for Flow Control:
7 1 6 6 2 2 2
Preamble SOF Destination address Source Length/Type MAC MAC Control
or address 802.3 MAC Control Parameters
Multicast address Control Op-code
01-80-C2-00-00-01 (88–08) (00–00 to
Pause FF-FF)
(00–01)

 Classic Ethernet, Fast and Gigabit Ethernet working together has issue of speed miss match.
 Performance miss match issue. Flow control possible only in full duplex.
 Pause Frame: sent by receiver to sender to pause for time specified so that process Data, clean buffers and
get ready for next frame receiving cycle.
 2 bits for pause op and 2 bits for indicating time to wait multiplied with 512.

D. 10Gb
 Much faster Ethernet having variations 802.ae, ak, ap, an etc
 Standard and non standard variants available which are not listed on table.
 Backplane Ethernet:
 Copper cable with short range not suitable for networking but used by bridges and switches
 802.3ap.
 Using 10G Base TX4 and 10G Base-KR.
 Not standardized.
 PAM-8, PAM-10, PAM-12 and PAM-16 work with 10Gbps. (PAM-5 excluded as it is working with Gigabit
Ethernet).
 Explicit support for WAN: PAM-16 using 10BaseW (10GBase-SW, 10GBase-LW, 10GBase-EW and
10GBase-ZW).

10Gb connections
Name Cable Maximum Advantage Name
Distance
10G Base-SR Multi-mode 26–82 m Low cost and low power 10G Base-SR
10G Base-LR Single-mode fiber 10–25 km Expensive better distance 10G Base-LR
coverage
10G Base-ER Single-mode fiber 40 km Long reach 10G Base-ER
10G Base-T IEEE UTP or STP cat-6 or 55 m with cat-6 Auto negotiation with 10G Base-T IEEE
802.3an cat-6a and 100 m with 1000 Base-T possible 802.3an
cat-6a

Future Versions: 40-100 Gbps


• Super fast Ethernet 802.3ba

Asst. Prof. Riddhi Joshi


Page 16
Chapter 6: Book 2 : Medium Access Sublayer
• 100 Gb over 40 Km
• Under standardization when this is being written
• Two Concepts need to be focused upon:
– Link aggregation
– Dense Wavelength Division Multiplexing(DWDM)
Name Cable Max. dist. Advantage
40G Base-KR4 Copper cable 1 m at 40 Gbps As backplane
40G Base-CR4 Copper cable 10 m at 40 Gbps Cheapest 100G
40G Base-SR4 Multi-mode fiber 100 m at 40 Gbps Conventional LAN distance
40G Base-LR4 Single-mode fiber 10 km at 40 Gbps Long-range transmission
100G Base-
Single-mode fiber 10 km at 100 Gbps Long-range transmission
LR4
100G Base-
Single-mode fiber 40 km at 100 Gbps Long-range transmission
ER4
Link Aggregation:
– Also called trucking.
– Merge two or more physical links logically into single link.
– Benefits:
• When 2 nodes are connected with multiple lines, all lines are logically merged into single
link.
• 4 lines of 10Mbps aggregated to achieve 40Mbps.
• More bandwidth and performance.
• Can Manage bandwidth such that it provides quality of service.
• Provide fault tolerance by diverting traffic of one link over another in case of failure.
DWDM:
 Dense Wavelength Division Multiplexing.
 Kind of Frequency Division Multiplexing.
 Very high range of frequency (so called wavelength).
 Frequency range is very dense and can carry large voluminous data, usually in Gbps.
 Four light carriers on single mode fiber to support 40 Gbps using single fiber.
 Capable of supporting both the modes, End to End and Link aggregation.
 Basically multiplexes multiple links into one.

Dual Speed Cards


 When Fast Ethernet came, there were 10/100 cards could operate upon two speeds.
 When Gigabit Ethernet came, we had cards capable of supporting 10/100/1000 speed types.
 So for users it is easy to upgrade from classic Ethernet to Gigabit Ethernets.
 This cards are called Dual Speed Cards.

Auto Negotiation:
 10 Mbps when realize that other end is capable of working at 100 Mbps, it automatically start operating at 100
Mbps.
 Even Gigabit Cards can work upon all 3 speeds, 10/100/1000.
 This is process of capability negotiation which is done without user‟s intervention.
 User can upgrade without worry of compatibility with communicating networks.
 Can boost speed and performance is used with switch.
LLC Layer:
 Content of frame is not determined by MAC header, so it is provided by LLC (Logical Link Layer).
 LLC Jobs:
o Hides MAC address from Network Layer.
Asst. Prof. Riddhi Joshi
Page 17
Chapter 6: Book 2 : Medium Access Sublayer

o Provide connection oriented primitives that MAC can not do.


o Can provide service of establishing connection.
o Gives sequence number
o Providing ACK.
 Ethernet do not need LCC, DIX frames can omit LLC layer as internet needs to have only type of information
and no connection establishment service needed.

Q.Wireless MAC Layer:


Topic List:
• The Wireless LAN protocol (802.11)
• The DCF Mode
• Fragmentation in DCF mode
• The PCF mode
• Managing PCF and DCF modes together
• The 802.11 frame

Q.Wireless transmission in 802.11


Problems
1. Hidden and Exposed station problem
2. Frequency allocation issues
3. Signal fading (free space path loss)
4. Interference
5. Multipath fading
6. Restriction on power (sender‟s power, signal strength)
7. LOS vs NLOS (line of sight)
8. Placement of physical obstacle (beneficial as offer bouncing of signals, see next fig)
9. Frequency range (wifi 2.48Ghz, ISM 4.33 MHz long distance)
10. 802.11a is vulnerable to rainfall and vegetation.
11. Modulation scheme (OFDM provides 54Mbps in 802.11g and DSSS only 11Mbps in 802.11b)
Placement of obstacles:

DCF (Ad Hoc) mode:


• Computers communicate directly
• No access point control
• Compulsory mode
• With or without CSMA/CA
• Collision invites Binary exponential backoff

Asst. Prof. Riddhi Joshi


Page 18
Chapter 6: Book 2 : Medium Access Sublayer
• Unlike Ethernet, stop and wait is used
• Without CSMA/CS uses Fragmentation which are sent when noise is higher

Ad Hoc mode with CSMA/CA:

Steps to manage RTS and CTS:


1. Sense the channel
2. If channel is idle, wait for DIFS (DCF Inter Frame Spacing) time
3. Then transmit RTS
4. If channel is busy, wait for DIFS and then start transmitting
5. Sender waits for CTS from receiver
6. Once receiver got RTS, waits for SIFS(Short InterFrame Spacing) time which is much smaller than DIFS and
then send back CTS.
7. If RTS or CTS is not received on time, everything is started again.
8. Once CTS received, after waiting for SIFS, it can send next frame.
9. One can detect collision only when response is not received.
10. And sender waits for Ack. If not received everything is started from step 1 all over again.
11. Once Ack received, sender sends next frame.

NAV:
• The neighbours are also involved.
• They observe the duration value and remain silent for that time.
• Similarly neighbours of the receiver also learn that the receiver is about to receive a frame, so they too enter
into silent mode fro time till receiver sends back an acknowledgement.
• Silent mode is referred as NAV (Network Allocation Vector) mode.

AdHoc mode without CSMA/CA

Steps: without RTS and CTS:


1. Sender sense channel
2. If channel is idle, waits for DIFS and then transmits the frame.
3. Sender doesn‟t check for collision, they learn only if reply is not received.
4. Receiver once receive frame, waits for SIFS and sends back Ack.
5. Sender once received Ack, concludes that it has successfully transmitted the frames.
6. Upon receipt of Ack, sender sends next frame if required.

Asst. Prof. Riddhi Joshi


Page 19
Chapter 6: Book 2 : Medium Access Sublayer

Fragments in 802.11:

Reduces the chance of data loss:

The PCF mode:


• Access point determines who will send when.
• beacon frames for polling each station every few milliseconds announcing SSID and MAC address.
• Two modes, Default and protected
• Default(unprotected) mode
– Must know the SSID(service set identifier)
• Protected Mode
– MAC address
– IP address
– Or both
• Data transmitting is always encrypted and SSID is never encrypted.

Access point primitives:


Job Prerequisite Next primitive
Primitive

Connect node to Access point should be on and ready


Associate network to accept Authentication

Validate the AP as well Association must be done Optional privacy,


Authentication as the optional node beforehand otherwise data
transmission
Decide the type of Authentication must be done
Privacy encryption to be used beforehand Data transmission

Actual data is sent and Association must be done, optionally Disassociation,


Data
received authentication and privacy distribution, integration,
transmission
relocation

Asst. Prof. Riddhi Joshi


Page 20
Chapter 6: Book 2 : Medium Access Sublayer

Transmission across
Disassociation,
Distribution various networks, Data transmission
integration, relocation
either wired or wireless
Transmission across an
Integration Ethernet network Distribution Disassociation, relocation

Disassociation,
Sender moves from one
Relocation Association distribution, integration,
AP area to another
relocation
Sender logs out from
De- Authenticated Disassociate
its authenticated
authentication
account
Node going out of
Disassociate range or AP going Association Associate
down for maintenance

Different Inter-frame spacing:

Managing PCF and DCF Modes Together:


• DCF and PCF impose delay but they are the best design to prioritize transmission.
• PCF is given higher priority over DCF
• Before starting any communication, each user need to wait for SIFS and already communicating parties to
complete the communication.
• Each ad hoc mode needs to wait for DIFS which is longer than PIFS to let PCF flows complete
communication.
• Priority from higher to lower goes like this, ACK, CTS, Fragments, then comes PCF and at last comes DCF
and then if errors, NACK.
• Similarly, SIFS then PIFS, DIFS and then EIFS.
• Still there is a chance of collision if at same time two users sends RTS.

Asst. Prof. Riddhi Joshi


Page 21
Chapter 6: Book 2 : Medium Access Sublayer

802.11Frame:

Frame Control:
• Two bytes (16 bits) length
• Protocol version, current 0.
• Type of Frame: 1st Control, 2nd Management and 3rd Data.
• Subtypes:
– Control types : RTS, CTS, ACK.
– Management types: beacon, authentication, de-authentication, association, dis association, re
association, etc.
– Data: Data.
• To AP and From AP: where the frame is coming and going. Used for inter and intra cell communication.
• More flag: indicates More Fragments expected in DCF mode.
• Retry: To eliminate duplication, frame indicates that this frame is sent again.
• Power Management: wireless transmission handles battery low situation. After completion of transmission,
device enters into power save or sleep mode.
• More Data: indicates if current transmission is over or not.
• W: whether WEP (Wired Equivalence Privacy) is implemented or not.
• O: indicates whether frames are to be processed in ORDER or not.
• Duration: RTS, CTS an NAV process based on this duration observation.
• DSS BSS and 4 Address Fields:
– Wireless area having 1 access point is called cell or BSS (Basic Service Set).
– There is a need of interconnection between two cells (AP) for forwarding packets if not in range.
– This network becomes distributed and denotes DSS (Distributed Service Set).
– We need 4 addresses here to manage inter-cell and intra-cell transmission.
– Issue here: conversion of wired to wireless and wireless to wired frames.
• Sequence: Sq no. Is allocated to individual frame and fragment.
• Payload: carries network layer data like IP datagram, max size is 2312 but usually kept 1500 for compatibility
with ethernet.
• CRC: most important in wireless medium as error rate is very high, same method as Ethernet.

Intra Cell and Inter Cell Transmission:


• Intra Cell Transmission: sender and receiver belongs to same cell.
• Inter Cell Transmission: sender and receiver has multiple Aps
between them and need forwarding of packets from one AP to
another.
• Intra Cell uses only two addresses.
• Inter Cell:
– Ethernet – Wireless (Heterogeneous Network) Inter Cell
communication uses 3 addresses and
– Wireless Inter Cell needs all 4 address.

Asst. Prof. Riddhi Joshi


Page 22
Chapter 6: Book 2 : Medium Access Sublayer

Q.Wireless Broadband(802.16):
• WiMax(Wireless for Microwave Access) is slang(informal word). It is a name of alliance(group) of vendors,
IEEE name is 802.16
• 802.16d for Fixed Wireless
• 802.16e included mobility (latest standard)
• Proved useful in case of calamities
Wireless Broadband Protocol Sub-layers:
• Two capabilities, fixed WiMax and Mobile WiMax.
• Better bandwidth and long distance support.
• OFDMA are used as physical layer in wireless broadband.
• Channel continuously examine noise level and decides which modulation scheme should be used, QAM-64,
QPSK, BPSK(Binary PSK).
• Fixed broadband uses LOC service provides maximum bandwidth.
• MIMO(multiple input multiple output), uses multiple antennas for multi stream transmission in parallel to get
better bandwidth.
802.16 sub-layer Functionality Layer

Service-specific convergence Similar to logical link layer


sublayer
MAC sublayer Similar to Ethernet layer, arbitration of the channel and Data link layer
related issues
Security sublayer Facilitates secure transmission
Transmission convergence Provides a consistent interface to the data link layer
sublayer while working with different physical layers below
Physical layer
Physical medium dependent BPSK or QPSK or some version of QAM depending on
sublayer the channel noise level

Security is Premium in WiMax:


1. Sender and receiver can authenticate each other.
2. Third party can give certificates to parties involved in communication.
3. Videos, Audios, Mails, Files get encrypted, eavesdropping revels no meaningful information.
4. Articles sent are verified for modification during transmission, know as integrity check.
5. Carry Subscriber-Carrier relationship: those who provide services to subscriber can charge subscription fees
and is completely private.

Difference between .11 and .16:


802.11 802.16
designed for LAN designed for MAN
2.4 GHz ISM band for its versions „b‟ and „g‟. 10 to 66 GHz range
It used the 5 GHz ISM band for its version „a‟ Now also available in the range near to the 802.11.
A small range and no LOS LOS(802.16d) and NLOS 802.16e) are available
Wireless Ethernet broadband Internet
Connectionless Connection oriented
Original design include mobility Latest version, 802.16e include mobility
Distance covered, few meters Distance covered, 50 km
Required loose security as covers only a campus. Required strong security as covers entire city.
Security is being addressed now Security is considered in the beginning
11 MB with type „b‟ and 54 MB with either „a‟ or „g‟. More than 70 Mbps with less than 1 km of distance and if
distance is more, it can reach up to 50 km

Asst. Prof. Riddhi Joshi


Page 23
Chapter 6: Book 2 : Medium Access Sublayer

The MAC Layer:


• Provides Connection-oriented service. i.e go-backN, sliding window and all protocols establishing
connections are included here.
• Provides QoS (Quality of Service).
• Connection Establishment and Withdrawal is done on every communication.
• But this adds lot of overhead.
• Intelligent to overcome overheads as 802.16 is capable of sending back to back frames, this is how we can
overcome overheads.
• Provides better service to VOIP like apps
• During telephone connection, gap between words are maintained till signals reach the destination.
• But bandwidth in internet doesn‟t remain constant.
• Thus, network service is affected.
• This delay is tolerable while browsing, but not for VoIP applications, video conferencing and video calling.
• Some Facts:
– Latency is less than 100ms doesn‟t affect QoS.
– Some users will be able to realize latency over 120ms.
– Most users will notice latency over 150ms.
– Humans are intolerant to speech delays of more than 200ms.
• Four service classes
– Base station polling for first three classes
– Ethernet like response for forth class
– Dynamic allocation of channels
Service Classes: 4 for 802.16:
1. CBR: Unsolicited grant service or constant bit rate(CBR) service,
2. RBR: Real-time polling service (also extended real-time polling service only for Mobile WiMax in 802.16e)
or variable bit rate(RBR) real-time service,
3. NRVBR: Non-real-time polling service or non-real-time variable bit rate(NRBR) service, and
4. Best effort service
CBR: Constant Bit Rate:
• Constant Bit Rate
• Unsolicited grant service
• Constant bandwidth throughout the transmission until connection terminates.
• Eg. Uncompressed video (live videos) needs CBR.
• Lease line also supports the same.

RBR: Real Time Variable Bit Rate:


• Real Time Service.
• Two classes:
– Normal Service (For both Fixed and Mobile WiMax)
– Extended Service (Only for Mobile WiMax)
• Required by senders sending videos in compressed format.
• Here, first frame is uncompressed, remaining all compressed.
• Eg. In the green field, first frame is sent, then following frame carry only the ball motion indication, others
remains same.
• When difference is large, new frame is sent.
• Bandwidth requirement is based on the difference between two consecutive frames.
• Thus, bandwidth requirement is variable.
• If bandwidth is not demanded by user, it is allocated to next service class users.
• Real Time Polling Service: the number of times the user has polled for additional bandwidth determines the
unit of bandwidth to be allocated to that user. This is called real time polling service.
• Mobile WiMax has combination of Constant Bit Rate and Real Time Variable Bit Rate where, fixed
bandwidth is allocated by CBR and additional bandwidth can be demanded by user.
NRBR: Non Real Time Variable Bit Rate:
• Variable bit rate requirement.

Asst. Prof. Riddhi Joshi


Page 24
Chapter 6: Book 2 : Medium Access Sublayer
• But not real time
• Eg: Multimedia Email
• Multimedia clips are added to email demanding bandwidth higher than CBR
• If bandwidth is not available, email can wait, and so, not real time.
• Given less priority than real time apps.
Best Effort Service:
• Lowest Priority.
• Uses whatever is left over from all above 3 classes.
• Eg. Email having attachment files.
• Demands neither real time nor variable bandwidth.
• Like Ethernet, have chance of collision, resolved by Binary Exponential Back off Algorithm.
How all 4 class requirement of subscriber fulfilled by provider?
• First Three Class have no issue of collision.
• Last Class handle it with BEB Algo.
• First 3 Classes has both direction transmission distributed like 75% downstream and 25% upstream.
• Negotiation happens at Subscriber and Base Station (SS and BS).
• Two options:
– Assign SS and he allocates.
– Assign BS individually as per the requirement.
• Priority of VoIP(real time variable bit rate) is higher than File Transfer(best effort service).
• Bandwidth allocation, two options:
– FDD Frequency Division Duplexing
– TDD Time Division Duplexing (First two frames carry upstream and downstream free timeslot
indication)
• Both use Base Station to inform Upstream and Downstream with system parameters.
• SS and BS negotiate bandwidth and delay tolerance.
• Inactive SS are grouped and later on given single poll to group instead of individual polls.
• Best Effort Service need no polling.
• Similar to Railway Reservation, Advanced Booking – CBR, Real Time – Tatkal, Non Real Time – TC
Relation, Best Effort – General.

Generic Frame structures for 802.16:

• Identification : 0 of Normal Frame and 10 of Control Frame.


• EC : whether encrypted or not.
• Type : Packing type, Single or multiple (data send back to back) or Fragmentation.
• Real time, no chance of errors, no checksum.
• CI : Checksum Indication, checksum = 1 present or checksum = 0 absent.
• EK : Encryption Key. 802.16a uses DES and RC5.
• Length : Frame length with header
• Connection ID : multiple connections are established so separated with connection ID.
• Header CRC : calculated using polynomial, x8 + 1.
• Payload : Arbitrary long data accommodation.
• CRC : 4 bytes of CRC redundancy bits.
• Free bits : Kept for forward error control using Hamming code.

Asst. Prof. Riddhi Joshi


Page 25
Chapter 6: Book 2 : Medium Access Sublayer
• Control Frame used for requesting bandwidth.
• Bytes Needed : Polling required number of bytes and bandwidth.
• All other same functionality.

Q. Which connecting devices are used at Data Link Layer?

 There is a device called layer-2 switch which is more popular today which functions in similar fashion as a bridge
but having many to many connections rather than one to one in the bridge.
 Both of them use MAC Layer as the connecting points.
 Why we need a connecting devices as the data link layer.
o When organization has multiple LANs, administrator needs to join them for information sharing.
o If two nodes are apart by more than 2500m in an Ethernet, then they cannot become a part of single
network. For such requirement we need to connect LANs.
o One may want to abolish all the networks and have a single network where all can share data with anyone.
o Employees are scared of viruses and want their machines maintained well.
o When two networks are of different types, eg. Wired and Wireless, we need a communicating device as a
mediator between the two networks.
o Bridges can even detect malicious traffic and stop them.
o A Virus on one network can be confined to that network only using a bridge.
o One can use TCPDUMP to spoof the entire network.
o We can have different policies like „nobody can access accounts data except his or her own salary
accounts.
o Some networks consume more load than others. Eg. R&D (Research and Development) Department. They
may starve other users for bandwidth as they eat away 80% of bandwidth.
o Broadcasting is used by lot of application layer protocols. This is not limited to single network, it will
create serious traffic overflow in network.
 Two options are available: 1) Bridge (Physical Connectivity) and 2) VLAN (Logical Connectivity).

Q.What is Virtual LAN (VLAN)? Also write its operations.

 Networks can also be connected in a logical way which is simpler and easier for a user, but cumbersome for an
administrator to manage.
 Solution is called Virtual LAN.
 In Virtual LAN, irrespective of where a node is situated, it can be a part of the network it wants to be.
 A student with his laptop can get connected to the campus network from any place.
 Virtual LAN is useful for two important purpose:
o Irrespective of the physical location, a user can be a part of any of his network.
o User receives anything that is broadcasted in his own network.
 A Virtual LAN is a LAN where the machines, without physical proximity, can be a member of a LAN.
 The machine that changes its network just needs to change its membership status which is indicated by different
color and size and VLAN tags in actual sense.
 In a VLAN, a node can decide the network it belongs to and inform the switch accordingly.
 An accountant of some department may go and sit in accounts department of the company in the month of March
and come back in middle of April.
 This is done by having switches which are capable of understanding both, physical connections and logical
network they belong to.
 Thus, VLAN aware switch remembers that port 1 belongs to network A, port 2 belongs to network B and so on.
 These switches are configurable such that, a sure can indicate that earlier port-1 belongs to Network B and now it
belongs to Network A.
 Manageable switches are the ones which are locally or remotely configurable.
 A user will remotely login to a switch and change the port and other information from his machine.
 Manageable switches are usually VLAN aware.

Asst. Prof. Riddhi Joshi


Page 26
Chapter 6: Book 2 : Medium Access Sublayer

Conventional LAN, moving the node:

Manual Shifting of a machine from one network to another.

Changing the membership VLAN way, changing the port membership.

Virtual LAN. The switches are VLAN-aware. If node ‘b’ wants to join network A, it can do so without
relocating. The node informs the switch which does the needful by changing a table resident in its memory.

VLAN Standardization and Frame Format:

 Standard: 802.1Q
 VLAN protocol ID: Fixed. 0x8100.
 VLAN tag: Also provides additional information about VLAN

Asst. Prof. Riddhi Joshi


Page 27
Chapter 6: Book 2 : Medium Access Sublayer

 Only 2 extra fields are added to VLAN enabled Headers. Others are same as Ethernet.
 The cards that understands this new Header is known as VLAN-Aware Cards.
 Usually switches contain such cards.
 Priority: Indicates that it contains priority value which is not concerned with VLAN
 CFI: Canonical Format Indicator, expecting fixed format.
 VLAN Identifier: It identifies VLAN uniquely.
 See figure on next page.

VLAN Operations:

 A VLAN operation starts when frame arrives at the first VLAN aware switches or bridge.
 Fames add VLAN PID and also tag information in the frame.
 If machine do not have VLAN aware card, then switch should attach that information before forwarding.
 First way to keep the information of configuration table using MAC address.
 MSTP: Multiple Spanning Tree Protocol in 802.1Q can work like spanning tree in normal LAN. This protocol
can block alternate path between any two VLANs, keeping only one path open to avoid loops. This protocol is
backward compatible fully and can work with legacy Ethernet Bridges and Switches.
 Maximum frame size is extended to 1522
 All machines belong to a unique virtual LAN
 Otherwise the switch should add VLAN tag
 VLAN aware switches
 MAC, IP Address or Port number can be used as a separator
 Not good from purist point of view
 MSTP to avoid loops

Asst. Prof. Riddhi Joshi


Page 28
Chapter 6: Book 2 : Medium Access Sublayer

University Questions List:

1. Give specifications of various Ethernet Cabling. Discuss about Fast Ethernet in brief.[7]
2. What is the importance of RTS and CTS in the wireless transmission?[3]
3. Explain Carrier Sense Multiple Access protocol with persistent and non-persistent scenarios.[4]
4. Differentiate between half duplex and full duplex channel.[1]
5. What is the major difference between a hub and a switch?[1]
6. Differentiate between wireless and mobile systems with example[5]
7. Explain a) Hidden Station Problem b) Exposed Station Problem with respect to wireless networks.[4]
8. Differentiate between non persistent, 1 persistent and p persistent CSMA/CA.[4]
9. Write a note on: Binary Exponential Back-off Algorithm[4]
10. What is the use of Network Allocation Vector in CSMA/CA?[3]
11. Four service classes in 802.16[4]
12. Dividing MAC networking stack in sub layers[4]
13. Manchester Encoding[1]
14. Frequency division multiplexing[2]
15. Give two important differences between QPSK and QAM 64[3]
16. Why sliding window protocols are called so?[3]
17. Why was slotted Aloha through put was double than normal Aloha?[3]
18. List two types of frames needed by 802.16[2]
19. What is the need for security sub layer in 802.11?[3]
20. List what services Integration and Distribution does for 802.11[3]
21. Why was Manchester Encoding chosen for first version of Ethernet?[3]
22. Explain how fragmentations are managed in 802.11[3]
23. Write any two reasons for introducing 802.16 even when 802.11 was around and successful[3]

Asst. Prof. Riddhi Joshi


Page 29

You might also like