Computer Communication and Networks. Lab Experiment 3. Media Access
Control (ALOHA) Protocol. Introduction. The Aloha protocol is an OSI layer 2
protocol ...
Computer Communication and Networks Lab Experiment 3 Media Access Control (ALOHA) Protocol Introduction The Aloha protocol is an OSI layer 2 protocol for LAN networks with broadcast topology. The first version of the protocol was basic:
If you have data to send, send the data
If the message collides with another transmission, try resending "later"
Many people have made a study of the protocol. The critical aspect is the "later" concept. The quality of the backoff scheme chosen significantly influences the efficiency of the protocol and the predictability of its behavior. The difference between Aloha and Ethernet on a shared medium is that Ethernet uses CSMA/CD, which broadcasts a jamming signal to notify all computers connected to the channel that a collision occurred, forcing computers on the network to reject their current packet or frame. Pure Aloha had a maximum throughput of about 18.4%. This means that about 81.6% of the total available bandwidth was essentially wasted due to losses from packet collisions. The basic throughput calculation involves the assumption that the aggregate arrival process follows a Poisson distribution with an average number of arrivals of 2G arrivals per 2X seconds. Therefore, the lambda parameter in the Poisson distribution becomes 2G. The mentioned peak is reached for G = 0.5 resulting in a maximum throughput of 0.184, i.e. 18.4%. An improvement to the original Aloha protocol was Slotted Aloha, which introduced discrete timeslots and increased the maximum throughput to 36.8%. A station can send only at the beginning of a timeslot, and thus collisions are reduced. In this case, the
average number of aggregate arrivals is G arrivals per 2X seconds. This leverages the lambda parameter to be G. The maximum throughput is reached for G = 1. It should be noted that Aloha's characteristics are still not much different from those experienced today by Wi-Fi, and similar contention-based systems that have no carrier sense capability. There is a certain amount of inherent inefficiency in these systems. For instance 802.11b sees about a 2-4 Mbit/s real throughput with a few stations talking, versus its theoretical maximum of 11 Mbit/s. It is typical to see these types of networks' throughput break down significantly as the number of users and message burstiness increase. For these reasons, applications which need highly deterministic load behavior often use token-passing schemes (such as token ring) instead of contention systems. For instance ARCNET is very popular in embedded applications. Nonetheless, contention based systems also have significant advantages, including ease of management and speed in initial communication. Because Listen before send (CSMA - Carrier Sense Multiple Access), as used in the Ethernet, works a lot better than Aloha for all cases where all the stations can hear each other, Slotted Aloha is used on low bandwidth tactical Satellite communications networks by the US Military, subscriber based Satellite communications networks, and contact less RFID technologies.
Figure 1
If we want to replicate the curve in Figure 1 Connect as many nodes as possible to the Network Emulator Unit. The generated load is given by G = (N*P)/(C*ta ), Where N is the number of nodes, P is the packet length in bits, C is the data rate in b/s and ta is the average time between packet arrivals at each node. This expression is accurate as long as ta is much greater than the software overhead per packet which is typically several milliseconds per packet. We can rewrite the expression as: G = (N*Tp )/ta, Where Tp = P/C is the transmission time of a packet. By using as many nodes as possible, and a large packet transmission time, you will be able to generate heavier loads.
Objective The objectives of this experiment are to:
Obtain a better understanding of the ALOHA protocols.
Analyze the throughput performance of ALOHA with varying packet sizes and packet intervals which in turn affect the load.
Network Topology
Node 1
Node 3
Node 2
Figure 1: Network Diagram
Node 4
Set up the network as illustrated in Figure 1 and configure the following parameters:
Topology: BUS
Link Delay: 0s
Data rate: 8Kbps
Frame error rate: Off
Bit error rate: Off
Experimental Set-Up 1. Open “MAC” program from the shortcut on both PCs 2. Go to Configure View of Figure 2, which is located under Configure in the Tool Bar of the program.
Figure 2: LAN Trainer Window 3. Set the node as shown in Figure 3:
1st and 2nd PC FIRST window:
Set node ID : 0
Set Packet Length : …..
Inter Packet Delay : ….
Set Direction : Sender
1st and 2nd PC SECOND window:
Set node ID : 1
Set Packet Length : ….
Inter Packet Delay : ….
Set Direction : Sender
Figure 3: Configuration View on all Windows 4. Then the 2nd PC first will press the following in sequence: Stop ---- > Reset ---- > Boot
5. Then the 1st PC will press the following in sequence: Stop ---- > Reset ---- > Boot
6. lastly, execute
the program in the following sequence starting from the 2 nd
PC to the 1st : node 0, node 1, node 0, node 1
Procedure and Results 1. Complete the following table by entering the suitable values for packet size (P) (more than 8 bits) and time interval between packets in seconds (TA). Then calculate the value for load (G). Where the number of nodes (N) = 4, Data rate (C) = 8Kbps.
N
P
C
TP
TA
G
# of rec. Experm packets ThP
Theor. ThP
2. For each calculated load, set up and run the experiment as indicated in the set up section of this manual. 3. By using the formula calculate the practical and theoretical throughput.
Lab Report 1. Write a brief description about ALOHA protocol. 2. Plot the experimental graphs for throughput vs. offered load for varying loads. 3. Plot the theoretical graphs for throughput vs. offered load for varying loads 4. Discuss your result in accordance with your graphs. 5. Conclude your results.
Questions 1. What is the effect of packet size on throughput? 2. What is the effect of time interval on throughput? 3. What is the most ideal load value? 4. What happens if the load is too large or too small? 5. Why doesn’t the throughput continue to increase as the load increases?