pcachetop is a Linux page-cache attribution and refault-like churn profiler written in Rust.
It reports observed file/inode residency, hot regions, eviction-like deletes,
delete-to-add churn, and the processes associated with page-cache population.
Residency is an event-derived estimate; dev:inode is the stable identity and
paths are best-effort display metadata.
cargo build --releaseBinary:
target/release/pcachetopLive view:
sudo target/release/pcachetop live --interval 1s --bucket-size 1MiBRecord and report:
sudo target/release/pcachetop record --duration 30s --out /tmp/trace.pcache.jsonl
target/release/pcachetop report /tmp/trace.pcache.jsonl --index fixtures/indexes/workloads.index.jsonlPath resolution:
target/release/pcachetop index --root /tmp/pcachetop-test --out /tmp/pcachetop-index.jsonl
target/release/pcachetop resolve --dev 253:0 --inode 12345 --index /tmp/pcachetop-index.jsonlrecordandlivecurrently useperf recordandperf script.- Live mode uses a background
/proc/*/fdresolver unless--no-proc-fdsis set. - Terminal tables use fixed-width columns, middle-truncated paths, and
file-level
LAST_ADD_PIDvalues inpid:processNameform. - Process attribution means observed demand/population context, not ownership.
- Delete events are eviction-like and may also reflect truncation, invalidation, or explicit cache dropping.
- Kernel tracepoint fields vary by kernel version.