computer networking basics

Learn Computer Networking Basics

The tutorial covers the basics of computer networking.  The basics include what computer networking is and how to set up a network using devices. The role of computer networking is very crucial for a long time in communication.  With time, there are faster and better technology options we have for a network.

A network consists of multiple devices  – routers, HUB, Switch, and Computers, connect each other using a wired or wireless medium. To build a computer network at any premises, understanding of how to connect components to each other is essential .

The tutorial coverts the basic understanding of the following:

  • Addressing Of devices(IP address) – How connected devices are discovered on the network.
  • Hub, Switches, and cables are the hardware components for a network.
  • How to do traffic flow shaping using Routers and security using firewalls.
  • Role of Clients and servers—how services e.g e-mail and web pages work using networks.

Client and Server in networking

On the network, a server and client have an essential relationship.  The server is a computing element that holds the necessary resources for a service, such as a mail server, a website for a web service, etc. For example, the computer hosting www.gmail.com is the server for mail service, and any other website (e.g www.cspsprotocol.com) is an example of a web server.  The server sends the content or pages when requested.

A client is another computing device, it can be a phone or laptop, that requests to use the service or to download the content from a server.  The client first connects to the server, then sends the service request. For example, when you open the GMAIL, your computer is the client and Gmail is the server.  The client connects to the server using TCP/IP then sends the login request. The web browsing is another example where your computer (more precisely web browser) is the client.

In the following example, we are demonstrating an example of client-server on Local Area Network (LAN)

  • Both computers are reachable from each other over the LAN cable.
  • The client requests a webpage from the server by typing a URL in the web browser.
  • The server returns the request page to the client. The client’s web browser displays the contents.

Most of the computer networking works in a client-server model. A server is a computer that can be located anywhere.

IP Address:

To accomplish any communication there is a need for origination and destination address.  The same applies to computer networks.  The address of a computer is an Internet Protocol(IP) address.  Here we will only discuss the IPv4 address only (no IpV6), which is of four bytes long each byte is separated by a dot(.).  An example of an IP address is 135.56.7.2.

Based on accessibility there are two types of IP addresses one is public and another is private. A public IP address or network is accessible from anywhere in the world. While private IP addresses are not.

For e.g, the www.google.com is hosting on the public domain.   The public address range is allocated to the ISPs is a country from IANA/ICANN.  While routing a packet with the public destination address, the network knows to which country packed needs to route. When it reaches ISP in that county, ISP knows how to send the packet to the final destination. In the real-world, the address of the house is similar to the Public IP address.  When we send a post(similar to network packet) first reaches the country than to the exact address.

A private IP may communicate with an external computer via another public IP, mostly LAN router.  The LAN is an example of a private network, which may be hidden behind the internet router with public IP assigned by the ISP. When a packet originates from a LAN computer,  and the destination is private IP. The router sends the packet to the local machine. If public IP, the router sends outside via ISP.

Network Hubs and Switches

The first thing to create a computer network is to connect the devices via Cable. Mostly the cable is the Ethernet cable, which has four pairs of wires in plastic packing. It looks similar to the regular phone cables but can transfer much more data than phone wires. With a cable there can be a connection between the two computers only. But a computer network may have multiple computers, those can communicate with each other.

The first basic solution is the hub. In the hub, there are multiple ports for ethernet. A connected network looks like a star, with hub the network topology is the star topology.

The following example shows how the HUB works. When the sender wants to send a network message to the receiver computer. It sends the message using a directly connected ethernet cable with the HUB. To send further, the hub broadcast the same message to all the connected computers.

This may lead to slow done if multiple computers start sending messages, as one packet generating many network packets.  There may be a collision too.

To overcome this problem, a network can use a switch.  Switch do not send repeat message to the network, only sends to the destination computer. This reduces the network bandwidth usage and increases performance.

Both Hub and Switches can only transmit the message to the directly connected computers.  To achieve forward a message there is a router.

Network Router and Firewall:

The routes are the core part of the networking. As the name suggests, they have the capability to route the messages. Apart from routering, there may be a firewall along with the router, which does traffic shaping.  Mosty routers are located between edges of WAN or LAN.  Following are few functions a router performs:

Bridging two different networks:

One of the basic functions, to bridge two or more different types of networks. If there there are two networks with different subnets a router can connect them to each other. One example of bridging is the internet connection we use in the house. Wen the internet router bridges home network to ISP.

Other functions of the router:
  1. As DHCP – Optionally a router can work as a DHCP server. In DHCP, a router assigns the IP addresses to the connected computers.
  2. As Firewall – A router may block a packet based on network parameters.
  3. VPN Server/Client – With the VPN feature a router can connect to any other VPN server to transfer messages securely.  When a router works in a client mode, there can be VPN accounts created one to access a company machine.
  4. Port Forwarding – Another way to access an internal company machine from an external device.  The routers forward a particular port to an internal machine.

Common definitions in computer networking.

  1. LAN – Local Area Network, is a private network inside a home or office.
  2. WAN – Wide area networks – connects two widely separated LANs.
  3. VPN – A private secure network.
  4. NIC – Network Interface Card – Hardware card in a computer to plug an Ethernet cable.
  5. HUB – Device to connected computers.
  6. Intranet – Internal network based on internet technologies.

 

Leave a Comment