Easier to read with cream paper, a tint, more contrast or larger text? Choose your colours and text, once, for every page.

Preview

DI 2.3: Monitoring, logging and capacity management

This is the first page of the lesson. Read it and have a go at the activities. The rest is in the full lesson.

60 minutes

The disk that filled up overnight

On Monday morning, the school mail server is down. The disk filled up over the weekend. Nobody knew, because nobody was watching.

The disk had been growing for months. A graph would have shown it running out. An alert would have sent a message three weeks ago.

Watching, recording and planning is the work of monitoring, logging and capacity management.

Key words

WordWhat it means
Monitoringwatching a system all the time and measuring how it is doing
Metricone measured number, such as how many requests a server has had
Alerta message sent when a metric goes past a limit
Thresholdthe limit that, when passed, makes an alert
Loga file where a program writes what happened, with the time
Capacity managementmaking sure a system always has enough room and power, now and later
Loadhow much work a server is doing at one time
CPUthe main processor of a computer
RAMthe short term memory of a computer
Networkcomputers and devices joined together so they can share data

The cells students fill in are left blank in this preview.

By the end of this lesson

Note

I can explain monitoring, logging and capacity management, read real server numbers and work out when a disk will fill.

Starter

Have a go

Starter

3 questions
Have a go: your answers are marked here and then forgotten. Sign in if you would like your score kept, and to pick up where you left off.Sign in to keep your score

Your answers are marked here and are not kept. A college account keeps every student’s marks.

Monitoring and alerts

Monitoring measures a system all the time. Each measure is a metric: CPU use, free disk space, how many users are connected.

A graph of a metric shows trends. A threshold turns it into an alert. For example: if free disk space falls below a set amount, send an email to the technician.

Alerts mean nobody has to stare at a screen.

Logging: the record of events

A log records what happened and when. A web server logs every request. A switch logs when a port goes down. A login system logs every failed password.

Logs help in three ways: to find the cause of a fault, to spot an attack, and to prove what happened. Keep logs safe and in time order. Big firms send logs from every device to one place.

See real numbers

The lab has a small web server called app. A helper program reads its status page and turns it into metrics.

Press Start the lab, then press Run on each command in turn.

Read the web server status page

Command
curl -s http://app:8081/stub_status

A command for the lesson’s lab terminal. It is shown here and not run.

How to read it

Note

"Active connections" is how many people are connected now. The three numbers under "server accepts handled requests" are connections accepted, connections handled and total requests. "Reading, Writing, Waiting" shows what each connection is doing.

The lesson goes on

12 more parts of this lesson are in the full curriculum, with the tasks, the final check and the labs. A college account gives your students all of it.