* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Download Lecture 16
Computer network wikipedia , lookup
Network tap wikipedia , lookup
Wireless security wikipedia , lookup
Recursive InterNetwork Architecture (RINA) wikipedia , lookup
Zero-configuration networking wikipedia , lookup
Piggybacking (Internet access) wikipedia , lookup
Wake-on-LAN wikipedia , lookup
Point-to-Point Protocol over Ethernet wikipedia , lookup
Power over Ethernet wikipedia , lookup
IEEE 802.1aq wikipedia , lookup
Cracking of wireless networks wikipedia , lookup
ICOM 6115 – Computer Networks and the WWW Manuel Rodriguez-Martinez, Ph.D. Lecture 16 ICOM 6115 ©Manuel Rodriguez-Martinez Lecture Objectives • Look at Stop-and-Wait pseudo code – Sliding window comes on Tuesday • Introduction to the Medium Access Control (MAC) Sublayer – Addressing – Channel allocation – IEEE 802 family of protocols • Ethernet • WiFi • Broadband ICOM 6115 ©Manuel Rodriguez-Martinez Multi-access Networks • Issue – Same channel is shared by many host – Only one can be using it at any given time • Problem – How to control access to the channel and be fair? ICOM 6115 ©Manuel Rodriguez-Martinez Medium Access Control (MAC) Sublayer • Lower part of the Data Link Layer for multiaccess networks – e.g. Bus networks like Ethernet • MAC has the protocols to control which host get access to the network • Logical Link Control (LLC) – Actual Data Link Services • Connectionless No ACKs • Connectionless with ACKs • Connection-oriented with ACKs ICOM 6115 ©Manuel Rodriguez-Martinez A View of the Data Link Layer ICOM 6115 ©Manuel Rodriguez-Martinez Why have a LLC? • Split Data Link Layer complexity – MAC is specific to the physical network • Various Flavors of Ethernet • Various Flavors of Wireless (802.11a or 802.11b) – LLC is common to all • Build just one version of this component – MAC is specific to interface with physical layer • Permits backward compatibility or interoperability – 802.11a y 802.11b share LLC ICOM 6115 ©Manuel Rodriguez-Martinez Example LLC • IEEE 802.2 • LLC receive packets from network layer • Adds header with – Frame sequence number – Frame ACK number (if any) • Call upon MAC sublayer to actually put data on wire • At Receiver side, MAC delivers frames to LLC – LLC decides to ACK or not – Send data up to the network layer ICOM 6115 ©Manuel Rodriguez-Martinez Example MAC sublayers • • • • • IEEE 802.3 – Ethernet IEEE 802.5 – IBM Token Ring IEEE 802.11 – Wireless LAN IEEE 802.15 – Personal LAN (Bluetooth) IEEE 802.16 – Broadband Wireless – Wireless Local Loop • All these share a common LLC – IEEE 802.2 ICOM 6115 ©Manuel Rodriguez-Martinez Services provided by MAC sublayer • Addressing – MAC Address • Given to the network interface card • • • • Frame generation Checksum computation Error detection Arbitration for channel access – Conflict detection and resolution ICOM 6115 ©Manuel Rodriguez-Martinez Static Channel Allocation • Allocate each host a chance to send • FDM or TDM can be used here – Reserve each host a part of the bandwidth • But these do not work well in LANs – Bursty traffic means channel is poorly used • Idle sender eats bandwidth that can be given to busy sender ICOM 6115 ©Manuel Rodriguez-Martinez Dynamic Channel Allocation • Distributed Algorithm is run to determine who gets to send – Get permission to send • Token-based approach – IBM Token Ring or FDDI – Send first and then fix any problem • Typical problem: Collisions – Two frames are send at the same time, thus distorting the signals ICOM 6115 ©Manuel Rodriguez-Martinez Ethernet MAC Sublayer • Invented at Xerox • Standardized as IEEE 802.3 • Properties – Best effort delivery • LLC must do re-transmission in case of timeout or CRC error – Carrier Sense with Collision Detection – Unique address for network Card – Support for multicasting and broadcasting ICOM 6115 ©Manuel Rodriguez-Martinez Ethernet Types • Cable type provides the type of Ethernet ICOM 6115 ©Manuel Rodriguez-Martinez Connectivity of Ethernet styles ICOM 6115 ©Manuel Rodriguez-Martinez Ethernet Frame Format • Preamble – 64 bits long, each byte has pattern 10101010 – Synchronize start of frame • Dest addr – 48-bit destination address • Src addr – 48-bit source address • Type – 16-bit flag used to indicate which upper layer protocol gets the frame • Body – variable length area to put the data from LLC • CRC – 32-bit error detection code ICOM 6115 ©Manuel Rodriguez-Martinez Ethernet Manchester Data Encoding • Problem: How to discern an idle link from the signal for bit 0? • Each bit period is divided into two sub-periods – 1 is encoded as transition from high to low voltage – 0 is endoced transition from low to high voltage ICOM 6115 ©Manuel Rodriguez-Martinez Ethernet MAC Address • Every Ethernet card has a unique MAC address – Stored (burned) in ROM – 6 bytes long – Usually printed on card in hexadecimal digits, one digit per 4-bit group • Example: – 8:0:2B:E4:B1:2 represents MAC address 00001000 00000000 00101011 11100100 10110001 00000010 – Can also be written as: 08:00:2B:E4:B1:02 ICOM 6115 ©Manuel Rodriguez-Martinez Ethernet Addressing • Unicast – Frame is addressed to one network card • Broadcast – Frame is addressed to all network cards – Special MAC Address for this • 11111111 11111111 11111111 11111111 • Multicast – Frame is addressed to a group of cards – Each address has the first bit set to 1 • 10101010 01001010 11110111 01011011 ICOM 6115 ©Manuel Rodriguez-Martinez Transmitter Algorithm • Ethernet is Carrier Sense system – Adaptor can “listen” to signal on wire • If card has a frame to send it listens to wire – If signal is detected, then it waits and tries again later when channel is idle – Otherwise, frame is sent and card starts listening as it sends • Send and listen simultaneously to detects collision ICOM 6115 ©Manuel Rodriguez-Martinez Collision Detection • If the card listens a different signal pattern than the one its sending, it assumes a collision • Card waits a random amount of time t • Card attempts to send the frame again • This is called collision detection – Often the system is term • CSMA/CD – Carrier Sense Multiple-Access with Collision Detection ICOM 6115 ©Manuel Rodriguez-Martinez Collisions • How much can it take to detect a collision? – 1 RTT ICOM 6115 ©Manuel Rodriguez-Martinez