Chapter 10: Computer Networks

In the early 1970s, if you wanted your computer to reach another computer on the young ARPANET, you did not look the machine up anywhere. You already had the list. A single file named HOSTS.TXT held the name of every host on the network beside the number that identified it, and that file was maintained by hand at the Network Information Center at the Stanford Research Institute, under Elizabeth Feinler. Whenever a machine joined or left, somebody edited the file. Every other site then had to fetch a fresh copy.

For a few dozen machines this worked. As the network grew into hundreds and then thousands of hosts, it stopped working. The file was always slightly out of date somewhere, two sites could not agree on who owned a name, and the traffic generated by everyone downloading the same growing file became a burden in itself. A system that assumed one central list simply could not be stretched.

The answer, designed by Paul Mockapetris in 1983, was to stop keeping one list at all and to distribute the job across many servers, each responsible for a part of the naming space. That design is still in use every time you type a web address. Fig. 10.0 shows the two arrangements side by side.

Fig. 10.0

Fig. 10.0 – Central list vs. distributed naming system.

This chapter is about the ideas that let a network keep working as it grows — how devices are joined, how they are named and numbered, and how a message finds its way.

NoteCuriosity Corner

Q1. A website can be reached by a name, but the network underneath works with numbers. Why keep both, instead of just one? Q2. Every network card carries a permanent address fixed at the factory. So why does the same computer also need a second address that keeps changing? Q3. Two computers in one room, and two computers in two different countries, are both “connected”. What decides which name we give to each kind of network? Q4. A hub and a switch both join several computers together with cables. What can a switch do that a hub cannot? Q5. One broken cable can bring an entire network down, while in another arrangement the same break costs you only one computer. What makes the difference?

The chapter that follows will answer each of these questions.

10.1 Introduction to Computer Networks

You send a message from a phone in Jaipur and it appears on a screen in Kochi a moment later. You press print on a laptop and a machine on the other side of the staff room begins to hum. You open a page and text stored on a computer you will never see arrives in front of you. None of this involves any single wire running from your device to the other one. It works because your device is part of a network.

The word itself is older than computing. A railway network, a network of roads, a network of friends — in each case the useful idea is the same: a set of things joined to one another in such a way that something can travel between them.

The Everyday Sense of the Word

A network is a group of two or more similar things or people interconnected with one another. Once the connections exist, the group can do something that no single member could do alone. A railway network moves a passenger from one town to another town it has never directly been joined to, because the two towns share a system of links.

NoteDefinition

A network is a group of two or more similar things, people or devices connected to one another so that something — a person, a signal, a message — can pass between them.

You already live inside several networks. A mobile network carries your calls. A social network connects people who have never met. Airlines, railways, banks and hospitals each run networks so that a booking made at one counter is known at every other. In every one of these, the value lies not in any single node but in the connections.

10.1.1 What Makes a Collection of Devices a Network

Two computers standing side by side on a table are not a network. Put a cable between them, or let them find each other over the air, and they become one. The connection is what matters, and it must be a connection over which data can actually be exchanged.

A computer network is an interconnection among two or more computers or computing devices, which allows them to share data and resources with one another. The definition sets a floor of two, and no ceiling. A basic network may join a few computers placed in one room. The largest one joins billions of devices spread across every continent.

NoteDefinition

A computer network is an interconnection among two or more computers or computing devices that allows them to share data and resources with each other.

Notice that two conditions are packed into that sentence, and both must hold. There must be an interconnection, and it must be usable — the devices must be able to send data to each other along it. A printer sitting unplugged beside a computer is connected to nothing, and a computer that can see a network but is not permitted to exchange anything with it is, for practical purposes, outside it.

The size of a network varies enormously with the number of computers it connects, and, as you will see in section 10.3, that size is one of the things we use to classify networks in the first place. What does not vary is the basic idea: devices, links between them, and data moving over those links.

Q. Two laptops are joined by a cable, but neither has been set up to share anything. Are they a network?

A. Physically, yes — the link exists. Functionally, no. A computer network is defined by the exchange of data and resources that the interconnection permits, not by the presence of a wire. Until the two machines can actually send data to each other, the cable is only a cable.

10.1.2 Nodes, Hosts and Networking Devices

Look closely at any working network and you will find that not everything in it is a computer in the ordinary sense. The arrangement in Fig. 10.1 is typical of a small network: a few computers, a phone, a tablet and a printer, all reaching one another through a device in the middle whose only job is to join them.

Fig. 10.1

Fig. 10.1 – A small computer network with a central device.

A computer network can include different types of hosts, also called nodes — a server, a desktop, a laptop, a cellular phone. Alongside these sit the networking devices: a switch, a router, a modem and others you will meet in section 10.4. Networking devices are used to connect multiple computers in different settings, and they are members of the network in their own right, not accessories to it.

The word node is used in a precise sense here, and it is worth reading slowly. In a communication network, each device that is a part of a network and that can receive, create, store or send data to different network routes is called a node. That is a wider set than “the computers”. A node can be a modem, a hub, a bridge, a switch, a router, a digital telephone handset, a printer, a computer or a server.

NoteDefinition

A node is any device that is part of a network and that can receive, create, store or send data to different network routes.

Students often assume, reasonably enough, that a node must be something a person sits at. The definition says otherwise. A router that no one ever touches is a node, because data arrives at it and leaves it along different routes. A printer is a node, because it receives data. The test is participation in the movement of data, not the presence of a keyboard.

How Data Actually Travels

Data does not cross a network as one long, unbroken stream. For communication, data in a network is divided into smaller chunks called packets, and these packets are then carried over the network. A file of a few megabytes leaves your machine as thousands of separate pieces, each carrying a portion of the data along with information about where it is going.

NoteDefinition

A packet is a small chunk into which data is divided before being carried across a network.

This is one of the quiet design decisions that makes large networks possible at all, and Fig. 10.2 shows why it is worth the trouble. If a single long message had to travel as one piece, one damaged stretch of cable would ruin the whole of it, and one large transfer would occupy a link completely while everyone else waited. Broken into packets, the same message shares the link with other traffic, and only the damaged pieces need to be sent again.

Fig. 10.2

Fig. 10.2 – Packets from different senders sharing a link.

Devices in a network can be connected either through wired media like cables or wireless media like air. Both carry the same packets; they differ only in what the signal travels through. Chapter coverage of the media themselves belongs elsewhere, but the distinction matters here because it explains why a network need not be visible. Two smartphones exchanging a photograph across a table are as genuinely networked as two computers joined by a cable under the floor.

10.1.3 What a Network Makes Possible

A network is built for a reason, and the reasons fall into two broad groups.

The first is communication. Interconnectivity of computing devices in a network allows us to exchange information simultaneously with many parties — through email, websites, audio and video calls. The word simultaneously is doing real work in that sentence. A letter goes to one address; a message on a network can reach fifty recipients at once without being written fifty times, because the network, not the sender, does the copying.

The second is resource sharing. A printer can be made available to many computers through a network, so that a school with forty machines does not need forty printers. A networked storage device can be accessed by multiple computers, so that a file has one home rather than forty slightly different copies. Fig. 10.3 shows the arrangement in a school computer laboratory.

Fig. 10.3

Fig. 10.3 – Resource sharing in a school laboratory.

Sharing is not only about saving money. A single shared store of files is easier to keep correct and easier to keep safe than the same data scattered across many machines, because there is only one copy to update and only one copy to protect.

Networks also form far more casually than most students expect. People often connect their devices through a hotspot, thus forming a small personal network — a phone offering a connection, a laptop and a tablet joining it. Nothing has been installed and no cable has been laid, yet every element of the definition is satisfied: two or more computing devices, interconnected, sharing data.

The two purposes are not really separate. Sharing a printer is a form of communication — your computer is sending the printer a message that happens to describe a page. Every act of sharing on a network reduces, underneath, to data moving from one node to another.

List five networks you were part of yesterday, and for each one name what was being shared or exchanged. At least two of them should not involve a computer at all. Then, for one network on your list, say what would have had to happen without it.

10.2 Evolution of Networking

Nothing about today’s networks was inevitable. Every idea in this chapter — dividing data into packets, giving machines addresses, agreeing on a common set of rules, naming servers so that people need not remember numbers — was worked out by somebody who had a specific problem in front of them. Reading the history is not an exercise in memorising dates. It is the quickest way to see which problem each idea was invented to solve.

10.2.1 From ARPANET to the Internet

In the 1960s, computers were large, scarce and expensive, and each one stood alone. A researcher in one university could not use a machine in another university, however idle it happened to be, and could not read data held on it without physically travelling there or posting a tape.

In that decade, a research project was commissioned by the Advanced Research Projects Agency in the U.S. Department of Defense to connect academic and research institutions located at different places, so that they could collaborate scientifically. The network that the project built was called advanced research projects agency network (ARPANET).

The first message was communicated between the University of California, Los Angeles and the Stanford Research Institute. Two machines, hundreds of kilometres apart, built by different people for different purposes, exchanged data. Everything in this chapter descends from that link.

It is often repeated that ARPANET was built to survive a nuclear attack. The documented purpose of the project was more ordinary and more useful: letting researchers at scattered institutions share scarce computing resources and work together. Resilience came along as a property of the design rather than as its advertised goal.

Slowly but gradually, more and more organisations joined ARPANET, and many independent smaller networks were formed alongside it. This is the point at which the story stops being about one network and starts being about the problem that defines modern networking: how do you join networks that were never designed for each other?

Fig. 10.4 shows why the question is hard. Each of those smaller networks had its own equipment, its own conventions and its own idea of how data should be packaged. Joining them physically is easy; making them understand one another is not.

Fig. 10.4

Fig. 10.4 – A network of networks.

The answer was to agree on a common set of rules that every network would follow when handing data to another network. A set of rules of this kind is called a protocol, and it is one of the load-bearing ideas of the whole subject. Two machines can differ in every other respect and still communicate, provided they follow the same protocol.

NoteDefinition

A protocol is an agreed set of rules that governs how data is formatted, addressed, transmitted and received between devices on a network.

The rules adopted for this purpose were transmission control protocol / internet protocol (TCP/IP), settled on as the standard for ARPANET in 1982. Once every joining network spoke the same language at the boundary, the collection of interconnected networks could be treated as one enormous network. That network of networks is the Internet.

NoteDefinition

The Internet is the global network formed by interconnecting networks of computing devices worldwide, all of which communicate using a common protocol suite.

Read the word literally and the design becomes clear. The Internet is not a network of computers; it is a network of networks. Your school laboratory does not join the Internet as forty separate machines. It joins as one network, connected onward to another, and so on outward.

Q. If every network already worked perfectly on its own, why did anyone need a common protocol at all?

A. Because a network working perfectly on its own is exactly the problem. Each network could move data internally using its own conventions, but a packet arriving from outside meant nothing to it. A common protocol gives every network one agreed way to address, package and hand over data at the boundary, which is what allows a message to cross networks it was not built for.

10.2.2 Milestones in the Growth of Networking

The journey from one experimental link to a global system took about thirty years, and a few dates mark the turning points. Table 10.1 lists them in order.

Table 10.1 – milestones in the evolution of computer networks; the year and what was achieved in it | Year | Milestone | |—|—| | 1961 | The idea of a network connecting research institutions — the idea that became ARPANET — is conceptualised | | 1969 | ARPANET becomes functional by connecting UCLA and SRI | | 1971 | Ray Tomlinson develops network messaging, or e-mail; the symbol @ comes to mean “at” | | 1974 | The term Internet is coined; the first commercial use of the technology begins, under the name Telenet | | 1982 | TCP/IP is introduced as the standard protocol on ARPANET | | 1983 | The Domain Name System is introduced | | 1986 | The National Science Foundation brings connectivity to many more people through its NSFNET programme | | 1990 | HTML and URL are developed at CERN, giving birth to the web | | 1997 | The first version of the Wi-Fi (802.11) standard is introduced |

Fig. 10.5

Fig. 10.5 – Milestones in the evolution of networking.

What the Dates Are Telling You

Read down Table 10.1 and a pattern appears. The early entries are about connection: getting two machines to talk at all, then getting many to talk. The middle entries are about agreement — a standard protocol in 1982, a naming system in 1983 — because once the network was large, the difficulty was no longer wiring but consistency. The later entries are about reach: NSFNET taking connectivity beyond a handful of institutions, the web making the content usable by people who were not engineers, and Wi-Fi removing the cable altogether.

Two of these milestones need a word of explanation now, because you will meet them again in this chapter.

The domain name system (DNS), introduced in 1983, is the arrangement that lets a person type a name while the network works with a number. How it does that is the subject of section 10.8.

The developments at CERN in 1990 produced the web — the vast collection of interlinked pages that most people, wrongly, take to be the Internet. Section 10.7 separates the two carefully.

Q. E-mail appeared in 1971, but the Domain Name System only in 1983. How were messages addressed in between?

A. By naming the host machine directly, from a list of host names that every site held a copy of. That worked while the number of hosts was small. It is precisely the growth of the network through the 1970s that made a distributed naming system necessary, which is why the two dates are twelve years apart.

Take any three milestones from Table 10.1 and, for each, write one sentence naming the problem it solved. Then choose the one you think the network could least afford to lose, and give a reason.

10.3 Types of Networks

Networks come in every size. At one end is a phone talking to a pair of earphones across a desk. At the other are the millions of computers spread across the globe that between them carry the world’s traffic. Some are joined by wires and some through the air, and it would be useless to describe both with the same word and leave it there.

So networks are classified. Based on the geographical area covered and the data transfer rate, computer networks are broadly categorised as:

  • PAN (personal area network)
  • LAN (local area network)
  • MAN (metropolitan area network)
  • WAN (wide area network)

Notice that the classification rests on two things together, not one. Area alone would not be enough, because a network’s usefulness depends on how fast data moves through it as much as on how far it reaches — and, as you are about to see, the two tend to pull against each other.

Reading a Data Transfer Rate

The data transfer rate of a network is the amount of data it can carry past a point in one second. It is measured in bits per second, and for the networks in this chapter the convenient unit is megabits per second, written Mbps, where \(1\ \text{Mbps} = 10^6\) bits per second. A thousand of these is a gigabit per second, written Gbps.

The unit is bits, not bytes, and this trips up more students than any other detail in the chapter. A byte is \(8\) bits, so a link rated at \(8\) Mbps delivers about \(1\) megabyte of data per second, not \(8\).

NoteDefinition

The data transfer rate of a network is the quantity of data it can carry in one second, normally measured in bits per second.

10.3.1 Personal Area Network (PAN)

The smallest kind of network is the one gathered around a single person. A personal area network (PAN) is formed by connecting a few personal devices such as computers, laptops, mobile phones, smart phones and printers, as shown in Fig. 10.6. All these devices lie within an approximate range of \(10\) metres.

Fig. 10.6

Fig. 10.6 – A personal area network.

NoteDefinition

A personal area network is a network formed by connecting a few personal devices lying within an approximate range of 10 metres.

A personal area network may be wired or wireless. A mobile phone connected to a laptop through a USB cable forms a wired PAN. Two smartphones communicating with each other through Bluetooth technology form a wireless PAN, also called a WPAN.

The hotspot you met in section 10.1 is a personal area network of exactly this kind. Nothing about it looks like networking equipment, and yet the phone is doing the job that a networking device does in a larger arrangement.

10.3.2 Local Area Network (LAN)

Step up from a desk to a building and you have a local area network (LAN). It is a network that connects computers, mobile phones, tablets, mice, printers and similar devices placed at a limited distance from one another. Fig. 10.7 shows a typical one.

Fig. 10.7

Fig. 10.7 – A local area network in one building.

NoteDefinition

A local area network is a network that connects nodes placed at a limited distance from one another, such as within a single room, a floor, a laboratory, an office, or a campus with one or more buildings in the same premises.

The geographical area covered by a LAN can range from a single room, a floor, or an office having one or more buildings in the same premises, to a laboratory, a school, a college or a university campus. The connectivity is done by means of wires, Ethernet cables, fibre optics or Wi-Fi. These networks can be extended up to \(1\) km.

Two properties of a LAN follow directly from its small size, and both matter.

The first is speed. Data transfer in a LAN is quite high, and usually varies from \(10\) Mbps, called Ethernet, to \(1000\) Mbps, called Gigabit Ethernet. Short cables lose less signal and need less handling along the way, so more data gets through per second.

The second is security. A LAN is comparatively secure, because only authentic users in the network can access the other computers or the shared resources. Users can print documents on a connected printer, and upload or download documents and software to and from the local server. The boundary of the network is the boundary of a building you control, and that is a real protection that a larger network cannot offer as easily.

The word Ethernet appears twice above, and it names something specific. Ethernet is a set of rules that decides how computers and other devices connect with each other through cables in a local area network.

NoteDefinition

Ethernet is a set of rules governing how computers and other devices are connected to one another through cables in a local area network.

Q. A LAN in one school runs at 100 Mbps and a home broadband connection is advertised at 100 Mbps. Are they the same thing?

A. No. The LAN figure is the rate at which two machines inside the building can exchange data with each other; the broadband figure is the rate at which the home can exchange data with the world outside. A file copied between two laboratory computers never leaves the LAN, so it moves at LAN speed regardless of what the outside connection is rated at.

10.3.3 Metropolitan Area Network (MAN)

A metropolitan area network (MAN) is an extended form of LAN which covers a larger geographical area, such as a city or a town. This kind of network can be extended up to \(30\)–\(40\) km. Cable TV networks and cable-based broadband internet services are examples of a MAN.

NoteDefinition

A metropolitan area network is an extended form of a local area network that covers a larger geographical area, such as a city or a town.

The data transfer rate in a MAN also ranges in Mbps, but it is considerably less than in a LAN. This is the first appearance of the trade-off that runs through the whole classification: as a network reaches further, its data transfer rate falls. Signals weaken over distance and must be regenerated, more devices sit in the path, and more users share the same links.

Sometimes many LANs are connected together to form a MAN, as shown in Fig. 10.8. This is worth pausing on, because it shows how the categories nest. The individual LANs do not stop being LANs when they are joined. A larger network has simply been built out of them.

Fig. 10.8

Fig. 10.8 – A metropolitan area network built from LANs.

10.3.4 Wide Area Network (WAN)

A wide area network (WAN) connects computers and other LANs and MANs which are spread across different geographical locations of a country, or in different countries or continents. A WAN could be formed by connecting a LAN to other LANs, as in Fig. 10.9, using wired or wireless media.

Fig. 10.9

Fig. 10.9 – A wide area network connecting distant LANs.

NoteDefinition

A wide area network is a network that connects computers, LANs and MANs spread across different geographical locations of a country, or across different countries or continents.

Large business, educational and government organisations connect their different branches in different locations across the world through a WAN. A bank is the standard example: an account opened at one branch must be visible at every other branch and at every cash machine, which is possible only if all of them are nodes of one wide area network.

The Internet is the largest WAN. It connects billions of computers and smartphones, and millions of LANs, from different continents. That single sentence ties this section back to section 10.2 — a network of networks is, by construction, a wide area network on the largest possible scale.

Comparing the Four

Table 10.2 sets the four types against one another. Read the third and fourth rows together: as the area grows, the data transfer rate falls. That is the whole shape of the classification in two lines.

Table 10.2 – PAN, LAN, MAN and WAN compared | Feature | PAN | LAN | MAN | WAN | |—|—|—|—|—| | Area covered | Around one person | One room, building or campus | A city or town | A country, or several countries and continents | | Approximate range | About 10 m | Up to 1 km | 30–40 km | No practical limit | | Data transfer rate | Low | Highest of the four, 10 Mbps to 1000 Mbps | In Mbps, but considerably less than a LAN | Lowest of the four | | Ownership | One person | One organisation | Usually a service provider | Many owners together | | Typical medium | USB cable, Bluetooth | Wires, Ethernet cables, fibre optics, Wi-Fi | Cables laid across the city | Wired and wireless links over long distances | | Example | A phone connected to a laptop | A school computer laboratory | A cable-based broadband service | The Internet |

Q3. Two computers in one room, and two computers in two different countries, are both “connected”. What decides which name we give to each kind of network?

A. Two things taken together — the geographical area the network covers and the rate at which it can transfer data. Two computers in one room fall inside the range of a LAN, and, being close, they can exchange data at a high rate. Two computers in different countries are joined by a WAN, which reaches across continents but moves data more slowly, because the signal must travel far and pass through many devices and many shared links on the way. The name records both the reach and the cost of that reach.

Q. A bank lets you check your account from any part of the world. Is the bank’s network a LAN, a MAN or a WAN?

A. A WAN, and it contains the others. Each branch runs its own LAN, several branches in one city may be joined into a MAN, and all of these are connected across the country and beyond into one wide area network. Your request from a distant city travels over the WAN and is answered by a machine sitting on some branch’s LAN.

Walk through your school’s computer laboratory and write down what kind of network you are standing in, what its likely boundary is, and one resource shared across it. Then name one device in the room that belongs to a personal area network rather than to the laboratory’s network, and say what makes it different.

10.4 Network Devices

Nodes at the two ends of a conversation get all the attention, but very little of the work of a network happens at the ends. Between a computer in one town and a server in another sit devices whose whole purpose is to keep the data moving: converting it into a form the medium can carry, strengthening it when it fades, deciding which cable it should leave by, and handing it across the boundary into a different network altogether.

To communicate data through different transmission media, and to configure networks with different functionality, we require different devices — a modem, an Ethernet card, an RJ45 connector, a repeater, a hub, a switch, a router and a gateway. Each solves one specific problem, and the quickest way to keep them apart is to remember which problem each was invented for.

10.4.1 Modem

A computer stores and processes data in terms of 0s and 1s. A signal of that kind — one that takes distinct, separate values — is a digital signal. Many of the media that carry data over a distance, including an ordinary telephone line, do not carry sharp steps well; they carry a smoothly varying wave, called an analog signal.

So something has to translate. A modem is a device used for conversion between analog signals and digital bits. The name is built from the two halves of its job: MOdulator DEModulator.

NoteDefinition

A modem is a device that converts digital data into analog signals for transmission, and converts received analog signals back into digital data.

There are modems connected at both the source and the destination nodes, as Fig. 10.10 shows. The modem at the sender’s end acts as a modulator, converting the digital data into analog signals. The medium — free space, or a physical cable — carries the signal to the receiver. The modem at the receiver’s end acts as a demodulator, converting the analog signals back into digital data that the destination node can understand.

Fig. 10.10

Fig. 10.10 – Modems converting signals across a telephone line.

Notice that a modem is needed in pairs, and that it changes nothing about the data itself. The same bits leave the sender and arrive at the receiver; only the form in which they travel is different in the middle.

10.4.2 Ethernet Card

Before a computer can send anything at all, it needs hardware that understands how to put data onto a network. An Ethernet card, also known as a network interface card (NIC), is a network adapter used to set up a wired network. It acts as the interface between the computer and the network.

NoteDefinition

An Ethernet card, or network interface card, is a network adapter that acts as the interface between a computer and the network it is attached to.

It is a circuit board mounted on the motherboard of a computer, as shown in Fig. 10.11. The Ethernet cable connects the computer to the network through the NIC. Ethernet cards can support data transfer between \(10\) Mbps and \(1\) Gbps, which is \(1000\) Mbps — the same range you met for a LAN in section 10.3, and for the same reason: the card is one of the things that fixes it.

Fig. 10.11

Fig. 10.11 – A network interface card.

Each NIC also carries a permanent hardware address, fixed at the time of manufacture, which uniquely identifies that computer on the network. That address, and the very different kind of address that sits alongside it, are the subject of section 10.6.

10.4.3 RJ45

The cable has to end somewhere, and it ends in a plug. RJ45, or Registered Jack-45, is an eight-pin connector that is used exclusively with Ethernet cables for networking. It is the standard networking interface that can be seen at the end of all network cables.

Physically it is a small plastic plug that fits into the RJ45 jacks of the Ethernet cards present in various computing devices, as in Fig. 10.12. It is the least glamorous item in this section and one of the most important, because a standard connector is what allows a cable bought anywhere to fit a card made by anyone.

Fig. 10.12

Fig. 10.12 – An RJ45 connector and jack.

10.4.4 Repeater

Data are carried in the form of signals over the cable, and a signal does not travel indefinitely. These signals can travel a specified distance, usually about \(100\) m. Beyond this limit they lose their strength and become weak, and a weak signal is eventually indistinguishable from noise. In such conditions, the original signal needs to be regenerated.

A repeater is an analog device that works with the signals on the cables to which it is connected. The weakened signal appearing on the cable is regenerated by the repeater and put back on the cable, as Fig. 10.13 shows.

NoteDefinition

A repeater is an analog device that regenerates a weakened signal on the cable to which it is connected and puts the restored signal back on the cable.

Fig. 10.13

Fig. 10.13 – A repeater regenerating a weakened signal.

The word analog in that description is worth noticing. A repeater does not read the data, does not know where it is going and cannot make any decision about it. It works on the signal, not on the message. That is the whole of its job, and it is why a repeater cannot help you when the problem is congestion rather than distance.

10.4.5 Hub

Once you have more than two devices, you need something to join them. An Ethernet hub is a network device used to connect different devices through wires. Data arriving on any of its lines are sent out on all the others.

NoteDefinition

A hub is a network device that connects several devices by wire and sends data arriving on any one of its lines out on all the other lines.

Fig. 10.14 shows what that means in practice. A hub with eight ports, given a packet on port 3 that is meant for the machine on port 6, sends it to ports 1, 2, 4, 5, 7 and 8 as well. Seven machines receive data intended for one, and six of them discard it.

Fig. 10.14

Fig. 10.14 – A hub broadcasting a packet to all ports.

The limitation of a hub follows from this design: if data from two devices come at the same time, they will collide. Since everything a hub receives goes everywhere, two simultaneous transmissions meet on the shared wiring, both are corrupted, and both must be sent again. The busier the hub, the more often this happens, and the busier it gets.

10.4.6 Switch

A switch is a networking device that plays a central role in a local area network. Like a hub, a network switch is used to connect multiple computers or communicating devices. Unlike a hub, it pays attention to what it is carrying.

When data arrives, the switch extracts the destination address from the data packet and looks it up in a table to see where to send the packet. Thus, it sends signals only to selected devices instead of sending them to all, as Fig. 10.15 shows. It can forward multiple packets at the same time. It also does not forward signals that are noisy or corrupted; it drops such signals and asks the sender to resend them.

NoteDefinition

A switch is a networking device that connects multiple devices in a local area network and forwards each incoming packet only to the port on which its destination lies.

Fig. 10.15

Fig. 10.15 – A switch forwarding packets to specific ports.

Everything a switch does better than a hub follows from that one difference — it reads the destination address before it acts. Table 10.3 sets the two side by side.

Table 10.3 – hub and switch compared | Feature | Hub | Switch | |—|—|—| | Where data is sent | Out on all lines other than the one it arrived on | Only to the line on which the destination lies | | Use of the destination address | Ignored | Extracted from the packet and looked up in a table | | Simultaneous transfers | Cause a collision, and both transfers fail | Multiple packets can be forwarded at the same time | | Noisy or corrupted signals | Passed on | Dropped, and the sender is asked to resend | | Effect on unintended machines | They receive data meant for someone else and discard it | They receive nothing they were not sent |

Q4. A hub and a switch both join several computers together with cables. What can a switch do that a hub cannot?

A. A switch can tell where a packet is going. It extracts the destination address from the packet and looks it up in a table, so it forwards the packet only to the port where that destination sits, and it can carry several such transfers at the same time. A hub reads nothing; it copies whatever arrives on one line out to all the others, so every machine is disturbed by traffic meant for one, and two devices transmitting at the same moment collide. A switch also refuses to pass on noisy or corrupted signals, which a hub cannot detect at all.

Ethernet switches are common in homes and offices to connect multiple devices, thus creating LANs or providing access to the Internet.

10.4.7 Router

A hub and a switch work inside one network. A router is the device that gets data out of it. A router is a network device that can receive the data, analyse it and transmit it to other networks; it is what connects a local area network to the Internet.

NoteDefinition

A router is a network device that receives data, analyses it, and transmits it onward to other networks.

Compared to a hub or a switch, a router has advanced capabilities, because it can analyse the data being carried over a network, decide or alter how that data is packaged, and send it on to another network of a different type. Fig. 10.16 shows the situation that makes this necessary.

Suppose data has been divided into packets of a certain size, and these packets are to be carried over a different type of network that cannot handle packets that big. The data must then be repackaged as smaller packets before being sent on, and the router is what does the repackaging.

Fig. 10.16

Fig. 10.16 – A router repackaging data between networks.

A router can be wired or wireless. A wireless router can provide Wi-Fi access to smartphones and other devices, and such routers usually also contain some ports to provide wired access. These days, home Wi-Fi routers perform the dual task of a router and a modem or switch: they connect to the incoming broadband lines from an internet service provider (ISP), and convert them to digital data for computing devices to process.

An internet service provider is any organisation that provides services for accessing the Internet. The single box on the wall of a house is doing at least three of this section’s jobs at once — modem, switch and router — which is exactly why students who have only seen that box find the three hard to separate.

10.4.8 Gateway

As the term suggests, a gateway is a key access point that acts as a gate between an organisation’s network and the outside world of the Internet. It serves as the entry and exit point of a network, since all data coming into or going out of the network must first pass through the gateway in order to use routing paths.

NoteDefinition

A gateway is the entry and exit point of a network, through which all data entering or leaving that network must pass.

Besides routing data packets, gateways also maintain information about the host network’s internal connection paths and about the identified paths of other remote networks. That stored knowledge is what makes the next step possible: if a node from one network wants to communicate with a node of a foreign network, it passes the data packet to the gateway, which then routes it to the destination using the best possible route. Fig. 10.17 shows two networks communicating in exactly this way.

Fig. 10.17

Fig. 10.17 – A gateway joining two networks.

For simple Internet connectivity at homes, the gateway is usually the Internet service provider that provides access to the entire Internet. Generally, a router is configured to work as a gateway device in computer networks, but a gateway can be implemented completely in software, in hardware, or in a combination of both. Because a network gateway is placed at the edge of a network, the firewall — the arrangement that inspects traffic and blocks what is not permitted — is usually integrated with it.

That last point is not an accident of convenience. If every packet in and out must cross one point, that point is the natural place to check them, and defending one gate is a great deal easier than defending a boundary with many openings.

Table 10.4 – switch, router and gateway compared | Feature | Switch | Router | Gateway | |—|—|—|—| | Works within or between networks | Within one network | Between networks | At the edge, between a network and the outside world | | What it does with data | Forwards a packet to the port where its destination lies | Analyses data, may repackage it, and transmits it to another network | Passes all incoming and outgoing data, routing it by the best available path | | Information it keeps | A table of addresses and ports | Paths to other networks | The host network’s internal paths and the identified paths of remote networks | | Handles networks of different types | No | Yes | Yes | | Typical position | Inside a LAN | Between a LAN and the Internet | At the single entry and exit point of a network |

Q. If a router can already send data to other networks, why is a separate idea of a gateway needed at all?

A. Because gateway names a role, not a piece of equipment. The role is being the one point through which all traffic in and out of a network must pass. That role is generally filled by a router that has been configured for it, but it can equally be filled by software, by dedicated hardware, or by an ISP. Calling a device a router describes what it can do; calling it the gateway describes where it stands.

For each of the following, name the single device from this section that solves it, and give one line of reasoning: a signal that has faded after a long cable run; a laptop that has no way of accepting a network cable at all; data that must be sent from a school’s network to a network elsewhere in the country; two computers whose transmissions keep colliding on shared wiring.

10.5 Networking Topologies

Sections 10.3 and 10.4 have given you the pieces: nodes of various kinds, and devices that join them. What remains is the question of arrangement. Given ten computers and a room, in what pattern should the cables run?

The question is not decorative. The pattern decides how much cable you must buy, how much traffic the network can carry at once, and — most importantly — what happens on the day something breaks. Two networks built from identical equipment can behave completely differently under a single cable fault, purely because of how they are laid out.

The arrangement of computers and other peripherals in a network is called its topology. Common network topologies are mesh, ring, bus, star and tree.

NoteDefinition

The topology of a network is the arrangement in which its computers and other peripherals are connected to one another.

10.5.1 Mesh Topology

Start with the arrangement that holds nothing back. In a mesh topology, each communicating device is connected with every other device in the network, as shown in Fig. 10.18.

Fig. 10.18

Fig. 10.18 – Mesh topology.

NoteDefinition

In a mesh topology, every communicating device in the network is connected directly to every other device.

Three advantages follow from this at once.

Such a network can handle large amounts of traffic, since multiple nodes can transmit data simultaneously and each pair has a link of its own to do it on. It is more reliable, in the sense that even if a node goes down, it does not cause any break in the transmission of data between the other nodes. And it is more secure than the other topologies, because each cable between two nodes carries different data — a node cannot see traffic that was not addressed to it, simply because that traffic never touches its cables.

The cost of all this is the wiring. To build a fully connected mesh topology of \(n\) nodes requires

\[\frac{n(n-1)}{2}\]

wires. Each of the \(n\) nodes needs a link to the other \(n-1\) nodes, which counts every link twice, so the product is halved.

Put numbers to it. For \(n = 5\) that is \(10\) wires; for \(n = 10\) it is \(45\); for \(n = 50\) it is \(1225\). The number of nodes has grown ten times and the cabling has grown more than a hundred times. Wiring is complex and cabling cost is high, and many of those connections are redundant or unutilised — a link between two machines that never exchange anything still had to be laid and still has to be maintained.

Q. If a mesh is the most reliable and the most secure arrangement, why is almost no ordinary network built as one?

A. Because the cost grows far faster than the benefit. Going from 10 nodes to 50 multiplies the cabling from 45 links to 1225, and most of those links carry nothing on most days. A mesh is worth its price only where a failure would be very expensive — which is why the pattern survives in the links between major networks rather than between desks in a room.

10.5.2 Ring Topology

At the other extreme of thrift, give every node exactly two links. In a ring topology, each node is connected to two other devices, one on either side, as shown in Fig. 10.19. The nodes connected with each other thus form a ring.

Fig. 10.19

Fig. 10.19 – Ring topology.

NoteDefinition

In a ring topology, each node is connected to exactly two other devices, one on either side, so that the nodes together form a closed loop.

The link in a ring topology is unidirectional. Data can therefore be transmitted in one direction only — clockwise or counterclockwise, but not both. A message from a node to its neighbour on the wrong side does not take one step backwards; it travels the whole way round.

This is economical, and it has a clear weakness that follows from the definition rather than from any particular equipment. Every node lies on the only path its neighbours have.

10.5.3 Bus Topology

A bus topology replaces the loop with a single line. Each communicating device connects to a transmission medium known as the bus, as shown in Fig. 10.20. Data sent from a node are passed on to the bus, and hence are transmitted along the length of the bus in both directions. That means the data can be received by any of the nodes connected to the bus.

Fig. 10.20

Fig. 10.20 – Bus topology.

NoteDefinition

In a bus topology, every node connects to a single shared transmission medium called the bus, along which transmitted data travels in both directions.

In this topology, a single backbone wire called the bus is shared among the nodes, which makes the network cheaper and easier to maintain. There is one length of cable to lay and one length to inspect, and adding a node means dropping one more short cable onto the line.

Both ring and bus topologies are considered to be less secure and less reliable. Less secure, because every node on the bus can receive data that was placed on it, whichever node it was meant for. Less reliable, because both arrangements share a single path: a break in the bus, or a break in the ring, cuts the network rather than one machine.

Q. In a bus network, a node is switched off. In a ring network, a node is switched off. Does the rest of the network keep working in either case?

A. In the bus, yes — the other nodes are attached to the shared line by their own drop cables and continue to use it, since a switched-off node is simply not sending or receiving. In the ring, no — every node is a link in the only path there is, and its two neighbours can no longer pass data through it, so the loop is broken. The difference is that a bus node hangs off the path while a ring node is part of it.

10.5.4 Star Topology

In a star topology, each communicating device is connected to a central node, which is a networking device like a hub or a switch, as shown in Fig. 10.21. No two end devices are joined directly to each other; everything passes through the middle.

Fig. 10.21

Fig. 10.21 – Star topology.

NoteDefinition

In a star topology, every communicating device is connected by its own separate link to a central node, which is a networking device such as a hub or a switch.

Star topology is considered very effective, efficient and fast, as each device is directly connected with the central device. A fault in one cable affects one machine, because no other machine’s traffic uses that cable. Although disturbance in one device will not affect the rest of the network, any failure in the central networking device may lead to the failure of the complete network.

That pair of sentences is the honest summary of the star. It converts many possible points of failure into one — which is a real improvement for the ordinary faults, a cut cable or a failed machine, and a real risk for the one fault it cannot absorb.

What the network does with a message depends on what sits in the middle, and you already know both possibilities from section 10.4. The central node can be either a broadcasting device, meaning data will be transmitted to all the nodes in the network, or a unicast device, meaning the node can identify the destination and forward data to that node only.

Q5. One broken cable can bring an entire network down, while in another arrangement the same break costs you only one computer. What makes the difference?

A. Whether the broken cable was shared or private. In a bus topology every node depends on one backbone wire, and in a ring topology every node lies on the single loop, so a break in that shared path cuts the network in two and traffic stops. In a star topology each node has its own separate cable to the central device, so a break on one cable isolates exactly one machine and the rest carry on. The star pays for this by concentrating the risk in one place instead: if the central hub or switch itself fails, the whole network fails with it.

10.5.5 Tree or Hybrid Topology

Real networks of any size are rarely one pattern throughout. A tree topology, also called a hybrid topology, is a hierarchical topology in which there are multiple branches, and each branch can have one or more of the basic topologies like star, ring and bus.

NoteDefinition

A tree or hybrid topology is a hierarchical arrangement of multiple branches, in which each branch may itself be built as a star, ring or bus topology.

Such topologies are usually realised in WANs where multiple LANs are connected, and those LANs may be in the form of a ring, a bus or a star. Fig. 10.22 shows four star topologies connected along a bus.

Fig. 10.22

Fig. 10.22 – Tree or hybrid topology.

In this type of network, data transmitted from a source first reaches the centralised device of its own branch, and from there the data passes through the branches, each of which can have links for further nodes. Reading the figure from the bottom up shows why the arrangement is called hierarchical: a node belongs to a star, the star belongs to the bus, and the bus may itself be one branch of something larger.

This is also how the categories of section 10.3 fit together physically. A campus builds each laboratory as a star, joins the stars along a backbone, and connects that backbone onward — and the result is a tree, whether or not anyone planned it as one.

Choosing Between Them

Table 10.5 puts the five arrangements side by side. Read the row for a single link failure alongside the row for cabling cost, and the trade-off that governs the whole section becomes visible: the arrangements that survive faults best are the ones that cost the most to build.

Table 10.5 – the five network topologies compared | Feature | Mesh | Ring | Bus | Star | Tree | |—|—|—|—|—|—| | How nodes are joined | Every node to every other node | Each node to two neighbours, forming a loop | All nodes to one shared backbone | Each node to a central device | Branches, each built as a basic topology | | Cabling needed for \(n\) nodes | \(n(n-1)/2\) links | \(n\) links | One backbone plus one drop per node | One link per node, plus the central device | Depends on the branches used | | Effect of one link failing | Other pairs unaffected | Breaks the loop | Cuts the shared path | Isolates one node only | Affects that branch | | Single point of total failure | None | The loop itself | The backbone | The central device | The device joining the branches | | Direction of data flow | Direct between the two nodes | One direction only | Both ways along the bus | Through the central device | Down through the hierarchy | | Typical use | Links that must not fail | Small closed networks | Small, low-cost networks | Ordinary LANs | Large networks built from many LANs |

A small library has one counter machine, four catalogue machines for readers and a shared printer, all in one hall. Sketch the network twice — once as a bus and once as a star — labelling every cable and every device. Then, for each sketch, mark the one cable whose failure would cost the library the most, and say what would still work.

10.6 Identifying Nodes in a Networked Communication

Section 10.4 said that a switch extracts the destination address from a packet and looks it up in a table, and that a gateway routes a packet to its destination by the best available path. Both statements quietly assumed something large: that every node has an address, that no two nodes share it, and that a device examining a packet can tell from the address alone where the packet should go.

Each node in a network should therefore be uniquely identified, so that a network device can identify the sender and the receiver and decide a routing path along which to transmit the data. Two different addressing schemes are used for this, and a single computer carries both at once.

10.6.1 MAC Address

The first address belongs to the hardware. MAC stands for media access control. The MAC address, also known as the physical address or hardware address, is a unique value associated with a network adapter called a NIC — the Ethernet card you met in section 10.4.

The MAC address is engraved on the NIC at the time of manufacturing. It is therefore a permanent address: it is fixed when the card is made and stays with that card wherever the machine is carried. The machine on which the NIC is attached can be physically identified on the network using its MAC address.

NoteDefinition

A MAC address is a unique, permanent hardware address assigned to a network interface card at the time of manufacture, used to identify that card physically on a network.

How a MAC Address Is Built

Each MAC address is a 12-digit hexadecimal number, \(48\) bits in length. Recall from Class XI that hexadecimal is base 16, so each hexadecimal digit stands for exactly \(4\) bits, and \(12 \times 4 = 48\).

The 12 digits divide into two halves, as Fig. 10.23 shows. The first six digits, that is \(24\) bits, contain the manufacturer’s identification, called the organisational unique identifier (OUI). The later six digits, another \(24\) bits, represent the serial number assigned to the card by that manufacturer.

Fig. 10.23

Fig. 10.23 – Structure of a MAC address.

The split is what makes the scheme work without any central office issuing every address one by one. Each manufacturer is given its own OUI and then numbers its own cards within it, and no two manufacturers can collide because their first halves differ. With \(48\) bits available, the scheme allows \(2^{48}\), or roughly \(2.8 \times 10^{14}\), distinct addresses — enough that a card need never reuse one.

Q. If a MAC address identifies a machine, why is it called the hardware address and not the computer address?

A. Because it belongs to the network interface card, not to the computer as a whole. A machine with both an Ethernet card and a Wi-Fi adapter has two MAC addresses, one for each. Replace the card and the address changes with it, while the computer stays the same.

10.6.2 IP Address

The second address belongs to the network. An IP address, also known as an internet protocol address, is a unique address that can be used to identify each node in a network. IP addresses are assigned to each node in a network that uses the Internet Protocol for communication.

NoteDefinition

An IP address is a unique address assigned to a node in a network that uses the Internet Protocol, by which that node is identified for communication.

If we know a computer’s IP address, we can communicate with that computer from anywhere in the world. But unlike a MAC address, an IP address can change: if a node is removed from one network and connected to another network, it is given a different IP address.

That single difference is the heart of this section, and Fig. 10.24 makes it visible. The same laptop, carried from a school laboratory to a home, keeps the address engraved on its card and is given a new address by each network it joins.

Fig. 10.24

Fig. 10.24 – MAC and IP addresses when moving networks.

Both addresses are needed, and neither replaces the other. A MAC address says which piece of hardware this is, and it never tells you where that hardware currently sits. An IP address says where on the network this node currently is, which is exactly what a router or gateway needs in order to choose a path — and it is precisely because it describes a position rather than an object that it must change when the position changes.

Table 10.6 – MAC address and IP address compared | Feature | MAC address | IP address | |—|—|—| | Also called | Physical or hardware address | Internet Protocol address | | Assigned by | The manufacturer, at the time of making the card | The network the node is connected to | | Permanence | Permanent; fixed on the NIC at manufacture | Can change when the node joins a different network | | What it identifies | A particular network interface card | A node’s position on a network | | Length | 48 bits, written as 12 hexadecimal digits | 32 bits in IPv4; 128 bits in IPv6 | | Used for | Identifying a machine physically on the network | Identifying sender and receiver and deciding a routing path |

Q2. Every network card carries a permanent address fixed at the factory. So why does the same computer also need a second address that keeps changing?

A. Because the two addresses answer different questions. The MAC address on the card says which piece of hardware this is, and it stays the same for the life of the card — which also means it says nothing about where that card is at the moment. To deliver a packet, a device must know where the destination currently sits so that it can choose a route towards it, and that is what the IP address records. When the machine is moved from one network to another its position genuinely has changed, so the address describing that position has to change with it, while the address describing the hardware does not.

IPv4 and IPv6

The initial IP address scheme, called version 4 or IPv4 in short, is a \(32\)-bit numeric address. It is written as four numbers separated by periods, where each number is the decimal representation of an \(8\)-bit binary number and can therefore take any value from \(0\) to \(255\). A sample IPv4 address looks like:

192.0.2.178

Fig. 10.25 shows how the written form relates to the bits underneath.

Fig. 10.25

Fig. 10.25 – Structure of an IPv4 address.

With more and more devices getting connected, it was realised that a \(32\)-bit address would not be sufficient, as it offers just under \(4.3\) billion unique addresses. The arithmetic is worth doing once: \(2^{32} = 4{,}294{,}967{,}296\), and the world now holds far more connectable devices than that.

Thus a \(128\)-bit IP address, called IP version 6 or IPv6 in short, was proposed. An IPv6 address is represented by eight groups of hexadecimal numbers separated by colons. A sample IPv6 address looks like:

2001:0DB8:0000:0000:0000:0000:3257:9652

Eight groups of four hexadecimal digits is \(8 \times 4 \times 4 = 128\) bits, giving about \(3.4 \times 10^{38}\) addresses — a supply that will not run out in any circumstance worth planning for.

Table 10.7 – IPv4 and IPv6 compared | Feature | IPv4 | IPv6 | |—|—|—| | Length of the address | 32 bits | 128 bits | | Written as | Four numbers separated by periods | Eight groups of hexadecimal numbers separated by colons | | Number system used in writing | Decimal | Hexadecimal | | Range of each written group | 0 to 255 | Four hexadecimal digits | | Number of addresses available | Just under 4.3 billion | About \(3.4 \times 10^{38}\) |

Q. Why was the answer to running out of addresses to move to 128 bits, rather than to 64?

A. Because changing an addressing scheme is enormously disruptive, and nobody wanted to do it twice. Every additional bit doubles the supply, so 64 bits would already have been an unimaginable increase — but the designers chose a size that leaves room for structure inside the address as well as for sheer quantity, so that the space can be divided among networks generously rather than counted out device by device.

Write down the four numbers of the IPv4 address 192.0.2.178 and convert each to its 8-bit binary form on paper. Check that you have written exactly 32 binary digits in all. Then explain, in two lines, why no group in a valid IPv4 address can ever read 300.

10.7 Internet, Web and the Internet of Things

Section 10.2 defined the Internet as the global network formed by interconnecting networks of computing devices worldwide, all communicating through a common protocol suite. This section looks at what is actually connected to it, how the connection is arranged, and what sits on top of it — because the thing most people call “the Internet” in everyday speech is not the Internet at all.

What Is Connected

The Internet is the global network of computing devices, and the word computing is doing more work every year. It includes desktops, laptops, servers, tablets, mobile phones and other handheld devices, and also printers, scanners, routers, switches and gateways.

Beyond these, smart electronic appliances such as televisions, air conditioners, refrigerators, fans and lights can also communicate through a network, and the list of such smart devices is always increasing — drones, vehicles, door locks, security cameras. You met this idea in Class XI as the internet of things (IoT): everyday objects given the ability to sense, communicate and be controlled over a network, so that they can act on information rather than wait for a person to act on it.

The point to carry forward from that earlier study is that nothing in this chapter has to change to accommodate them. A refrigerator on a network is a node exactly as section 10.1 defined a node. It has a network interface, it is given an address, it sends and receives packets, and a switch treats its traffic no differently from a laptop’s.

How the Connection Is Arranged

The Internet is evolving every day, and it is difficult to visualise or describe every aspect of its architecture. The general shape, however, is a hierarchy, and Fig. 10.26 shows it.

Computers are connected to a modem, either through a cable or wirelessly using Wi-Fi. That modem, wired or wireless, is connected to a local internet service provider, which in turn connects to a national network. Many such ISPs connect together forming a regional network; regional networks connect together forming a national network; and such country-wise networks form the Internet backbone.

Fig. 10.26

Fig. 10.26 – The hierarchy of Internet connectivity.

Read the figure from the bottom upward and you are watching section 10.3 in action. A home network joins a larger network, which joins a larger one still, and at no level does anyone build a single enormous network — they build a network of networks, each level owned and run by different people.

The influence of all this is no longer limited to the technical field of computer communications. It is used by everyone in society, as is evident from the increasing use of online tools for education, creativity, entertainment, socialisation and e-commerce.

10.7.1 The World Wide Web (WWW)

The world wide web (WWW), or web in short, is an ocean of information stored in the form of trillions of interlinked web pages and web resources. The resources on the web can be shared or accessed through the Internet.

NoteDefinition

The World Wide Web is the collection of interlinked web pages and web resources that are stored on computers across the world and can be accessed through the Internet.

To see what problem it solved, picture the situation before it. To access files residing in different computers, one had to log in individually to each computer through the Internet. Besides, files in different computers were sometimes in different formats, and it was difficult to understand each other’s files and documents. The connection existed; the convenience did not. You could reach a machine, and then you had to negotiate with it separately about who you were and what its files meant.

Sir Tim Berners-Lee, a British computer scientist, invented the World Wide Web in 1990 by defining three fundamental technologies that led to the creation of the web. Each one removes a specific part of that difficulty.

HTML

HTML — hypertext markup language — is a language which is used to design standardised web pages, so that the web contents can be read and understood from any computer. The basic structure of every webpage is designed using HTML.

This is the answer to the problem of formats. If every page is described in the same agreed language, then any program that understands that language can display any page, and the question of whether your machine understands my documents disappears.

URI

URI — uniform resource identifier — is a unique address or path for each resource located on the web. It is also known as URL, uniform resource locator, and every page on the web has a unique URL. A URL is sometimes also called a web address.

A URL is not only the domain name; it contains other information that completes a web address, as Fig. 10.27 shows. The domain name identifies the server that holds the resource — it is the name given to a server in place of the numeric address you met in section 10.6 — and the rest of the URL identifies which resource on that server is wanted.

Fig. 10.27

Fig. 10.27 – Anatomy of a URL.

HTTP

HTTP — hypertext transfer protocol — is a set of rules which is used to retrieve linked web pages across the web. Its more secure and advanced version is HTTPS, in which the data exchanged between the browser and the server is encrypted so that anyone able to observe the traffic in between cannot read it.

This is a protocol in exactly the sense defined in section 10.2. It settles how a browser asks for a page and how a server answers, so that a browser written by one group and a server written by another can work together without ever having been introduced.

The three technologies of the web Statement: The web rests on HTML for describing pages, URI or URL for naming resources uniquely, and HTTP for retrieving them. In words: One agreed language to write a page in, one agreed way to name it, and one agreed way to ask for it. Why it holds: Each removes a separate obstacle — differing formats, the absence of a universal name, and the absence of an agreed request procedure. Remove any one and the other two are not enough. Used for: Publishing a page once and having it readable and reachable from any computer in the world. Watch out: These three describe the web, not the Internet. They assume a working network underneath and add nothing to it.

10.7.2 The Web and the Internet Compared

Many people confuse the web with the Internet, and the confusion is worth clearing carefully, because the two words are not two names for one thing.

The Internet, as you know from section 10.2, is the huge global network of interconnected computers — computers which may or may not have any file or webpage to share with the world. The web, on the other hand, is the interlinking of a collection of web pages on these computers, which are accessible over the Internet. Fig. 10.28 shows the relationship.

Fig. 10.28

Fig. 10.28 – The World Wide Web on the Internet.

The test is simple. A machine on a network that shares no pages at all — a database server inside a bank, a networked printer in an office — is on the Internet and is not part of the web. Every page you read, on the other hand, needed the Internet to reach you.

Table 10.8 – the Internet and the World Wide Web compared | Feature | Internet | World Wide Web | |—|—|—| | What it is | A global network of interconnected computers and networks | A collection of interlinked web pages and resources | | What it is made of | Computers, networking devices and the links between them | Pages, resources and the links among them | | Depends on the other | No | Yes — it is accessed through the Internet | | Rests on | A common protocol suite for carrying data | HTML, URL and HTTP | | Came into existence | Grew from ARPANET through the 1970s and 1980s | Invented in 1990 | | A device that shares no pages | Still part of it | Not part of it |

The web today gives users access to a vast collection of information created and shared by people across the world, and it is the most popular information retrieval system in use.

Q. You send a message through a chat application on your phone. Did it travel over the Internet, over the web, or both?

A. Over the Internet only. The message was carried as packets between networks, which is the Internet’s job, but no web page was involved — the application did not fetch an HTML document by URL over HTTP. The web is one of the many things the Internet carries, not the carrier itself.

Write down a URL of your own invention for an imaginary school library page, then mark on it which part names the protocol, which part names the server and which part names the resource. Now write a second URL for a different page on the same server, and say which part of the two is identical and why it must be.

10.8 Domain Name System

The Internet holds information in the form of millions of websites. Each website is stored on a server which is connected to the Internet, which means, by section 10.6, that each such server has an IP address. Every device connected to the Internet has one.

That is the whole difficulty in a sentence. Delivery works on numbers. A router choosing a path, a gateway routing a packet outward, a switch looking up a destination — none of them can act on anything but an address of the kind you met in section 10.6. But a person cannot be expected to remember that a school’s library server is at 192.0.2.41, and to remember a different string of numbers for every site they ever visit.

Names are easy for people and useless to routers. Numbers are the reverse. Rather than force either side to give way, the network keeps both and puts a translation service between them.

10.8.1 Domain Names

Because it is easier to remember names, each computer server hosting a website or a web resource is given a name against its IP address. These names are called domain names, or hostnames, corresponding to the unique IP addresses assigned to each server.

NoteDefinition

A domain name, or hostname, is the name given to a server in place of its IP address, and it corresponds to that server’s unique IP address.

You have already seen a domain name in section 10.7, as the part of a URL that says which server is wanted. What section 10.7 did not say is that the server itself never uses it. The name exists for the human being typing it.

Table 10.9 shows a few examples of the mapping.

Table 10.9 – examples of domain names and the IP addresses they map to; the left column holds the name a person types and the right column holds the address the network uses | Domain name | IP address | |—|—| | example.com | 192.0.2.14 | | library.example.org | 192.0.2.41 | | depot.example.net | 198.51.100.6 | | results.example.in | 203.0.113.22 |

The arrangement is the same one you use every day without noticing. The contacts list on a phone lets you tap a name; the telephone network still places the call using the number stored behind it. Nobody argues that the number should be abolished, and nobody proposes memorising it either.

Q1. A website can be reached by a name, but the network underneath works with numbers. Why keep both, instead of just one?

A. Because the two are good at different things and neither can do the other’s job. Names are easy for people to remember, recognise and pass on, but they carry no information about where a server sits, so a router could not choose a path from a name. IP addresses are exactly what routers and gateways need, but a person cannot hold a distinct string of numbers for every site they visit — and the address of a server may be changed by its owner, while its name can stay the same. Keeping both, and translating between them at the moment of use, gives each side the form it works best with.

10.8.2 DNS Server and Domain Name Resolution

Assigning a name solves half the problem. The other half is that a browser handed a name still needs a number before it can ask anyone for anything.

The conversion of the domain name of each web server into its corresponding IP address is called domain name resolution. It is done through a server called a DNS server.

NoteDefinition

Domain name resolution is the conversion of a domain name into the corresponding IP address, and a DNS server is the server that performs this conversion.

Thus, when we enter a URL in a web browser, the HTTP protocol approaches a computer server called a DNS server to obtain the IP address corresponding to that domain name. After getting the IP address, HTTP retrieves the information and loads it in our browser. Fig. 10.29 shows the exchange.

Fig. 10.29

Fig. 10.29 – Domain name resolution and page request.

Read the figure carefully, because the order matters. Two separate conversations take place, with two different machines. The DNS server is asked a question about a name and answers with a number; it holds no web pages and knows nothing about the site’s contents. Only after that answer arrives can the browser approach the actual web server.

Q. A site’s page loads correctly one day, and the next day the browser reports that the name could not be found, although the site is running normally. Which of the two conversations in Fig. 10.29 has failed?

A. The first one. The browser never got as far as the web server, because it never obtained an address to contact. A failure in name resolution looks to the user exactly like a site being down, even though the site itself is untouched — which is why the two steps are worth keeping distinct in your mind.

Where the Answers Are Kept

A DNS server maintains a database of domain names and their corresponding IP addresses. But no single machine could hold every name on the Internet, keep it current, and answer the world’s questions about it. So the DNS servers are placed in hierarchical order, as Fig. 10.30 shows.

At the top level there are 13 root servers. Below the root servers there are other DNS servers at different levels. A DNS server may contain the IP address corresponding to a domain, or it will contain the IP address of other DNS servers where that domain entry can be searched.

Fig. 10.30

Fig. 10.30 – Hierarchy of DNS servers.

That last sentence of the description is the design in miniature. A server that does not know an answer is not a dead end, because it knows which server to ask. No machine has to hold everything, and no query has to visit more than a few servers.

The domain name system Statement: Domain names are mapped to IP addresses by a hierarchy of DNS servers, each responsible for part of the naming space, and a name is resolved by querying servers along that hierarchy. In words: Nobody keeps the whole list; each server keeps a part of it and knows where the rest of the answers live. Why it holds: Because a query need only find one server that holds the entry, and any server that does not hold it can point towards one that does, the work of answering and the work of keeping records current are both spread across many independent operators. Used for: Letting people and programs use stable, memorable names while routers continue to work only with IP addresses. Watch out: Resolution is a separate step that happens before any page is fetched. If it fails, nothing that follows can begin, even though the destination server may be perfectly healthy.

The 13 root servers are identified by the letters A to M and are run by different organisations, and the Internet Assigned Numbers Authority (IANA) keeps the authoritative list of them. There are far more than 13 physical machines involved: each of the 13 addresses is served by many installations in many countries, so that a query is answered by a nearby copy and no single failure removes a root from the network.

Using Table 10.9, write down in order the steps a browser would take, from the moment a student types library.example.org to the moment the page appears. Mark clearly which step involves the DNS server and which step involves the web server, and state what the browser has after each step that it did not have before.

10.9 Summary

Networks and Nodes
  1. A network is a group of two or more similar things, people or devices interconnected with one another. A computer network is an interconnection among two or more computers or computing devices that allows them to share data and resources with each other.

  2. A node is any device that is part of a network and that can receive, create, store or send data to different network routes. A node need not be a computer: a modem, a hub, a bridge, a switch, a router, a digital telephone handset, a printer, a computer and a server are all nodes.

  3. For communication, data in a network is divided into smaller chunks called packets, which are then carried over the network. Devices may be connected through wired media such as cables, or wireless media such as air.

  4. A network exists for two reasons: to exchange information with many parties at once, and to share resources such as a printer or networked storage, so that one resource serves many machines.

How Networking Grew
  1. A research project commissioned in the 1960s by the Advanced Research Projects Agency in the U.S. Department of Defense produced ARPANET, built to connect academic and research institutions for scientific collaboration. Its first message passed between the University of California, Los Angeles and the Stanford Research Institute.

  2. As more organisations joined and independent smaller networks formed, the problem became joining networks that were never designed for each other. The answer was a protocol — an agreed set of rules governing how data is formatted, addressed, transmitted and received.

  3. TCP/IP was adopted as the standard protocol on ARPANET, and the network of networks that resulted is the Internet. The milestones of this growth run from the conception of ARPANET in 1961 through e-mail in 1971, the coining of the term Internet in 1974, TCP/IP in 1982, the Domain Name System in 1983, NSFNET in 1986, the birth of the web in 1990, and the first Wi-Fi standard in 1997.

Types of Networks
  1. Based on the geographical area covered and the data transfer rate, computer networks are broadly categorised as PAN (personal area network), LAN (local area network), MAN (metropolitan area network) and WAN (wide area network).

  2. A PAN connects a few personal devices lying within an approximate range of 10 metres, and may be wired or wireless. A LAN connects nodes at a limited distance — a room, a floor, a laboratory or a campus — extends up to about 1 km, and carries data at 10 Mbps to 1000 Mbps. A MAN is an extended form of LAN covering a city or town, reaching 30–40 km at rates lower than a LAN. A WAN spans a country, or several countries and continents; the Internet is the largest WAN.

  3. Across these four types, reach and speed pull against each other: the further a network extends, the lower its data transfer rate. Data transfer rate is measured in bits per second, not bytes per second.

  4. Ethernet is a set of rules that decides how computers and other devices connect with each other through cables in a local area network.

Network Devices
  1. A modem converts digital data into analog signals for transmission and converts received analog signals back into digital data; modulation happens at the sender and demodulation at the receiver.

  2. An Ethernet card, or network interface card, is the adapter that acts as the interface between a computer and the network, and it carries a permanent hardware address fixed at manufacture. RJ45 is the eight-pin connector used exclusively with Ethernet cables.

  3. A repeater is an analog device that regenerates a weakened signal and puts it back on the cable; it works on the signal, not on the message, and makes no decisions about the data.

  4. A hub sends data arriving on any line out on all the other lines, so simultaneous transmissions collide. A switch extracts the destination address from the packet, looks it up in a table and forwards the packet only to the port where its destination lies; it can forward several packets at once and drops noisy or corrupted signals.

  5. A router receives data, analyses it and transmits it to other networks, repackaging it where the next network cannot carry packets of the size it arrived in. A gateway is the entry and exit point of a network, through which all data entering or leaving must pass, and it keeps information about the host network’s internal paths and the identified paths of remote networks. Because it stands at the edge, the firewall is usually integrated with it.

Topologies
  1. The arrangement of computers and other peripherals in a network is called its topology. Common network topologies are mesh, ring, bus, star and tree.

  2. In a mesh topology every device is connected to every other device, which gives high capacity, reliability and security at the cost of complex wiring — a fully connected mesh of \(n\) nodes needs \(n(n-1)/2\) wires, many of them unused.

  3. In a ring topology each node is connected to two neighbours, forming a loop in which data travels in one direction only. In a bus topology all nodes share a single backbone wire along which data travels in both directions, which makes it cheap and easy to maintain. Both are considered less secure and less reliable.

  4. In a star topology each device has its own link to a central node, which is a networking device such as a hub or a switch. A fault in one link affects one machine, but a failure of the central device can bring down the whole network. The central node may be a broadcasting device or a unicast device.

  5. A tree or hybrid topology is hierarchical, with multiple branches, each of which may itself be a star, ring or bus. It is the arrangement usually found in WANs where many LANs are connected.

Identifying Nodes
  1. Every node must be uniquely identified so that devices can recognise the sender and the receiver and decide a routing path.

  2. A MAC address is the physical or hardware address engraved on a network interface card at manufacture. It is 48 bits long, written as 12 hexadecimal digits, of which the first six digits are the organisational unique identifier naming the manufacturer and the last six are the card’s serial number.

  3. An IP address identifies a node on a network using the Internet Protocol. Unlike a MAC address it can change when a node is moved to another network, because it records a position rather than a piece of hardware.

  4. IPv4 is a 32-bit address written as four decimal numbers separated by periods, each between 0 and 255, offering just under 4.3 billion addresses. IPv6 is a 128-bit address written as eight groups of hexadecimal numbers separated by colons.

The Internet, the Web and Names
  1. Computers connect to a modem, the modem to a local internet service provider, ISPs join into regional networks, regional networks into national networks, and country-wise networks form the Internet backbone. Smart appliances joining this network are the internet of things.

  2. The World Wide Web is the collection of interlinked web pages and web resources stored on computers across the world and accessed through the Internet. Sir Tim Berners-Lee invented it in 1990 by defining three technologies: HTML for writing standardised pages, URI or URL for naming each resource uniquely, and HTTP for retrieving linked pages, whose more secure version is HTTPS.

  3. The Internet and the web are not the same. The Internet is the network of interconnected computers, which may or may not share any page; the web is the interlinking of pages held on those computers. The web depends on the Internet, and not the other way round.

  4. Each server hosting a website is given a domain name, or hostname, against its IP address, because names are easier for people to remember while routers work only with numbers.

  5. The conversion of a domain name into its corresponding IP address is called domain name resolution, and it is carried out by a DNS server. A browser resolves the name first and only then requests the page from the web server.

  6. DNS servers are arranged in hierarchical order, with 13 root servers at the top level and further DNS servers below them. A DNS server either holds the IP address for a domain, or holds the address of another DNS server where that entry can be searched.

10.10 Key Terms

  1. Analog signal: a signal that varies smoothly and continuously, of the kind carried by media such as a telephone line.

  2. ARPANET — advanced research projects agency network: the network built in the 1960s to connect academic and research institutions, from which the Internet grew.

  3. Bus topology: an arrangement in which every node connects to a single shared transmission medium, along which data travels in both directions.

  4. Computer network: an interconnection among two or more computers or computing devices that lets them share data and resources.

  5. Data transfer rate: the quantity of data a network can carry in one second, measured in bits per second.

  6. Demodulator: the role played by the modem at the receiving end, converting analog signals back into digital data.

  7. Digital signal: a signal that takes distinct, separate values, of the kind a computer uses to store and process data.

  8. DNS — domain name system: the hierarchical system of servers that maps domain names to IP addresses.

  9. DNS server: a server that holds a database of domain names and their IP addresses and performs domain name resolution.

  10. Domain name: the name given to a server in place of its IP address, corresponding to that server’s unique address.

  11. Domain name resolution: the conversion of a domain name into the IP address that corresponds to it.

  12. Ethernet: the set of rules that decides how computers and other devices connect to one another through cables in a LAN.

  13. Ethernet card: the network adapter that acts as the interface between a computer and the network; also called a network interface card.

  14. Firewall: the arrangement that inspects traffic entering or leaving a network and blocks what is not permitted; usually integrated with the gateway.

  15. Gateway: the entry and exit point of a network, through which all data entering or leaving that network must pass.

  16. Gigabit Ethernet: Ethernet operating at 1000 Mbps.

  17. Host: a device that is part of a network; also called a node.

  18. Hostname: another name for a domain name — the name assigned to a server against its IP address.

  19. Hotspot: a connection offered by one device, usually a phone, through which nearby devices join to form a small personal network.

  20. HTML — hypertext markup language: the language used to design standardised web pages so that their contents can be read from any computer.

  21. HTTP — hypertext transfer protocol: the set of rules used to retrieve linked web pages across the web.

  22. HTTPS: the more secure and advanced version of HTTP, in which data exchanged between browser and server is encrypted.

  23. Hub: a network device that sends data arriving on any one of its lines out on all the other lines.

  24. Internet: the global network formed by interconnecting networks of computing devices worldwide, all using a common protocol suite.

  25. Internet backbone: the country-wise networks, joined together, that carry traffic between regions of the Internet.

  26. IoT — internet of things: the extension of network connectivity to ordinary physical objects so that they can send and receive data.

  27. IP address — internet protocol address: the unique address assigned to a node on a network that uses the Internet Protocol.

  28. IPv4: the 32-bit IP address scheme, written as four decimal numbers separated by periods, each from 0 to 255.

  29. IPv6: the 128-bit IP address scheme, written as eight groups of hexadecimal numbers separated by colons.

  30. ISP — internet service provider: any organisation that provides services for accessing the Internet.

  31. LAN — local area network: a network connecting nodes placed at a limited distance, such as within a room, a building or a campus.

  32. MAC address — media access control address: the permanent hardware address engraved on a network interface card at the time of manufacture.

  33. MAN — metropolitan area network: an extended form of LAN covering a larger area such as a city or a town.

  34. Mesh topology: an arrangement in which every communicating device is connected directly to every other device.

  35. Modem: a device that converts digital data into analog signals for transmission and converts received analog signals back into digital data.

  36. Modulator: the role played by the modem at the sending end, converting digital data into analog signals.

  37. Network: a group of two or more similar things, people or devices interconnected so that something can pass between them.

  38. Networking device: a device such as a modem, hub, switch, router or gateway, whose purpose is to connect other devices into a network.

  39. NIC — network interface card: another name for the Ethernet card, the adapter through which a computer joins a wired network.

  40. Node: any device that is part of a network and can receive, create, store or send data to different network routes.

  41. OUI — organisational unique identifier: the first 24 bits of a MAC address, identifying the manufacturer of the card.

  42. Packet: a small chunk into which data is divided before being carried across a network.

  43. PAN — personal area network: a network formed by connecting a few personal devices lying within about 10 metres of one another.

  44. Protocol: an agreed set of rules governing how data is formatted, addressed, transmitted and received between devices.

  45. Repeater: an analog device that regenerates a weakened signal on a cable and puts the restored signal back on it.

  46. Resource sharing: the use of one resource, such as a printer or a storage device, by many computers over a network.

  47. Ring topology: an arrangement in which each node is connected to two neighbours, forming a closed loop in which data travels one way.

  48. RJ45: the eight-pin connector used exclusively with Ethernet cables for networking.

  49. Root server: one of the 13 DNS servers at the top level of the DNS hierarchy.

  50. Router: a network device that receives data, analyses it and transmits it onward to other networks.

  51. Server: a host on a network that provides data, resources or services to other nodes.

  52. Star topology: an arrangement in which every device has its own link to a central networking device such as a hub or a switch.

  53. Switch: a networking device that forwards each incoming packet only to the port on which its destination lies.

  54. TCP/IP — transmission control protocol / internet protocol: the protocol suite adopted as the standard for ARPANET and used across the Internet.

  55. Topology: the arrangement in which the computers and other peripherals of a network are connected to one another.

  56. Tree or hybrid topology: a hierarchical arrangement of multiple branches, each of which may itself be a star, ring or bus topology.

  57. URI — uniform resource identifier: the unique address or path of a resource located on the web; also known as a URL.

  58. URL — uniform resource locator: the complete web address of a resource, naming the protocol, the server and the path to the resource.

  59. WAN — wide area network: a network connecting computers, LANs and MANs spread across a country, or across countries and continents.

  60. Web page: a document written in HTML that forms part of the World Wide Web.

  61. Wired media: cables and other physical media through which network signals are carried.

  62. Wireless media: air and other free space through which network signals are carried without cables.

  63. WPAN: a personal area network whose devices are connected wirelessly.

  64. WWW — world wide web: the collection of interlinked web pages and web resources stored on computers worldwide and accessed through the Internet.

10.11 Points to Ponder

  1. A mesh topology is the most reliable and the most secure arrangement in this chapter, and it is almost never used for an ordinary network. What would have to be true of a network — its size, its purpose, the cost of an hour of failure — before the wiring of a mesh became worth paying for?

  2. A switch does everything a hub does and does it better. Why, then, did hubs ever exist? What capability does a switch need in order to forward a packet to one port instead of all of them, and why was that capability once more expensive than sending copies everywhere?

  3. Suppose the design had been reversed: the address burnt into the card could change, while the address given by the network was permanent for the life of the machine. Which parts of a network would stop working, and which parts would not notice?

  4. Resolving a domain name adds a step before any page can be fetched, and a failure at that step makes a perfectly healthy server unreachable. What is gained in exchange for that extra step and that extra point of failure — and would the answer change if servers never moved and never changed their addresses?

  5. The exhaustion of IPv4 addresses was foreseen long before it became urgent, and IPv6 has still taken decades to spread. What is it about an addressing standard, as against a piece of equipment, that makes it so hard to replace even when everyone agrees on the replacement?

  6. The web depends on the Internet, and the Internet does not depend on the web. Does the same one-way dependence hold for e-mail, and for a chat application? Judging from your answer, what exactly is it that the Internet supplies to everything built on top of it?

10.12 Objective Questions

  1. Which of the following is measured in bits per second?

    1. The number of nodes in a network
    2. The data transfer rate of a network
    3. The length of a MAC address
    4. The range of a personal area network [1 mark]
  2. A device that regenerates a weakened signal on a cable and puts it back on the same cable is a:

    1. switch
    2. gateway
    3. repeater
    4. router [1 mark]
  3. In which topology does a single break in the shared backbone wire cut the network into two parts?

    1. Star
    2. Mesh
    3. Bus
    4. Tree [1 mark]
  4. How many bits are there in an IPv6 address?

    1. 32
    2. 48
    3. 64
    4. 128 [1 mark]
  5. A fully connected mesh topology of 6 nodes requires how many wires?

    1. 6
    2. 12
    3. 15
    4. 30 [1 mark]
  6. Fill in the blank: The conversion of a domain name into its corresponding IP address is called __________. [1 mark]

  7. State whether the following statement is true or false: A computer that is connected to the Internet but hosts no web page is not part of the Internet. [1 mark]

  8. Write the full form of each of the following: (i) ARPANET (ii) NIC (iii) OUI (iv) HTTPS. [1 mark]

  9. Match each device in Column A with what it does in Column B.

Column A Column B
a. Modem i. Forwards a packet only to the port where its destination lies
b. Hub ii. Acts as the single entry and exit point of a network
c. Switch iii. Converts between digital data and analog signals
d. Gateway iv. Sends data arriving on one line out on all the other lines

[1 mark]

  1. Assertion (A): A MAC address does not change when a laptop is carried from a school network to a home network. Reason (R): A MAC address records the position of a node on the network it has joined.
    1. Both A and R are true and R is the correct explanation of A.
    2. Both A and R are true but R is not the correct explanation of A.
    3. A is true but R is false.
    4. A is false but R is true. [1 mark]
  2. Assertion (A): In a star topology, a fault in one cable does not stop the other nodes from communicating. Reason (R): In a star topology every node has its own separate link to the central networking device.
    1. Both A and R are true and R is the correct explanation of A.
    2. Both A and R are true but R is not the correct explanation of A.
    3. A is true but R is false.
    4. A is false but R is true. [1 mark]

10.13 Check Your Concepts

  1. Define a node. Give one example of a node that is not a computer. [2 marks]

  2. Why is data divided into packets before it is carried over a network? State any two reasons. [2 marks]

  3. What is a protocol? Name any one protocol studied in this chapter and state what it is used for. [2 marks]

  4. A network in a single school building carries data at 100 Mbps, while a network covering the whole city carries data at a lower rate. Give reasons for this difference. [2 marks]

  5. Differentiate between a hub and a switch, with one example of a situation in which the difference matters. [3 marks]

  6. Differentiate between a MAC address and an IP address on any three points. [3 marks]

  7. Explain, with the help of an example, why a URL contains more than the domain name of a server. [3 marks]

  8. A fully connected mesh topology is described as the most reliable arrangement, yet it is rarely built. Calculate the number of wires needed for 8 nodes and for 40 nodes, and use your answer to explain why. [4 marks]

  9. Explain the role of a gateway in a network. Why is a firewall usually integrated with it? [4 marks]

  10. Describe, step by step, what happens from the moment a student types a web address into a browser to the moment the page is displayed. Name the servers involved at each step and state what each one supplies. [5 marks]

  11. Compare bus, star and tree topologies on the basis of cabling required, the effect of a single link failure, and the effect of the failure of a central device. Support each point with a reason. [5 marks]

10.14 Output & Debugging

  1. A network is described as follows: six computers, each joined by its own separate cable to one central device, and no computer joined directly to any other. Name the topology, and state what will happen to the network if (i) one of the six cables is cut, and (ii) the central device fails. [3 marks]

  2. Classify each of the following as a PAN, a LAN, a MAN or a WAN, and give a one-line reason for each: (i) a phone connected to a printer by Bluetooth across a desk; (ii) all the computers of a college campus; (iii) a cable-based broadband service covering a town; (iv) the network joining a company’s offices in four countries. [4 marks]

  3. A student writes the following as an IPv4 address: 192.0.2.300. Identify the error in it and correct it, giving the reason for your correction. [2 marks]

  4. Complete the missing entries (i) to (iv) in the comparison below.

Feature Hub Switch
Where data is sent (i) (ii)
Behaviour when two devices transmit at the same moment (iii) (iv)

[2 marks]

  1. In each situation below, name the single most suitable device from this chapter and give one line of reasoning: (i) a signal has faded after a run of about 100 m of cable; (ii) data must be sent from a school’s local network to a network in another state; (iii) a desktop computer has no way of accepting a network cable at all. [3 marks]

10.15 Case-Based Questions

  1. A school is setting up a network across four blocks in one campus. The number of computers in each block is:
Block Number of computers
Administrative 25
Academic 60
Library 30
Hostel 15

The Academic block is roughly 40 m from the Administrative block, the Library is 35 m from the Academic block, and the Hostel is about 250 m from the Academic block. The school also wishes to connect to the Internet.

a. Name the type of network the school is building across the campus, and give one reason for your answer. [1 mark]

b. Suggest a suitable topology for the network inside the Academic block, and justify your choice against one other topology you rejected. [2 marks]

c. Name the device the school should place on the link to the Hostel block, and the device it needs in order to reach the Internet, giving a reason for each. [2 marks]

[5 marks]

  1. A bus depot office has eight computers joined through a single hub. As bookings have increased, the staff report that transfers frequently fail and have to be repeated, and that the network slows badly when several people work at once. The depot manager also wants a printer in the office to be usable from all eight machines.

    1. Explain, in terms of how a hub works, why transfers fail when several machines are busy. [2 marks]

    2. Name the device that should replace the hub, and explain the two things it does differently that would solve the problem. [2 marks]

    3. State what the depot gains by sharing one printer over the network rather than buying eight, apart from the saving in cost. [1 mark]

[5 marks]

  1. A student opens a browser and types the address http://www.example.org/library/catalogue.htm. The page fails to open, and the browser reports that the address could not be found. A friend on the same network is able to open other websites at the same moment.

    1. Name the three parts of the address the student typed, and state what each part specifies. [2 marks]

    2. Two separate exchanges normally take place before such a page is displayed. Name both, and state which one has failed here, giving a reason. [2 marks]

    3. The student concludes, “the Internet is not working”. Give one reason why this conclusion may be wrong. [1 mark]

[5 marks]