UCCN2013-C,hapter01-EthernetOverview

41
Network Switching & Routing Ethernet Overview UCCN 2013 (Lecture 01)

Transcript of UCCN2013-C,hapter01-EthernetOverview

  • Network Switching & RoutingEthernet OverviewUCCN 2013(Lecture 01)

  • Brief Development History of EthernetIEEE802.3 Ethernet standardIEEE802.3u 100BASE-T Fast Ethernet IEEE802.3z/ab 1000Mb/s Gigabit Ethernet IEEE802.3ae 10GE Ethernet10G Ethernet1970s1980s1990sEthernet10M EthernetShared turn to LAN switch100M Fast Ethernet19921996Gigabit Ethernet2002

  • Shared Ethernet Transmission Media10Base5: A thick coaxial cable. The 5 refers to a maximum transmission distance of 500 meters.10Base2: A thin coaxial cable . The 2 refers to a maximum transmission distance of 185 meters.

  • Shared Ethernet Medium10Base-T: twisted-pairTwisted wire pairRJ45STP Twisted wire pairUTP Twisted wire pair

  • Pin Order of Category 5 Twisted-pairStraight Cable

    Crossover CableSide 11=white/orange2=orange3=white/green4=blue5=white/blue6=green7=white/brown8=brownSide 2Side 1Side 21=white/orange2=orange3=white/green4=blue5=white/blue6=green7=white/brown8=brown1=white/orange2=orange3=white/green4=blue5=white/blue6=green7=white/brown8=brown1=white/green2=green3=white/orange4=blue5=white/blue6=orange7=white/brown8=brownSide 11234567812345678Side 21234567812345678Side 1Side 2

  • Device Medium Relationship

    HostRouterSwitch (MDI_X)Switch (MDI)Hub (MDI_X)HostCrossCross StraightN/AStraightRouterCrossCross Straight N/AStraightSwitch (MDI_X)StraightStraightCross StraightCross Switch (MDI)N/AN/AStraightCrossStraightHub (MDI_X)StraightStraightCross StraightCross

  • Medium Dependent InterfaceMDI Medium Dependent InterfaceMedia Dependent Interface optionAllows port to auto sense cable type (straight or Xover)Command mdix auto supported on new Cisco switchesBy default on switches running Cisco IOS release 12.2(18)SE or later.Huawei switches port at eNSP by default mdix

  • Standard EthernetStandard Ethernet10Mbit/s defined by IEEE 802.3

    Standard Ethernet 10Mbit/susually orients at access layer

  • General View of 802.3 Cable

    Standard Cable type Transmission distance10BASE-5Thick coaxial-cable500m10BASE-2Thin coaxial-cable200m10BASE-TTwisted-pair100m

  • Fast EthernetFast Ethernet is a LAN based technology with a capability for data transmission rates of 100Mbps. It can provide higher bandwidth for terminal users, servers and server groups. IEEE802.3u is defined by IEEE as the standard for Fast Ethernet supporting two medium types.Twisted-pairFiber

  • General View of Fast Ethernet

    standardCable typeTransmission distance100BaseTXEIA/TIA category 5 (UTP) Unshielded Twisted Paired 2pair100m100BaseT4EIA/TIA category 3, 4, 5 (UTP) Unshielded Twisted Pair (4pair)100m100BaseFXMultiple mode fiber (MMF)550m-2kmSingle mode fiber (SMF)>2km

  • Gigabit EthernetGigabit Ethernet is the extension of the IEEE802.3 standard, for which transmission speeds of 1Gbps are achieved. Two standards are defined:IEEE802.3z (fiber and copper cable)IEEE802.3abtwisted-pair

  • General View of Gigabit Ethernet

    standardCable typeTransmission distance1000BaseTCopper EIA/TIA type 5UTPUnshielded Twisted Paired 4 pair100m1000BaseCXCopper Shielded Twisted Pair25m1000BaseSXMultiple mode fiber, 50/62.5um fiber, uses laser which wavelength is 850nm550m/275m1000BaseLXSingle mode fiber, 9um fiber, uses laser which wavelength is 1300nm2km-15km

  • 10G EthernetStandards for 10G include IEEE 802.3ae (fiber), IEEE 802.3ak (copper cable) and IEEE 802.3antwisted-pairMainly applied between core nodes over backbone networks

  • General View of 10G Ethernet Cable

    standardCable typeTransmission distance10GBASE-SR/SW Multimode fiber, 62.5/125um fiber or 50/125um fiber2m-300m 10GBASE-LR/LW Multimode fiber, 62.5/125um fiber or 50/125um fiber; single mode fiber, 10/125um fiber2m-10km 10GBASE-ER/EW10/125um fiber2m-40km10GBase-LX4Multimode fiber, 62.5/125um fiber or 50/125um fiber; single mode fiber, 10/125um fiberMultiple mode 300m, single mode 10km10GBase-CX4coaxial copper cable15m10GBase-TTwisted-pair copper cable100m

  • Working Principle of L2 Switch

  • Review: Ethernet FramePreamble (7 bytes) & Start Frame Delimiter Fields (1 byte)The Preamble and SFD fields are used for synchronization and to get the attention of the receiving nodes. Destination MAC Address Field (6 bytes)The address in the frame is compared to the MAC address in the device. If there is a match, the device accepts the frame.Source MAC Address Field (6 bytes)It identifies the originating NIC or interface. Switches use this address to add to their lookup tables.Length/Type Field (2 bytes)Length of field or Layer 3 protocolData and Pad Fields (46 to 1500 bytes)It contain the encapsulated data from a higher layer, which is a generic Layer 3 PDU. Frame less than 64 bytes is paddedFrame Check Sequence Field (4 bytes)The receiving device receives the frame and generates a CRC to look for errors. If the comparison does not match the FCS contents, frame is discarded

  • Ethernet Frame StructureEthernet_IIDMACSMACLength/TypeDATA/PADFCSLength/Type valueMeaningLength/T > 1500

    Length/T

  • Ethernet_II Frame Structure0800IP datagram0806ARP request/response8035RARP request/responseDMACSMACTypeDATA/PADFCS

  • 802.3 Frame Structure TYPEDATADSAPSSAPCTRLORG CODE0806ARP request/response8035RARP request/response0800IP datagram11132381492DMACSMACLengthDATA/PADFCSIn an 802.3 frame, there is a three-byte 802.2 LLC and a five-byte 802.2 SNAP header.

  • Ethernet Device AddressingHosts need a Data Link layer addressPhysical address burned in to NIC ROM48 bits in length and displayed in Hexadecimal

  • Uses for MAC Destination AddressUnicastFrame is destined for a specific node on local segmentBroadcastFrame is destined for all nodesAll Fs in Hex and all 1s in BinaryMulticastFrame is destined for a group of nodesGroup membership is defined at upper layers

  • Source MAC Learning

  • Source MAC LearningStep 1. Broadcast frame from PC 1 on Port 1.Step 2. Switch learns the source MAC address on Port 1 and adds to the address table.Step 3. Switch floods the broadcast frame to all ports, except the port on which it received the frame.Step 4. PC 2 replies to the broadcast with a unicast frame addressed to PC 1.Step 5. . Switch learns the source MAC address on of PC 2 and adds to the address table. The destination address of PC 1s frame and its associated port is found in the MAC address table.Step 6. The switch can now forward unicast frames between PC1 and PC 2devices without flooding.

    Note: broadcast frames will always be flooded

  • Forwarding Based on the Destination MACMACDMACA......Port 1MACDMACA......Port 2MAC addressportMACA1MACB1MACC2MACD2

  • Page *L2 Switch PrinciplesFrame InputFrame flooding (except source port)Forwarding frame(except source port)unicastbroadcastmatchedNot matched

  • Switch Forwarding MethodsStore-and-ForwardForwards only after it receiving full frameDelay lies on frame lengthSwitch check error, the error packet will be discarded Low error but most latencyCut-through SwitchingBest performance but more errors2 types of Cut-Though SwitchingFast Forwarding Forward the frame as soon as it receives destination MAC address.Low delayNo error checkFragment Free Forwarding Switch receives/read the first 64 bytes of the frame, then performs a lookup up of the address table by header and forwards Switch check the first 64 bytes, if it finds error, the packet will be discarded.

  • Store-and-Forward Switching

  • Cut-Through Switching

    Fragment free switching is a modified form of cut-through switching - the switch waits for the collision window (64 bytes) to pass before forwarding the frame.

  • Layer 2 and Layer 3 SwitchingLayer 2 LAN switchingA Layer 2 LAN switch performs switching and filtering based only on the OSI data link layer (Layer 2) MAC address.Layer 3 LAN switchingA Layer 3 switch can also use IP address information. Configured with routing tables and can use dynamic routing protocols. Note: hardware based forwarding on a switch is faster than software based forwarding on router

  • Ethernet Port Technology

  • Duplex Communication

  • Switch Port Settings

  • Switch Port SettingsPorts can be configured to auto or manually set for speed, duplex, flow control, mdix etc.

    CommandPurposespeed{10|100|1000|auto}Enter the speed parameter for the port.duplex{full|half|auto}Enter the duplex parameter for the port.flowcontrol{receive|send} {on|off|desired}Configure the flow control mode for the port.mdix autoEnable auto-MDIX on the interface.

  • Switch Port SettingsAuto (default for UTP) - negotiates half/full duplex with connected device.Full sets full-duplex modeHalf - sets half-duplex modeAuto is fine if both devices are using it. Potential problem if switch uses it and other device does not. Switch defaults to half.Full one end and half the other errors.

  • Auto-MDIX FeatureWhen auto-MDIX is enabled, the interface automatically detects cable is straight through or crossover and configures the connection appropriately.To use this command, the interface speed and duplex must be set to auto.Depends on IOS versionEnabled by default from 12.2(18)SE onDisabled from 12.1(14)EA1 to 12.2(18)SENot available in earlier versions

  • Flow ControlStandard EthernetFast EthernetGigabit EthernetCongestion

    Half-duplexFull-duplexBackpressure PAUSE frame

  • Half-duplex Flow ControlbackpressureEmulate collision to preventthe cache from overflowing100Mbps10Mbps100Mbps server sends data to a 10Mbps client PC through the switch, the switch will try its best to catch frames until its cache is nearly full.

  • Full-duplex Flow ControlIEEE802.3x standard defines a new method, to handle flow control with full-duplex mode. Switch creates a PAUSE frame, using reserved multicast address: 01-80-C2-00-00-01. the switch sends the frame to the traffic source, when it is received, the receiver will pause or stop sending.

    Since a PAUSE frame uses a reserved multicast address, it wont be forwarded by a bridge or switch, thus PAUSE frame wont create add-on information.

  • Full-duplex Flow ControlApplication situation of PAUSE function:Simple point to point network, between two terminalsA switch and a terminalThe link between switchesPAUSE frame realizes very simple flow control

  • *The history of Ethernet:1973, Ethernet was invented at Xerox in Palo Alto, California. Dr Robert Metcalfe is regarded as the father of Ethernet. Early Ethernet standards, the prototype of todays Ethernet ran at a speed of 2.94 Mbps.1980, Digital Equipment Corporation, Intel and Xerox promoted Ethernet as a standard, the so called Ethernet DIX80 or Ethernet version 1 standard which standardized 10Mbps Ethernet.1982, A second revision of Ethernet, known as Ethernet DIX82 or Ethernet version II. The Ethernet II remains the Ethernet standard used in todays networks.1995, IEEE issued the standard for Fast Ethernet, namely, the 802.3u standard.1998, IEEE issued the standard for gigabit Ethernet.1999, IEEE 802.3ab or 1000 BASE-T standard was published.July 18th, 2002, IEEE published the 802.3ae or 10G Ethernet standard which involves three physical interface standards, namely, 10GBASE-R, 10GBASE-W and 10GBASE-LX4.March, 2004, IEEE issued the 802.3ak standard or 10GBASE-CX4 for 10G Ethernet over copper twin-axial cable.

    *In the early days, Ethernet was a shared network medium. It often ran using the following transmission media:10Base5: thick coaxial cable commonly known as thicknet. The 5 refers to a maximum transmission distance of 500 meters.10Base2: thin coaxial cable commonly known as thinnet. The 2 refers to a maximum transmission distance of close to 200 meters, the true distance is 185 meters.Before shared Ethernet came into being, coaxial cable was connected with a device called a pigtail which is was inserted by cutting a small hole in the coaxial cable. Extreme care had to be taken when inserting a pigtail into the coaxial cable due to the potential for the central core to short out on contact with the metallic shield, which could cause the failure of an entire segment.

    *At the end of 1980s, unshielded twisted pair (UTP) came into being and was soon widely used. UTP is cheap and easily made and with UTP data can be sent and received over different wires, which makes full duplex easily applied.Twisted pair cable comes in two types: shielded twisted pair (STP) and unshielded twisted pair (UTP). STP is very effective at protecting cables from external electromagnetic interference. Twisted cables are categorized by the length of a single twist for each wire pair, and they come in the following types:Category-3 twisted-pair cable The cable defined by ANSI and EIA/TIA568. Its transmission frequency is 16MHz and is mainly for transmitting voice or transmitting data with data rates of up to 10Mbps. It is often used for 10base-T networks.Category-4 twisted-pair cable Mainly used for transmitting voice or transmitting data with a typical data rate of 16Mbps. It is commonly used in token ring LANs and 10base-T/100base-T networks.Category-5 twisted-pair cable Mainly for transmitting voice or data at the rates of up to 100Mbps. It is often used for 100base-T and 10base-T networks. It one of the most widely used Ethernet cables, however has generally been superseded by an enhanced version known as Cat5e. The Cat5e standards are much more stringent and give a support the use of 4 wire pairs as opposed to 2 wire pairs used by Cat5, allowing Cat5e to support Gigabit Ethernet transmissions.

    *Ethernet interfaces on networking devices come into two types: Medium Dependent Interface (MDI) and Medium Dependent Interface Crossover (MDI_X). Ethernet interfaces of routers and interfaces of Network Interface Cards (NIC) are often MDIs. The Interfaces of hubs are considered MDI_X interfaces.Twisted-pair cables can be divided into straight cable and crossover cable types. Straight cables are used for connecting MDI and MDI_X type devices; crossover cables are mainly for connecting MDI and MDI or MDI_X and MDI_X device types. It should be noted that the pair sequence in a crossover cable results in a crossover at each end of the cable between pins 1 & 3 and 2 & 6.

    **Usually 10 Mbit/s Ethernet is only located at the access layer of the network. The new generation multimedia products, video and database products may easily chew up the bandwidth of 10Mbit/s Ethernet.

    *Besides coaxial cable and twisted pair cable, the IEEE802.3 cable also use fiber 10BASE-F. 10BASE-F was once used at the early age of Ethernet and its transmission distance can reach 2 Km.

    *The standard (10Mbps) Ethernet transmission rate is too low to meet the demands of todays networks. To meet these higher demands, IEEE issued the IEEE802.3u standard for fast Ethernet, supporting data transmission rates of 100Mbps.

    *Full-duplex fast Ethernet is capable of sending and receiving data at 100 Mbps/s rate simultaneously. Data sending and receiving are independent due to the use of separate wire pairs for transmitted and received data, which avoids collisions and interference and improves the network efficiency.The standards body EIA/TIA stands for Electronic Industries Alliance/Telecommunication Industry Association.

    *Gigabit Ethernet is an extension of the Ethernet defined by IEEE802.3, for which transmission speeds of 1Gbps are achieved. There are two standards that have been defined for gigabit Ethernet, they are IEEE802.3z (for fiber and copper) and IEEE802.3ab (for twisted-pair).

    *IEEE802.3ab specifies the standard for 1000BaseT. 1000BaseT is a kind of 10G Ethernet technologies using Type5 UTP to transmit data and its effective transmission distance reaches 100 meters as that of 100BASETX does. Users can upgrade their 100Mbps Ethernet to 1000Mbps Ethernet smoothly in their original fast Ethernet system with this technology.IEEE802.3z sets standards for three kinds of cables:1000BaseCX is based on a kind of copper shielded twisted-pair cables with high quality. The transmission distance of this cable is 25 meters and is connected by 9um D type connectors.1000BaseSX is a kind of technology using shortwave laser as the signal source. The wavelength of the laser is set to be within the scope of 770-860nm (usually 800nm). It supports only multi-mode fiber and cannot operate on the single modefiber.1000BaseLX is another optical gigabit Ethernet standard, using a long wavelength laser (1270-1355, usually is 1300nm),It can drive not only multi-mode fiber but also single-mode fiber.

    *10G Ethernet is the cutting-edge technology in the Ethernet world. Its transmission speed is 10 times that of a gigabit Ethernet and its working area is much wider. 10G Ethernet can be applied not only to the traditional LANs, but also WANs and MANs which were once closed to Ethernet due to its limited capabilities. 10G Ethernet can be compatible with DWDM seamlessly which stretches Ethernet to a global geographical scope without being limited by distance.Two organizations, IEEE and 10 Gigabit Ethernet Alliance (10GEA), played an important role in the standardization of 10G Ethernet. IEEE is in charge of setting standards for 10G Ethernet and it has issued IEEE802.3ae as of June 2006. IEEE802.3ae specifies the standard of 10G Ethernet that runs on fiber, a standard not so suitable for enterprise LANs that commonly transmit data through copper cabling. To meet the requirements from the 10G Ethernet that runs on copper cables, IEEE issued the 802.3ak standard in March 2004 and the IEEE 802.3an standard for 10G Ethernet over twisted-pair cabling.

    *The standard for 10G Ethernet over fiber is IEEE802.3ae, which consists of 10G BASE-X, 10GBASE-R and 10GBASE-W.10GBASE-X uses a tightly packed package which involves a rather simple WDM device, four receivers and four lasers that work at the wavelength of about 1300nm at an interval of around 25nm. Each sender and receiver pair works at a speed of 3.125 Gbps with a data rate of 2.5 Gbps.10GBASE-R is a form of serial interface based on a 64B/66B coding scheme instead of the 8B/10B scheme applied to the gigabit Ethernet. Its data rate is 10.000 Gbps/s which leads to a clock rate of 10.3 Gbps.10GBASE-W refers to the WAN interface, which is compatible with SONET OC-192. The clock rate and data rate of 10 GBASE-W are 9.953 Gbps and 9.585 Gbps respectively.The 10G Ethernet standard for fiber is IEEE802.3ae. IEEE802.3ak is the standard for 10G Ethernet over coaxial cables. 10GBASE-CX4 allows 10G Ethernet to transmit over coaxial copper lines up to a distance of 15 meters.

    *Use graphic 1.1.1.1Use graphic 1.1.1.3*In the figure above, DMAC indicates the MAC address of the destination and SMAC is the MAC address of the source. The meaning of the Length/Type field various with its values. When its (hexadecimal) value exceeds 1500, it indicates the field is a type field; when the value is less than or equal to 1500, the field indicates it is a frame length field. The value of the DATA/PAD field represents the length of the data filled to make the frame length to be 64 bytes or above. FCS refers to the extra checksum characters added to a frame for error detection and correction.When the value of the Length/Type field exceeds 1500, the MAC sub-layer can submit the frame to a protocol at the upper layer immediately without going through the LLC sub-layer. This structure is the Ethernet_II structure which is very popular and used by most protocols. In this structure, the data-link layer only involves the MAC sub-layer and does not implement the LLC layer. When the value of the Length/Type is less than or equals to 1500, it indicates the Ethernet_SNAP structure which is set by the 802.3 committee but is not widely used.

    *An Ethernet frame whose type is 0800 is an Ethernet_II frame, as 0x0800 when converted from Hexadecimal to Decimal is bigger than 1500 and must be an IP datagram, since 0800 represents the IP datagram header. In a similar way, it is possible to determine that a 0806 frame is for ARP request/response and a 8035 frame is for RARP request/response.However, the question remains how we can identify the type of a the next frame header defined in 802.3 since the 802.3 frame indicates only the frame length instead of the frame type'?

    *In an 802.3 frame, there is a three-byte 802.2 LLC and a five-byte 802.2 SNAP header. The values of Destination Service Access Point (DSAP) and Source Service Access Point (SSAP) are both set to 0xAA. The Ctrl field is set to 3 and the 3-byte org code field that comes after it is set to 0. The following TYPE field functions the same as that of the Ethernet_II frame.

    *Use graphic 1.1.1.1Use graphic 1.1.1.3*Forwarding Frames Based on the Destination MACThe switch forwards frames according to its MAC address table. If the destination address of the frame is not in the table, the switch will flood the frame. The switch maintains its MAC address table through an automatic learning and aging mechanism. Frame structures are not modified in most cases. (VLAN makes changes to the frame structure by putting a TAG in the frame.)*The switch receives a data frame from the local segment via one of its port interfaces.The switch builds its MAC address table by learning the source MAC of the frames and maintains its MAC address table with the aging mechanism. The switch looks for the destination MAC in its MAC address table and if the destination MAC is in the table, then the switch sends the frame to the corresponding port (the source port is not included); if the switch cannot find the destination MAC in its table, then it sends the frame to all the ports except the source port.*1.2.1.4 Store-and-Forward Switching*1.2.1.5 Cut-Through Switching*Use graphic 1.1.1.1Use graphic 1.1.1.3*Network congestion occurs when data are transmitted between two ports with different speed rates (for example, when a 100Mbps port sends data to a 10Mbps port.) or a link or node is carrying so much data that its quality of service deteriorates. Typical effects include queuing delay, packet loss or more retransmissions which wastes network resources dramatically. In real networks, especially for LANs, network congestion seldom occurs. So no switch manufacturers produce switches with flow control functions. High-capability switches should support backpressure in the half duplex mode and flow control in the full duplex mode defined by IEEE802.3x.

    *Bridged or half-duplex Ethernet uses a method called backpressure to manage transmission between stations with different speeds. For example, when a 100Mbps server sends data to a 10Mbps client PC through the switch, the switch will try its best to cache frames until its cache is nearly full, at which time it must ask the server to stop sending more data. To achieve this the switch can generate a collision event with the server to make the server retreat, or alternatively the switch can apply a carrier test to keep the server port busy. The two approaches can both cause the server to stop sending data for a while which gives time for the switch to process the data in its cache.

    *In the full duplex environment, the link between the server and the switch is a collision-free channel and the backpressure technology cannot be applied to it. So the server continues to send packets to the switch until the frame cache of the switch overflows. To solve the problem, IEEE made a compound full duplex flow control standard, namely, IEEE 802.3x. IEEE 802.3x defines the format of a 64-byte MAC control frame named PAUSE. When congestion occurs at the port, the switch sends PAUSE to the source to tell it to stop sending information for a while.

    *PAUSE is applied to prevent frames from being dropped when an instantaneous influx of traffic causes an overflow to the cache. The PAUSE frame can help the device prevent loss of frames when the traffic surpasses the cache limit. The device sends a PAUSE frame to its peer to prevent its cache overflow by requesting the peer device stop sending data after it receives the PAUSE frame. In this way, the device wins time to relieve the congestion/buildup in its cache.