Link Layer Review CS176A Ramya Raghavendra • Suppose two nodes start to transmit at the same time a packet of length L over a broadcast channel of Rate R. Denote the propagation delay between the two nodes as tprop. Will there be a collision if tprop < L/R? Why or why not? • Transmission delay = L/R • Propagation delay = d/s Link Layer Protocols • Desirable Properties of a broadcast medium of rate R bps – When only one node has data to send, that node has a throughput of R bps. – When M nodes have data to send, each node should have R/M average rate – Decentralized – Simple and inexpensive to implement Slotted ALOHA • How many of these desirable properties does ALOHA have? – All frames consist of L bits – Time is divided into slots of size L/R secs – Nodes start to transmit frames at the beginning of a time slot – Nodes are synchronized (Why? ) – Nodes detect collision before the time slot ends – When node has a frame to send, transmits at the beginning of the next slot – If there is a collision, retransmits with probability Ethernet A B C • A sends IP datagrams to B, encapsulating MAC address to B, does C receive it? • Do the IP datagrams get passed to C? • What if A sent broadcast packets? ARP • • • • IP addresses at the network layer MAC addresses at the link layer Need to translate Address Resolution Protocol – same subnet • Broadcast ARP Packet • Unicast Reply • Why? ARP (Cont) R R has 2 ARP modules Can a MAC address appear on both? CSMA 1. Carrier Sensing 2. Collision Detection • CSMA/CD – – – • Ethernet Senders detect collision Can this be possible in all media? Wireless? CSMA/CA – – – Intent to transmit Clear notification Acknowledgement CSMA/CA • Adapter waits K * 512 bit-times, K being random, when it detects collision • K=100, how long does it wait for – 10 Mbps Ethernet 51200 bit-times => [51.2 * 10^3] / [10 * 10 ^6] = 5.12 ms – 100 Mbps = 512 microsec