Networking Tutorial : Understanding Computer Networks, Protocols, Architecture and Data Communication
Networking began in the 1960s with the development of ARPANET, the first packet-switching network, which laid the groundwork for the internet. Early networks connected research institutions, evolving rapidly into the global internet we use today, transforming communication and data exchange.
What is Networking?
Networking refers to the practice of connecting computers and other devices to share resources, data and services. It is the backbone of communication in the modern world, enabling everything from browsing the internet to sending an email.
Computer networks allow people across the world to communicate using various means including social media platforms such as twitter, linkedin, X (formerly twitter) etc. Computer networks are connected using various wired and wireless mediums as shown in figure-1. Wired communication uses coaxial cable, fiber optic cable and twisted pairs where as wireless mediums uses radio frequency (RF) waves for communication. All the wired and wireless technologies are categorized into LAN, MAN and WAN.
![Networking](https://www.rfwireless-world.com/images/Networking.webp)
Types of Computer Networks
1. Local Area Network (LAN) :
• Covers a small geographical area, like a home, office, or building.
• High-speed and low latency.
• Commonly uses Ethernet cables or Wi-Fi.
2. Wide Area Network (WAN) :
• Spans large geographical areas, such as cities or countries.
• Lower speed compared to LAN.
• Uses leased telecommunication lines, satellites, or the internet.
3. Metropolitan Area Network (MAN) :
• Connects multiple LANs within a city or metropolitan area.
• Faster than WAN but slower than LAN.
4. Personal Area Network (PAN) :
• A network for personal devices, such as smartphones, tablets, and laptops.
• Typically covers a range of a few meters (e.g., Bluetooth).
5. Wireless Networks :
• Uses radio waves for communication (e.g., Wi-Fi, cellular networks).
• Allows mobility and eliminates the need for physical cables.
Networking Protocols
What are Protocols?
➨Protocols are a set of rules that govern data communication between network devices,
ensuring reliable and standardized communication.
Key Networking Protocols:
1. Transmission Control Protocol/Internet Protocol (TCP/IP)
• The foundation of the internet.
• TCP ensures reliable data transmission with error checking and retransmission of lost packets.
• IP handles addressing and routing, directing packets to their destinations.
2. User Datagram Protocol (UDP)
• A connectionless protocol that sends data without error checking.
• Faster than TCP but less reliable, used for applications like video streaming.
3. Hypertext Transfer Protocol (HTTP/HTTPS)
• Used for transmitting web pages over the internet.
• HTTPS adds a layer of security with encryption.
4. File Transfer Protocol (FTP)
• Used for transferring files between a client and server.
• Supports both upload and download.
5. Simple Mail Transfer Protocol (SMTP)
• Used for sending emails.
6. Domain Name System (DNS)
• Translates domain names (like www.example.com) into IP addresses.
7. Dynamic Host Configuration Protocol (DHCP)
• Automatically assigns IP addresses to devices on a network.
Networking Architecture
What is Networking Architecture?
➨Networking architecture refers to the overall design and structure of a network, defining how different
devices and components interact.
Types of Networking Architectures:
1. Client-Server Architecture
• Centralized system where clients request services from a server.
• Common in web services, email systems, and database access.
2. Peer-to-Peer (P2P) Architecture
• Decentralized system where each device can act as both a client and a server.
• Used in file-sharing networks like BitTorrent.
3. Hybrid Architecture
• Combines elements of both client-server and P2P architectures.
• Used in many modern applications.
Data communication
Let us understand how data is transported between peers on two sides.
![OSI_TCPIP](https://www.rfwireless-world.com/images/OSI_TCPIP.webp)
OSI Layer
Data transport involves multiple steps, which are facilitated by the OSI (Open Systems Interconnection) model:
1. Application Layer : User-facing protocols (e.g., HTTP, SMTP).
2. Presentation Layer : Data translation and encryption.
3. Session Layer : Establishes and manages connections.
4. Transport Layer : Ensures reliable communication (e.g., TCP, UDP).
5. Network Layer : Handles routing of data (e.g., IP).
6. Data Link Layer : Manages data frames and error detection.
7. Physical Layer : Transfers raw bits over physical media (e.g., cables, radio waves).
TCP/IP Stack
The TCP/IP stack consists of four layers, each responsible for specific functions in network communication.
Here’s a brief overview of the key protocols at each layer with their major functions.
1. Application Layer :
The Application layer is the topmost layer of the TCP/IP stack. It provides protocols that applications use to communicate over a network.
• HTTP (Hypertext Transfer Protocol) / HTTPS (HTTP Secure):
Used for transferring web pages and resources over the internet. HTTPS adds a layer of security using SSL/TLS encryption.
• FTP (File Transfer Protocol): Facilitates the transfer of files between a client and a server. Supports commands for file manipulation.
• SMTP (Simple Mail Transfer Protocol): Used for sending and forwarding emails between mail servers.
• POP3 (Post Office Protocol 3) / IMAP (Internet Message Access Protocol): POP3 downloads emails from the server to the client, while IMAP allows
managing emails directly on the server.
• DNS (Domain Name System): Translates human-readable domain names (e.g., www.example.com) into IP addresses.
• DHCP (Dynamic Host Configuration Protocol): Automatically assigns IP addresses and other network configuration settings to devices.
• SNMP (Simple Network Management Protocol): Used for network management, monitoring devices, and collecting information about network performance.
2. Transport Layer :
The Transport layer is responsible for end-to-end communication, reliability, and data flow control between devices.
• TCP (Transmission Control Protocol): Provides reliable, ordered, and error-checked delivery of data.
It establishes connections, manages data retransmission, and ensures data integrity.
• UDP (User Datagram Protocol): Offers a connectionless service that sends data without establishing
a connection or ensuring delivery. It’s faster but less reliable, suitable for applications like video streaming or online gaming.
3. Internet Layer :
The Internet layer handles the logical addressing and routing of data packets across networks.
• IP (Internet Protocol): Routes and addresses packets of data so they can travel across networks. IP defines the packet structure and
addressing format (IPv4 or IPv6).
• ICMP (Internet Control Message Protocol): Used for error reporting, diagnostics, and network testing. For example,
the ping command uses ICMP to check connectivity.
• ARP (Address Resolution Protocol): Resolves IP addresses to MAC (Media Access Control) addresses on a local network,
enabling communication between devices on the same LAN.
• RARP (Reverse Address Resolution Protocol): Allows a device to request its IP address from a network server using
its MAC address. Mostly outdated, replaced by DHCP.
4. Network Access Layer (Link Layer) :
The Network Access layer (also known as the Link Layer) deals with the physical transmission of data over network media and hardware addressing.
In the context of the TCP/IP stack, both PHY and MAC are components of the Network Access (Link) Layer. This layer is responsible for the physical and logical connection between devices on the same network segment.
The Physical Layer (PHY) is concerned with the actual transmission of raw bits over a physical medium, such as cables, fiber optics, or radio waves.
The Media Access Control (MAC) layer is a sublayer of the Data Link layer within the Network Access Layer. It handles the protocol that controls access to the shared medium.
• Ethernet: A widely used protocol in wired LANs. It defines wiring and signaling standards for the physical and data link layers.
• Wi-Fi (IEEE 802.11): A wireless networking protocol that provides data transmission over radio waves in WLANs (Wireless Local Area Networks).
• PPP (Point-to-Point Protocol): Provides a standard way to transport multi-protocol data between two directly connected (point-to-point) nodes.
Commonly used in dial-up internet connections.
• Frame Relay: A protocol for high-speed packet switching in WANs. It’s often used for connecting LANs to form a larger network.
• ATM (Asynchronous Transfer Mode): A protocol that transmits data in fixed-size cells, suitable for high-speed networks and real-time applications.
Networking Components and Devices
Key Components and Their Functions:
1. Router :
• Directs data packets between different networks.
• Determines the best path for data to travel.
2. Switch :
• Connects devices within the same network.
• Operates at the Data Link layer, forwarding data based on MAC addresses.
3. Modem :
• Modulates and demodulates signals for internet connectivity.
• Converts digital data from a computer into analog for transmission over phone lines or cable.
4. Access Point (AP) :
• Extends the range of a wireless network.
• Allows wireless devices to connect to a wired network.
5. Firewall :
• Protects networks by controlling incoming and outgoing traffic based on security rules.
• Can be hardware, software, or a combination of both.
6. Network Interface Card (NIC) :
• A hardware component that connects a computer to a network.
• Can be wired (Ethernet) or wireless (Wi-Fi).
7. Repeater :
• Boosts signals to extend the range of a network.
8. Bridge :
• Connects two or more LANs, making them function as a single network.
Conclusion
Networking is a fundamental component of modern computing, enabling the connectivity and communication that underpin the internet and countless other technologies. Understanding the basics of networking protocols, architectures, and devices is essential for anyone working in IT or looking to understand how data flows across the globe.
Networking related links
ARP Request and ARP Response
TCP IP packet format
Networking Gateway
What is Router
What is an IP address
network switch
network bridge
Hub and Types of Hub
What is MAC address