Slowdowns never happen while you’re watching. Something eats the CPU at 03:12, and by the time you open top it’s gone. atop can write what it sees to a file, so you can look at it later like a flight recorder.
atop -w /tmp/atop.raw 60 30
atop -r /tmp/atop.raw
The first command writes a raw file with one sample every 60 seconds, thirty times. The second opens it in the normal atop screen. In replay, t shows the next sample and T the previous one. b jumps to a timestamp and r rewinds to the start.
To look at a specific stretch, add -b and -e with a time in the form hhmm:
atop -r /var/log/atop/atop_20261130 -b 0300 -e 0330
If you run atop -r without a file name, it opens today’s file in /var/log/atop/. Debian’s packaging keeps such a daily file by default, with a sample every 600 seconds and 28 days of history (settings in /etc/default/atop). Other distros may differ.
One caveat: the raw file contains process data for the whole system, so treat it as private and don’t send it around. A short interval over a long time also makes it grow quickly.
Further reading: atop man page (Debian), atop project
Going deeper: Keep a domain pointed at your home with Cloudflare DDNS on Unraid