Linux Labs

Inside the system: resources, kernel, processes / Stage 2 of 12

Memory, swap and the OOM killer

Not running Starting usually ~20 s
Leave the lesson

Step 6 of 9 · on a machine · 3 min

A ceiling for the cache

The lab-cache service keeps data in memory and runs with no ceiling. If it grows, the shortage will hit the whole machine, and the OOM killer will pick a victim among all its processes.

Exercise · do it

Put a ceiling on the cache

The lab-cache service keeps hot data in memory and runs with no memory ceiling. Give it a 96 MiB ceiling: it must work right now and survive a package update. Do not change the unit file in /usr/lib/systemd/system.

Sign in and start The machine is available after signing in

Goals · 0 of 2

  • Give the service a 96 MiB ceiling not done yet
  • Keep the ceiling outside the package file not done yet

Step goals

0 of 2
  • Give the service a 96 MiB ceiling — not done yet
  • Keep the ceiling outside the package file — not done yet
Ubuntu 24.04

Step goals

0 of 2
  • Give the service a 96 MiB ceiling — not done yet
  • Keep the ceiling outside the package file — not done yet
Loading…