Resources | Subject Notes | Information Technology IT
This section describes the fundamental components used in computer networks: routers, switches, and hubs. Understanding their functions is crucial for comprehending how data is transmitted across networks.
A hub is a simple networking device that connects multiple devices together in a network. It operates at the physical layer (Layer 1) of the OSI model.
How it works: When a hub receives a data packet from one of its connected devices, it simply broadcasts the packet to all other devices connected to it. This means every device on the network receives the data, regardless of whether it's the intended recipient.
Advantages:
Disadvantages:
A switch is a more intelligent networking device than a hub. It operates at the data link layer (Layer 2) of the OSI model.
How it works: A switch learns the MAC addresses of devices connected to its ports. When a data packet arrives, the switch examines the destination MAC address and forwards the packet only to the port connected to that specific device. This is known as unicasting.
Advantages:
Disadvantages:
A router connects different networks together, such as a home network to the internet. It operates at the network layer (Layer 3) of the OSI model.
How it works: A router examines the destination IP address of a data packet and uses routing tables to determine the best path to forward the packet towards its destination. Routing tables contain information about different networks and the best routes to reach them.
Advantages:
Disadvantages:
Component | Layer | Function | Advantages | Disadvantages |
---|---|---|---|---|
Hub | Physical (Layer 1) | Broadcasts data to all connected devices. | Simple, Inexpensive | Network congestion, Security risk |
Switch | Data Link (Layer 2) | Forwards data only to the intended recipient based on MAC address. | Reduced congestion, Improved performance, Enhanced security | More expensive, Requires configuration |
Router | Network (Layer 3) | Connects different networks and determines the best path for data. | Connects networks, Best path determination, Security features | Complex configuration, Expensive |