inspect_memory_dump
Get live memory and CPU stats for a Docker container, plus top processes. Helps diagnose performance issues in running containers.
Instructions
Return live memory and CPU stats, plus top processes, for a container.
Uses `docker stats --no-stream` for a point-in-time snapshot (this is not
a real heap dump — the name is aspirational). The container must be
running for stats to be available.
Args:
container_id: Container ID or name.
include_processes: If True, also runs `ps aux --sort=-%mem` inside
the container and includes the output.
Returns:
dict with cpu_percent, memory_mb, memory_limit_mb, memory_percent,
and optionally processes (list of strings, one per ps line).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| container_id | Yes | ||
| include_processes | No |