Glossary/When something goes wrong

Spindump

Also: hang report

Quick answer

A spindump is a diagnostic report that records what processes on a Mac were doing, used to investigate apps that hang or stop responding. macOS includes a `spindump` tool, and Activity Monitor can create one from its More menu.

A spindump is like a sample of the whole system rather than a single process. It shows which threads were running or waiting, which helps a developer see why an app stopped responding.

In Activity Monitor, Apple describes Spindump as creating a report for unresponsive apps that were terminated using force quit. It is one of several diagnostic reports in the More menu, along with Sample Process and System Diagnostics.

How to create a spindump in Activity Monitor

Click the More button (the three dots) at the top of the Activity Monitor window and choose Spindump. You may be asked for an administrator password. The report opens when it is done, and you can save it.

Create it while the app is hung, not after, so the report captures the problem.

What to do with a spindump

Attach it to a bug report to the app's developer or to Apple through Feedback Assistant. The report can include the names of apps and processes you are running, so review it before sharing it publicly.

How to take a spindump from Terminal

The spindump command samples every process on the Mac, so it must run as root. It only records what processes are doing and does not stop them.

  1. Open Terminal while the app is still hung.
  2. Run sudo spindump Safari -reveal, replacing Safari with part of the app's name. Enter your administrator password when asked.
  3. Wait while it samples. The default length is 10 seconds.
  4. When it finishes, the report is saved in /tmp, and the -reveal option shows it in Finder.

How to read a spindump

The app you name is listed first, and every other process follows. Each process shows its threads and the call stacks seen while sampling.

  • By default, stacks are sorted by count. A line that starts with 84 was seen in 84 samples.
  • A star (*) at the start of a frame marks kernel code.
  • The deepest frame on each stack shows whether the thread was running or suspended.
  • If the app's main thread is suspended waiting on another process, look at that other process in the same report. That is the main advantage over a single process sample.

Where spindumps are saved

When you force quit an app that was not responding, macOS can create a report automatically and may offer to send it to Apple. These reports are stored in /Library/Logs/DiagnosticReports.

You can browse them in the Console app, in Applications > Utilities. Under Reports in the sidebar, look at Spin Reports and Diagnostic Reports. Select a report to read it.

Reports you take yourself from Activity Monitor open in a window when they finish. Save the report from that window before you close it, so you have a copy to send.

Sample, spindump, or System Diagnostics

Activity Monitor's More menu offers several reports. Pick the one that matches the problem. A spindump is much larger than a sample because it includes every process, and System Diagnostics takes longer still and shows a privacy notice before it runs. If a developer asks for a sample, send a sample. If Apple Support asks for a specific report, send that one.

  • Sample Process: one process, about 3 seconds. Use it when you know which app is stuck or busy.
  • Spindump: every process on the Mac. Use it when an app hangs and the cause may be another process.
  • System Diagnostics: a larger report built from logs across the Mac, usually requested by Apple Support.

Questions people ask

What is a spindump on a Mac?

It is a diagnostic report of what processes were doing, used to find why an app hung. You can create one from the More menu in Activity Monitor.

What is the difference between a spindump and a sample?

Sample Process records one selected process. A spindump looks at processes across the system, which helps when the cause of a hang is outside the app itself.

Is spindump using a lot of CPU normal?

It can use CPU for a short time while it writes a report, often after an app hangs. It should stop on its own once the report is done.

Why does spindump need an administrator password?

It reads the call stacks of every process on the Mac, including system processes. macOS only allows that for root.

Can I take a spindump when nothing is frozen?

Yes, but it will only show normal activity. Take it while the app is hung so the report captures the problem.

Why did a spindump appear after I force quit an app?

macOS uses spindump to record what an unresponsive app was doing when it was force quit. That report is what the "send to Apple" dialog offers to submit.

Related

Looking for something better than Activity Monitor? See the best Activity Monitor alternatives for Mac, or browse every term in the glossary.