Before we do the comparison, let's take a quick look at the network data in which the switch and hub are distributing. When we talk about network data, we talk about packets, each packets is labeled with a source and destination address (Also known as MAC - Media Access Control address) and every network device has its own MAC address and TCP/IP address.
Hubs:
Hub simply passes on (repeats) all the info it receives, so all the devices that connected to it ports receive that info. Hubs can be used to extend the network because they repeat everything they received. But this can result in a lot of unnecessary traffic because Hubs pass on traffic to network regardless of intended destination, then all devices that attached to the hub use the address information in each packet to work out which packets are meant for them. All network data it receives on one port will be immediately transmitted out all the other ports, so each computer must take it's turn before sending data. This is called half-duplex, it is very inefficient. However, there is no processing delay created by the Hub because there is no processing in Hub. In a small network, repeating is not a problem, but for a larger network, this can cause heavy network traffic.
A hub can send or receive information, but it can’t do both at the same time. This makes hubs slower than switches. Hubs are the least complex and the least expensive of these devices.
For a network has <= 30 uses, hub can easily cope with the network traffic.
Switches:
Switches (or a smart Hub) control the network traffic flow based on the address information in the packet (Layer 2). A switch actually learns which devices are connected to its ports (by monitoring the packets it receives), and then forwards on packets to appropriate device. This allows simultaneous communication across the switch, and reduces unnecessary network traffic. A computer plugged directly into the switch will not receive unnecessary traffic and can transmit to the switch whenever it needs to, this leaves all the bandwidth available to each machine. The Switch also memorizes the MAC address of each device and which port it resides on.
It is normal that hubs and switches are used in the same network, for differtnet purpose: the hubs extend the network by providing more ports, and the switches divide the network into smaller, less congested sections.
For a network has +> 50 uses, probably you want to use switch to divide the groups of hubs.
Comparison chart:
Hub | Switch | |
---|---|---|
Tech Spec | Hubs classify as Layer 1 devices in the OSI model | Network switches operate at layer two (Data Link Layer) of the OSI model. |
Layer | Physical layer (Layer 1 Device) | Data Link Layer (Layer 2 devices) |
Transmission Type | Broadcast only | At Initial Level Broadcast then Uni-cast & Multicast |
Spanning-Tree | No Spanning-Tree | Many Spanning-tree Possible |
Table | There is no MAC table in Hub, Hub can't learn MAC address. | Store MAC address in lookup table and maintain address at its own, Switch can Learn MAC address. |
Used in (LAN/MAN/WAN)l | LAN | LAN |
Ports | 4 ports/12 ports | Switch is multi port Bridge. 24/48 ports |
Collision | In Hub collision occur. | In Full Duplex Switch no Collision occur. |
Transmission Mode | Half duplex | Full duplex |
Cost | Cheaper | 3 or 4 times expensive than Hub |
Device Type | Passive Device (Without Software) | Active Device (With Software) & Networking device |
Broadcast Domain | Hub has one Broadcast Domain. | Switch has one broadcast domain [unless VLAN implemented] |
If you already have purchased several hubs and are experiencing a slow network, a single switch can solve your problem. Instead of having all your hubs daisy chained together, you can separate them by using the switch as the center point between all the hubs. Any traffic destined from a computer on hub one to a computer on hub two will be directed by the switch and you will avoid traffic propagating to the other hubs.
What about Router?
Routers enable computers to communicate and they can pass information between two networks—such as between your home network and the Internet. This capability to direct network traffic is what gives the router its name. Routers can be wired (using Ethernet cables) or wireless. If you want to get all of your computers access to internet, you can use a router (or a modem with a built-in router).
Switches create a network, Routers connect networks.
No comments:
Post a Comment