How does the Internet work?

  • 27 نوفمبر، 2024
  • بواسطة : admin

What is a network?

Before we talk about the Internet, we need to define what a “network” is. A network is a group of connected computers that are able to exchange data. A computer network is very similar to a social club, which is a group of people who know each other, regularly exchange information, and coordinate activities in a collaborative way.

What is the Internet?

The Internet is a vast, sprawling collection of networks that connect to each other. In fact, you might say that the word “Internet” comes from this concept: interconnected networks.

Because computers connect to each other in networks, and these networks also connect to each other, a computer can communicate with another computer in a distant network through the Internet. In this way, information can be exchanged quickly between computers around the world.

Computers connect to each other and to the Internet through wires, cables, radio waves, and other types of network infrastructure. All data sent over the Internet is translated into pulses of light or electricity, also called “bits,” and then interpreted by the receiving computer. Wires, cables, and radio waves carry these bits at the speed of light. The more bits that can be transmitted over these wires and cables at the same time, the faster the Internet works.

What is distributed networking and why is this concept important for the Internet?

There is no control center for the Internet. Rather, it is a distributed network system, which means that it does not depend on any single machine. Any computer or hardware that can send and receive data in the correct way (i.e., using the correct network protocol) can be part of the Internet.

The distributed nature of the Internet makes it resilient. Computers, servers, and other network hardware continually connect and disconnect from the Internet without impacting the functioning of the Internet, unlike a computer, which might not function at all if a component fails. This is also true at scale: if one server, an entire data center, or an entire region of data centers goes down, the rest of the Internet can still function (although perhaps more slowly).

How does the Internet work?

There are two main concepts that are fundamental to how the Internet works: packets and protocols.

Packets

In networking, a packet is a small segment of a larger message. Each packet contains both data and information about that data. The information about the contents of the packet is known as a “header” and is placed at the front of the packet so that the receiving machine knows what to do with it. To understand the purpose of a packet header, think about how some consumer products come with assembly instructions.

When data is sent over the Internet, it is first broken into smaller packets, which are then translated into bits. The packets are routed to their destination by various network devices such as routers and switches. When the packets arrive at their destination, the receiving device reassembles the packet in the expected order and can then use or display the data.

Compare this process to how the Statue of Liberty was built in the United States. It was designed and first built in France. However, it was too large to be transported on a ship, so it was shipped to the United States in pieces, along with instructions on where each piece should go. Workers who received the pieces reassembled them into the statue that stands in New York today.

While this approach took a long time to build the Statue of Liberty, sending digital information in smaller pieces is extremely fast on the Internet. For example, a photo of the Statue of Liberty stored on a Web server can travel around the world in one packet at a time and be uploaded to someone’s computer in a matter of milliseconds.

Packets are sent across the Internet using a technique called “packet switching.” Routers and switches in between can process packets independently of each other, regardless of where they originate or go. It’s all designed this way so that no single connection dominates the network. If data were sent between computers all at once without packet switching, a connection between two computers could consume multiple cables, routers, and switches for minutes at a time. In essence, only two people would be able to use the Internet at a time, instead of the nearly unlimited number of people that are actually available.

Protocols

Connecting two computers, both of which may use different hardware and run different software applications, is one of the major problems that the inventors of the Internet had to solve. It requires the use of communication techniques that all the connected computers can understand, just as two people who grew up in different parts of the world might need to speak a common language to understand each other.

This problem is solved with standardized protocols. In networking, a protocol is a standardized way of performing certain actions and formatting data so that two or more devices can communicate and understand each other.

There are protocols for sending packets between devices on the same network (Ethernet), for sending packets from network to network (IP), for ensuring that packets are distributed correctly in the expected order (TCP), and for formatting data for websites and applications (HTTP). In addition to these basic protocols, there are also protocols for routing, testing, and encryption. And there are also alternatives to the protocols just mentioned for different types of content: for example, video streaming often uses UDP instead of TCP.

Because all computers connected to the Internet can interpret and understand these protocols, the Internet works regardless of who or what connects to it.

What physical infrastructure enables the Internet to function?

There are many types of hardware and infrastructure that make the Internet work for everyone. Some of the more important types include the following:

  • Routers: forward packets to different computer networks based on their destination. Routers are like the traffic cops of the Internet: they make sure that Internet traffic is directed to the right networks.
  • Switches: connect devices that share a single network. They use packet switching to forward packets to the correct devices. They also receive outgoing packets from those devices and direct them to the correct destination.
  • Web servers: specialized, high-powered computers that store and deliver content (web pages, images, videos) to users, as well as host applications and databases. Servers also respond to DNS queries and perform other important tasks to keep the Internet running smoothly. Most servers are located in large data centers around the world.

How do these concepts relate to user access of websites and applications over the Internet?

Let’s take the example of this article. For your viewing pleasure, it was sent across the Internet fragment by fragment in the form of several thousand packets. These packets traveled over wires and radio waves and through routers and switches from our web server to your computer or device. Your computer or smartphone received that packet and transmitted it to your device’s browser. In turn, the browser interpreted the data inside the packets to show you the text you are reading now.

The specific steps involved in this process are:

  1. DNS Query: When your browser started loading this web page, it probably first performed a DNS query to find out the IP address of Cloudflare’s website.
  2. TCP handshake: Your browser opened a connection to that IP address.
  3. TLS Handshake: Your browser has also configured encryption between a Cloudflare web server and your device so that attackers cannot read the data packets that pass between these two endpoints.
  4. HTTP Request: Your browser has requested the content on this web page.
  5. HTTP Response: Cloudflare’s server transmitted the content in the form of HTML, CSS, and JavaScript code, broken up into a series of data packets. Once your device received the packets and verified that it had received them all, your browser interpreted the HTML, CSS, and JavaScript in the packet to show you this article about how the Internet works. The entire process only took a second or two.

Leave a comment

لن يتم نشر عنوان بريدك الإلكتروني. الحقول الإلزامية مشار إليها بـ *

error: Content is protected !!
Call Now Button
×