A log is a list of events, and a list of events becomes a story once you put it in order. This set covers picking fields out of a line, counting who was busy, why the sort before uniq matters, and how to read a run of failures without jumping to a conclusion.
Each one is marked as you go, and the explanation arrives straight after, which is
the part worth reading.
4 questions, marked as you go.
Tasks
These need your own device. Run the command in Termux, then paste what it printed.
The marking looks at what the output means, so spacing, version numbers and
ordering do not matter. If you have not installed anything yet, the
lesson covers the setup.
Turn a log into a timeline
This writes a short auth log and then reads it two ways: as a timeline of time, user and result, and as a ranking of the sources that failed. Read the shape of both, not the exact addresses.
Run this in Termux
On your own device. Nothing on this page executes it. The command runs in
your terminal, and this box only reads what you paste back.
The timeline drops the source field. The ranking keeps only the source field. Each view answers a different question about the same lines.
the timeline shows the time, the user and the result
each noisy source is ranked with a count
the timeline and the ranking are both shown
the commands actually ran
What a good answer looks like
A timeline of four lines, each a timestamp, a user and a result, in the order the events happened. Then a heading and one ranked row per failing source, each a count then the source, largest count first. The timeline tells you what happened in sequence; the ranking tells you who was noisiest. Together they are the story in a screen, which is the point of the lesson. An empty ranking means the grep found no failures.
Marking your own work
Both halves of this are checked in your browser, with no server involved, so nothing
stops you from pasting output you did not run. The tasks are written so that the
easiest way to pass one is to actually do it and read the result, which is the whole
intention.