Year 7 · Networks · Part D: Computers in the world

Networks and the internet

In one line

A network is computers joined up to share. The internet is a network of networks. Data crosses it in small numbered packets, following agreed rules called protocols.

1

Say why we connect computers, and tell a LAN from a WAN, and the internet from the web.

2

Name the hardware in a home or school network and say what each box does.

3

Explain IP and MAC addresses, and why an IPv4 part stops at 255.

4

Follow a DNS lookup and a packet's journey, step by step.

5

Use protocols, layers, bandwidth and latency correctly, and work out download times by hand.

LAN / WANSmall-area network / wide-area network.
RouterJoins different networks. Forwards packets.
IP addressA device's address on a network. IPv4 = 4 bytes.
MAC addressThe fixed ID of a network card. 48 bits.
DNSTurns names like bbc.co.uk into IP addresses.
PacketA small numbered chunk of data.
ProtocolA set of agreed rules for communicating.
Bandwidth / latencyHow much per second / how long the trip takes.

What a network is, and why we bother

A network is two or more computers joined together so they can share. The joins can be cables or radio waves (Wi-Fi). That's it.

Without a network 3 printers. Files stuck on each machine. With a network (a LAN) 1 printer, 1 file store, 1 internet line.
The switch in the middle joins everything. Each computer can now reach the printer, the shared files and the internet.

What a network lets you share

  1. Files. Save homework on the school server. Open it from any room.

  2. Hardware. 30 computers share one printer.

  3. One internet connection for the whole building.

  4. Talking: email, chat, video calls, online games.

  5. Central care. Back up everyone's files and install updates from one place.

What it costs

  1. Money and setup. Cables, switches, servers, and someone to look after them.

  2. Viruses spread. Malware on one machine can reach all of them.

  3. Security risk. More ways in for hackers. Wi-Fi can be picked up outside the walls.

  4. One fault, many victims. If the main server or switch breaks, lots of people stop.

★Remember

A network = computers joined to share: files, hardware, an internet connection, and messages.

LAN and WAN: small area, wide area

Networks are named by how much ground they cover. A LAN is one site. A WAN joins sites that are far apart.

LAN: school in Madrid LAN: school in London WAN Lines rented from telecoms companies, over long distances
Inside each school: a LAN the school owns. Between them: a WAN made of long-distance lines and routers that other companies own.
LAN (Local Area Network)WAN (Wide Area Network)
CoversOne home, school or officeCities, countries, the world
Owned byUsually whoever uses itOften rented from telecoms companies
Joined bySwitches, Ethernet cables, Wi-FiRouters, fibre, undersea cables, satellites
SpeedUsually very fast: few users, short cablesSlower per user: long distances, shared with many
ExampleThe school networkThe internet is the biggest WAN
?Why?

Why rent instead of build? A school can run cables round its own building. It can't dig a trench from Madrid to London. So it pays a telecoms company to carry its data on lines that already exist.

e.g.Example

A PAN (personal area network) is even smaller than a LAN: your phone, earbuds and watch talking over Bluetooth. Nice to know, but not in the GCSE specs.

The internet is a network of networks. The web is one thing on it.

Your home LAN, your school LAN, a mobile phone network and a data centre are all separate networks, with separate owners. Routers join them together. All of those joined-up networks, worldwide, are the internet.

Each coloured network has its own owner. Each one's router (R) links it, through an internet service provider (ISP), to the backbone. No single company owns the internet.

The internet is the roads. The things you do on it are the traffic. The World Wide Web is just one kind of traffic.

Services that use the internet (the traffic) THE INTERNET cables, fibre, Wi-Fi, routers, satellites: the roads
Email, games and video calls all use the internet, but they are not "the web". The web is pages and links, fetched with HTTP or HTTPS and shown in a browser.
The internetThe World Wide Web
What it isThe physical network of networksA service: linked pages you view in a browser
Made ofCables, routers, satellites, serversWeb pages (HTML) on web servers, joined by links
Started1969 (ARPANET); the internet protocols from 19831989–91, Tim Berners-Lee at CERN
AnalogyThe roadsOne kind of vehicle on them (delivery vans)
!Watch out

"I'll look it up on the internet" is fine in normal life. In an exam, if the question is about web pages and browsers, say the web. If it's about cables and routers, say the internet.

The hardware: what each box does

Your home network has more parts than you think. The white box from your internet company is really four devices in one case. Tap any part of the diagram to see its job.

Dashed = Wi-Fi radioGrey line = copper Ethernet cableThick coloured line = fibre-optic cable (light)
DeviceJob in one lineReads which address?
NIC (network interface card)Connects one device to the networkHas its own MAC address
SwitchJoins devices inside one LAN. Sends data only to the right deviceMAC addresses
RouterJoins different networks. Forwards packets towards their destinationIP addresses
Wireless access pointLets devices join the LAN by Wi-FiMAC addresses
Modem / fibre boxTurns data into the signal the outside line usesNone: it just converts signals

Cables or Wi-Fi?

Copper EthernetFibre-opticWi-Fi
Data travels asElectrical pulsesFlashes of light in glassRadio waves
SpeedFast (often 1 Gbps)Fastest, over huge distancesSlower; drops through walls
DistanceUp to about 100 mMany kilometres (undersea!)Tens of metres
InterferenceA littleNone from electricityLots: walls, microwaves, neighbours
SecurityNeed to plug inVery hard to tapSignal leaks outside: must be encrypted
Freedom to moveNoNoYes
?Why?

Why does a switch beat sending to everyone? An old hub copied every message to every socket. Every device had to read and ignore other people's data, and the cable was busy all the time. A switch learns which MAC address is on which socket, so a message only goes where it's needed.

Topologies: the shape of the network

A topology is the layout: what joins to what. It decides what happens when something breaks. The GCSE specs (AQA and OCR) ask for two: star and mesh.

Star: everything goes through the middle. Mesh: lots of different paths between any two devices.
StarMesh
LayoutEvery device has its own cable to a central switchDevices join to many others (full mesh: to every other)
One cable breaksOnly that device drops offData finds another way
Centre breaksEverything stops: a single point of failureThere is no centre
CostCheap-ish: one cable per deviceExpensive: lots of links
Where you see itMost homes and schoolsThe internet's routers; mesh Wi-Fi systems
▶

Cut a cable, break a box

Tap a line to cut that cable. Tap a box to break that device. Who can Your PC still reach?

e.g.Maths

How many links does a full mesh need? Each of n devices joins to the other n − 1. That counts every link twice (once from each end), so halve it: n × (n − 1) ÷ 2. 5 devices: 5 × 4 ÷ 2 = 10. 30 devices: 30 × 29 ÷ 2 = 435 cables. That's why a whole school is never a full mesh.

!Watch out

Older books also show bus and ring topologies. They are history now and are not in the current AQA or OCR specs. Learn star and mesh well.

Addresses: IP and MAC

Every device on a network needs two kinds of address. One says where it is (IP). One says which card it is (MAC). Like a postal address and a passport number.

IPv4 address 4 bytes × 8 = 32 bits → 2³² ≈ 4.3 billion addresses MAC address who made the card this one card's number
IPv4: four numbers, each one byte. MAC: six bytes, written in hexadecimal (each pair of hex digits is one byte).

IP addresses

  1. An IP address is a device's address on a network. Routers read it to deliver packets.

  2. It can change. Take your laptop from home to school and it gets a new one, like a postal address when you move house. Most are handed out automatically (this is called DHCP).

  3. IPv4 looks like 192.168.1.25: four numbers with dots.

  4. Each number is one byte = 8 bits. From Topic 2: 8 bits make 2⁸ = 256 patterns, so each part runs from 0 to 255. That's why 192.168.300.1 is impossible.

Running out: IPv6

4 bytes = 32 bits. How many different addresses is that? Use the patterns formula from Topic 2.

  1. 32 bits make 2³² patterns. Too big to do as 32 twos in your head, so split it up.

  2. Trick: 2¹⁰ = 1,024 ≈ 1,000. Ten bits ≈ a thousand.

  3. 32 = 2 + 10 + 10 + 10. So 2³² = 2² × 2¹⁰ × 2¹⁰ × 2¹⁰.

  4. ≈ 4 × 1,000 × 1,000 × 1,000 = 4 billion. The exact answer is 4,294,967,296.

  5. The world has over 8 billion people, and many own a phone, a laptop and a games console. Not enough.

  6. So IPv6 uses 128 bits: 2¹²⁸ ≈ 340 undecillion (3.4 × 10³⁸). That's 34 followed by 37 zeros. Plenty for every grain of sand.

IPv6 is written as 8 groups of 4 hex digits: 2001:0db8:85a3:0000:0000:8a2e:0370:7334. Each hex digit = 4 bits, so 8 × 4 × 4 = 128 bits.

MAC addresses

  1. A MAC address is the fixed ID of the network card (NIC) itself, set when it's made. It doesn't change when you move.

  2. 48 bits = 6 bytes, written as 12 hex digits: 3C:22:FB:7A:1E:90.

  3. The first half says who made it. The second half is that card's own number.

  4. Switches use MAC addresses to deliver inside a LAN. Routers use IP addresses to deliver between networks.

IPv4IPv6MAC
Size32 bits (4 bytes)128 bits (16 bytes)48 bits (6 bytes)
Written as4 denary numbers, 0–2558 groups of 4 hex digits6 pairs of hex digits
Changes?Yes, depends on the networkYesNo, fixed to the card
Used byRouters, to deliver between networksSwitches, inside one LAN
e.g.Example

Addresses starting 192.168. or 10. are private: used inside homes and schools only. Millions of homes all use 192.168.1.x. Your router swaps them for its one public address when packets go out to the internet. That trick kept IPv4 alive.

DNS: the internet's phone book

Routers only understand numbers. People remember names. DNS (the Domain Name System) turns a name like www.bbc.co.uk into an IP address. No single computer knows every name, so it asks a chain of servers.

▶

Follow a DNS lookup

The IP addresses here are made-up example addresses. Real ones change.

ServerWhat it knowsPhone-book version
ResolverNothing at first, but it does the asking, and remembers answers (its cache)A helpful receptionist
Root serverWho looks after each ending: .com, .org, .uk, .esThe shelf of phone books, by country
TLD serverFor its ending, who looks after each name (bbc.co.uk, rae.es)One country's phone book
Authoritative name serverThe actual address for each name in its domainThe family's own entry
?Why?

Why not one giant list? There are hundreds of millions of domain names, changing every minute, and billions of lookups a second. One server would be overloaded and one fault would break everything. Spreading the job out (and caching answers) keeps it fast and reliable.

e.g.Try it

Type an IP address straight into a browser bar and it skips DNS. If a website "is down" but its IP address works, the problem was DNS.

Packet switching: chop it up, send, rebuild

A photo is not sent in one piece. It is cut into thousands of small packets. Each packet travels on its own and may take a different route. The receiver puts them back together.

Header PayloadTrailer From192.168.1.25 To203.0.113.7 Packet number3 of 7 The data itself"MEET AT NOON…" Check= 214 Routers read only the header, like the outside of an envelope. Payload: usually up to about 1,500 bytes. Trailer: a checksum so the receiver can spot damage. Blue = from · orange = to · green = packet (sequence) number · yellow = checksum.
Every router sends each packet on whichever link is least busy right now. So packets from the same photo can go different ways and arrive in a different order.
  1. Split. The sender cuts the file into packets and numbers them: 1 of 7, 2 of 7…

  2. Label. Each gets a header: from-address, to-address, packet number. And a checksum at the end.

  3. Send. Each packet goes off on its own.

  4. Route. Every router reads the to-address and passes the packet one hop closer, on the least busy link.

  5. Arrive. Packets turn up at different times, out of order.

  6. Check. The receiver redoes the checksum. If it doesn't match, the packet was damaged.

  7. Rebuild. Put them in order by packet number. Anything missing or damaged gets asked for again.

▶

Route a packet around trouble

Each line shows its delay in milliseconds (ms). The packet takes the fastest total route. Tap a line to cut it. Tap a router to make it busy, then broken.

The checksum, by hand

A checksum is a number worked out from the data. The sender works it out and puts it in the trailer. The receiver works it out again. Here's a very simple version: add up the letter codes, and keep only what's left after dividing by 256 (so it fits in one byte).

  1. The payload is HI!. In ASCII: H = 72, I = 73, ! = 33.

  2. Sender adds them: 72 + 73 + 33 = 178. Less than 256, so the checksum is 178. It goes in the trailer.

  3. On the way, interference flips one bit. I (73 = 01001001) becomes 75 = 01001011, the letter K.

  4. Receiver adds what arrived: 72 + 75 + 33 = 180.

  5. 180 ≠ 178. Damaged! The receiver asks for that packet again. Only one small packet is resent, not the whole file.

?Why?

Why chop it up at all? (1) Lots of people share the same cables at once: small packets take turns, so nobody hogs a line. (2) If a link breaks, packets just go another way. (3) A lost packet means a tiny resend, not starting the whole download again.

e.g.How many packets?

A 3 MB photo with about 1,500 bytes per packet: 3,000,000 ÷ 1,500 = 2,000 packets.

Protocols, and the 4-layer TCP/IP model

A protocol is a set of agreed rules for communicating: how to start, what order things go in, how to spot mistakes. Two devices made by different companies can talk because they follow the same protocols.

ProtocolStands forJobLayer
HTTPHyperText Transfer ProtocolFetches web pagesApplication
HTTPSHTTP SecureSame, but encryptedApplication
DNSDomain Name SystemTurns names into IP addressesApplication
SMTPSimple Mail Transfer ProtocolSends email, to and between mail serversApplication
IMAPInternet Message Access ProtocolCollects email; it stays on the server, synced on all your devicesApplication
POP (POP3)Post Office ProtocolCollects email; downloads it to one deviceApplication
FTPFile Transfer ProtocolMoves files between computersApplication
TCPTransmission Control ProtocolSplits into packets, numbers them, checks they all arrive, resendsTransport
UDPUser Datagram ProtocolSends packets fast with no checking. Good for games and callsTransport
IPInternet ProtocolAddresses and routes packetsInternet
Ethernet, Wi-FiMoves data across one cable or radio linkLink
Going down, each layer wraps the data in its own header, like putting a letter in an envelope, then in a parcel. Going up on the other side, each layer unwraps its own part.
  1. Application (purple): the program's own rules. HTTP asks for a page. SMTP sends an email.

  2. Transport (green): TCP chops the data into numbered packets and makes sure they all arrive. Or UDP, if speed matters more than every packet.

  3. Internet (blue): IP adds the from and to addresses, and routers forward packets across networks.

  4. Link (orange): Ethernet or Wi-Fi moves the bits across one physical link, using MAC addresses.

?Why?

Why layers? Each layer does one job and only talks to the layers next to it. So you can swap one without touching the others. Move from cable to Wi-Fi (link layer): the web page (application layer) doesn't care. Engineers can work on one layer without understanding all four.

★Exams

AQA 8525 names the four layers: application, transport, internet, link, and which protocol sits in each. OCR J277 asks for the protocols and the idea of layers and why they help, but not the names of the 4 layers. Teach the 4 names anyway: they make it clearer.

Speed: bandwidth and latency are different things

"My internet is slow" can mean two different problems. Bandwidth is how much data can flow per second. Latency is how long each bit of data takes to make the trip.

More lanes = more cars per minute (bandwidth). A longer road = each car takes longer to arrive (latency). You can have lots of lanes on a very long road.
BandwidthLatency
MeansHow much data per secondHow long data takes to arrive
Measured inMegabits per second (Mbps)Milliseconds (ms). "Ping" measures it
MotorwayNumber of lanesLength of the journey
You notice it whenDownloading big files, streaming 4KGaming ("lag"), video calls
Made worse byMany users sharing, weak Wi-Fi, old copper cablesDistance, many router hops, satellites far above Earth

A download time, by hand

A 2.5 GB game update. Your broadband is 50 Mbps. How long, at best?

  1. Same units first. 2.5 GB = 2.5 × 1,000 = 2,500 MB.

  2. Bytes → bits. Speed is in bits, so turn the file into bits too: 2,500 MB × 8 = 20,000 megabits.

  3. Divide by the speed. 20,000 ÷ 50 = 400 seconds.

  4. Make it human. 400 ÷ 60 = 6 remainder 40. So 6 minutes 40 seconds.

  5. Sense check. Real life is a bit slower: other people share the line, and every packet carries a header, not just data.

▶

The race: bandwidth vs latency

Two connections fetch the same thing. Total time = waiting time (latency) + sending time (size × 8 ÷ bandwidth). Which one wins?

striped = waiting (latency)solid = sending (bandwidth)
★Remember

Small things (game moves, clicks): latency decides. Big things (films, updates): bandwidth decides.

Client–server vs peer-to-peer

Two ways to organise who does what on a network. Either one computer is in charge (client–server), or every computer is equal (peer-to-peer).

Client–server: requests go in, responses come out, all through one place. Peer-to-peer: everyone gives and takes.
Client–serverPeer-to-peer (P2P)
HowClients request; a central server respondsEvery computer is equal and shares directly
GoodEasy to secure, back up and update in one placeCheap: no server. No single point of failure
BadServer costs money. If it fails, everyone stopsHard to secure and back up. Files spread everywhere
ExamplesSchool logins, websites, email, NetflixBitTorrent, some game updates, sharing between two phones
e.g.Example

When you open a web page, your browser is the client. It sends an HTTP request. The web server responds with the page. That is client–server, millions of times a second.

!Watch out

"Server" means a job, not a special kind of box. Any computer that responds to requests is acting as a server. Your laptop can be one.

Common mix-ups

The mistakes nearly everyone makes the first time. Read the left side, then the right.

People think

The internet and the web are the same thing.

Actually

The internet is the network. The web is one service on it, like email or games.

People think

The router box at home is just a router.

Actually

It's a router, a switch, a wireless access point and a modem in one case.

People think

Switches and routers do the same job.

Actually

A switch works inside one LAN using MAC addresses. A router joins different networks using IP addresses.

People think

An IPv4 part can be any number, like 300.

Actually

Each part is one byte: 0 to 255 only.

People think

Your IP address is fixed forever, like your MAC address.

Actually

IP addresses change with the network you join. The MAC address is the fixed one.

People think

A file travels as one piece along one wire.

Actually

It's split into packets that can take different routes and arrive out of order.

People think

Bandwidth and latency both mean "speed", so they're the same.

Actually

Bandwidth = how much per second (lanes). Latency = how long the trip takes (distance).

People think

100 Mbps downloads 100 MB per second.

Actually

Speeds are in bits: 100 ÷ 8 = 12.5 MB per second at most.

Check yourself

Quick questions first. Then endless practice: a wrong answer shows you the working, step by step.

[ {"q":"Why can't an IPv4 part be 300?","o":["Each part is one byte: max 255","300 is reserved","Routers can't count that high"],"a":0,"w":"8 bits hold 0 to 255."}, {"q":"Which turns www.bbc.co.uk into an IP address?","o":["DNS","HTTP","SMTP"],"a":0,"w":"DNS is the phone book."}, {"q":"Packets arrive out of order. How are they fixed?","o":["Sequence numbers","They're sent again","The router sorts them"],"a":0,"w":"The receiver puts them back in order by number."}, {"q":"Which device joins your home LAN to your ISP's network?","o":["Switch","Router","Wireless access point"],"a":1,"w":"A **router** joins **different** networks. A switch only joins devices inside one LAN."}, {"q":"In a star network the central switch breaks. What happens?","o":["Only one device drops off","Every device loses the network","Data finds another route"],"a":1,"w":"The switch is a **single point of failure**: everything goes through it."}, {"q":"Which protocol checks every packet arrived and asks again for missing ones?","o":["IP","TCP","FTP"],"a":1,"w":"TCP (transport layer) numbers packets and resends lost ones. IP just addresses and routes them."}, {"q":"A game feels laggy, but big downloads are fast. The problem is most likely…","o":["Low bandwidth","High latency","Too many IP addresses"],"a":1,"w":"Game moves are tiny, so the **waiting time** (latency) matters, not the lanes (bandwidth)."}, {"q":"A 400 MB file on a 100 Mbps line takes at best…","o":["4 seconds","32 seconds","40 seconds"],"a":1,"w":"400 × 8 = 3,200 megabits. 3,200 ÷ 100 = **32 seconds**."} ]