Hubb Switch

Embed Size (px)

Citation preview

  • 7/30/2019 Hubb Switch

    1/4

    What is the difference between an Ethernet hub and switch?

    Although hubs and switches both glue the PCs in a network together, a switch ismore expensive and a network built with switches is generally considered faster thanone built with hubs. Why?

    When a hub receives a packet (chunk) of data (aframe in Ethernet lingo) at one of its ports from a PCon the network, it transmits (repeats) the packet toall of its ports and, thus, to all of the other PCs onthe network. If two or more PCs on the network tryto send packets at the same time a collision is saidto occur. When that happens all of the PCs have togo though a routine to resolve the conflict. Theprocess is prescribed in the Ethernet Carrier SenseMultiple Access with Collision Detection (CSMA/CD)

    protocol. Each Ethernet Adapter has both a receiver and a transmitter. If theadapters didn't have to listen with their receivers for collisions they would be able tosend data at the same time they are receiving it (full duplex). Because they have tooperate at half duplex (data flows one way at a time) and a hub retransmits datafrom one PC to all of the PCs, the maximum bandwidth is 100 Mhz and thatbandwidth is shared by all of the PC's connected to the hub. The result is when aperson using a computer on a hub downloads a large file or group of files fromanother computer the network becomes congested. In a 10 Mhz 10Base-T networkthe affect is to slow the network to nearly a crawl. The affect on a small, 100 Mbps(million bits per scond), 5-port network is not assignificant.

    Two computers can be connected directly togetherin an Ethernet with acrossover cable. A crossovercable doesn't have a collision problem. It hardwiresthe Ethernet transmitter on one computer to thereceiver on the other. Most 100BASE-TX EthernetAdapters can detect when listening for collisions isnot required with a process known as auto-negotiation and will operate in a full duplex mode when it is permitted. The result is acrossover cable doesn't have delays caused by collisions, data can be sent in both

    directions simultaneously, the maximum available bandwidth is 200 Mbps, 100 Mbpseach way, and there are no other PC's with which the bandwidth must be shared.

    An Ethernet switch automatically divides the network into multiple segments, acts asa high-speed, selective bridge between the segments, and supports simultaneousconnections of multiple pairs of computers which don't compete with other pairs ofcomputers for network bandwidth. It accomplishes this by maintaining a table ofeach destination address and its port. When the switch receives a packet, it readsthe destination address from the header information in the packet, establishes atemporary connection between the source and destination ports, sends the packeton its way, and then terminates the connection.

    http://www.duxcw.com/digest/Howto/network/cable/cable1.htmhttp://www.duxcw.com/digest/Howto/network/cable/cable1.htmhttp://www.duxcw.com/digest/Howto/network/cable/cable1.htmhttp://www.duxcw.com/digest/Howto/network/cable/cable1.htm
  • 7/30/2019 Hubb Switch

    2/4

    Picture a switch as making multiple temporary crossover cable connections betweenpairs of computers (the cables are actually straight-thru cables; the crossoverfunction is done inside the switch). High-speed electronics in the switchautomatically connect the end of one cable (source port) from a sending computer tothe end of another cable (destination port) going to the receiving computer on a per

    packet basis. Multiple connections like this can occur simultaneously. It's as simpleas that. And like a crossover cable between two PCs, PC's on an Ethernet switch donot share the transmission media, do not experience collisions or have to listen forthem, can operate in a full-duplex mode, have bandwidth as high as 200 Mbps, 100Mbps each way, and do not share this bandwidth with other PCs on the switch.

    Hubs, switches, and routers are all devices that let you connect one or morecomputers to other computers, networked devices, or to other networks. Each hastwo or more connectors called ports into which you plug in the cables to make theconnection. Varying degrees of magic happen inside the device, and therein lies thedifference. I often see the terms misused so let's clarify what each one really means.

    Ahub is typically the least expensive, least intelligent, and least complicated of thethree. Its job is very simple: anything that comes in one port is sent out to theothers. That's it. Every computer connected to the hub "sees" everything that everyother computer on the hub sees. The hub itself is blissfully ignorant of the databeing transmitted. For years, simple hubs have been quick and easy ways to connectcomputers in small networks.

    Aswitch does essentially what a hub does but more efficiently. By paying attentionto the traffic that comes across it, it can "learn" where particular addresses are. For

    example, if it sees traffic from machine A coming in on port 2, it now knows thatmachine A is connected to that port and that traffic tomachine A needs to only besent to that port and not any of the others. The net result of using a switch over ahub is that most of the network traffic only goes where it needs to rather than toevery port. On busy networks this can make the network significantly faster.

    Arouter is the smartest and most complicated of the bunch. Routers come in allshapes and sizes from the small four-port broadband routers that are very popularright now to the large industrial strength devices that drive the internet itself. Asimple way to think of a router is as a computer that can be programmed to

    understand, possibly manipulate, and route the data its being asked to handle. Forexample, broadband routers include the ability to "hide" computers behind a type offirewall which involves slightly modifying the packets of network traffic as theytraverse the device. All routers include some kind of user interface for configuringhow the router will treat traffic. The really large routers include the equivalent of afull-blown programming language to describe how they should operate as well asthe ability to communicate with other routers to describe or determine the best wayto get network traffic from point A to point B.

    A quick note on one other thing that you'll often see mentioned with these devices

    and that's network speed. Most devices now are capable of both 10mps (10 mega-bits, or million bits, per second) as well as 100mbs and will automatically detect the

  • 7/30/2019 Hubb Switch

    3/4

    speed. If the device is labeled with only one speed then it will only be able tocommunicate with devices that also support that speed. 1000mbs or "gigabit"devices are starting to slowly become more common as well. Similarly many devicesnow also include 802.11b or 802.11g wireless transmitters that simply act likeadditional ports to the device.

  • 7/30/2019 Hubb Switch

    4/4