liveBook · Manning

Nodetool toppartitions

As explained in ScyllaDB in Action

nodetool toppartitions is a Cassandra-compatible administration command that samples traffic to identify the most frequently queried partitions.

nodetool toppartitions samples cluster traffic and reports the partitions queried most often during a sampling period. Scope the result to a keyspace or table when investigating unusually heavy traffic. section 9.3.4

Use it to investigate hot partitions: a partition receiving more traffic than its shard can handle can increase latency for operations using that shard. The result helps connect the slowdown to a partition key, a recent application change, or an abusive traffic pattern. section 9.3.4 section 11.3.1

Finding a heavily queried author partition

Run `nodetool toppartitions reviews authors 10000` while investigating the `reviews.authors` table. A sample can report the partition key `33a753de-704c-11ee-b962-0242ac120002` with 39 reads, identifying it as the busiest recorded partition during sampling. section 9.3.4

(scylla-1) root@scylla-1:/# nodetool toppartitions reviews authors 10000
WRITES Sampler:
  Cardinality: ~0 (256 capacity)
  Top 10 partitions:
    Nothing recorded during sampling period...

READS Sampler:
  Cardinality: ~1 (256 capacity)
  Top 10 partitions:
    Partition                                                  Count +/-
    (reviews:authors) 33a753de-704c-11ee-b962-0242ac120002        39 0

Inspect the command output showing separate write and read samplers, cardinality, and the top partition count. section 9.3.4

How ScyllaDB in Action covers it

How deep it goes
Explains sampling, scoping, and interpretation for hot-partition diagnosis, but defers continuous monitoring and remediation details.
Examples
Demonstrates a scoped command against reviews.authors that records repeated reads of one UUID partition.
What it assumes
Assumes familiarity with ScyllaDB tables, keyspaces, partition keys, shards, and node-level administration.
What you can do after
Diagnose hot partitions by sampling traffic and identifying the partition key receiving unusually many reads or writes.
How it connects
Connects hot partitions with shards, read latency, application traffic, monitoring, and rate limiting.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of ScyllaDB in Action. The section links point to the parts of the book it draws on.