Nodetool repair: The basic default sequential repair covers all nodes, computes merkle trees in sequence one node at a time. Only need to run the command one node. Nodetool repair -par: covers all nodes, computes merkle trees for each node at the same time. Much higher IO load as every copy of a key range is scanned at once. Can be totally OK with SSDs and throughput limits. Only need to run the command one node. Nodetool repair -pr: Only covers the ranges owned by the node's token(s). Must be run on each node because each node owns a partial share of the ring.
Incremental repair: only consider range changes since the last repair. Probably can be combined with whatever other flags. > On Apr 13, 2015, at 2:37 PM, Benyi Wang <bewang.t...@gmail.com> wrote: > > What about "incremental repair" and "sequential repair"? > > I ran "nodetool repair -- keyspace table" on one node. I found the repair > sessions running on different nodes. Will this command repair the whole table? > > In this page: > http://docs.datastax.com/en/cassandra/2.1/cassandra/operations/ops_repair_nodes_c.html#concept_ds_ebj_d3q_gk__opsRepairPrtRng > > <http://docs.datastax.com/en/cassandra/2.1/cassandra/operations/ops_repair_nodes_c.html#concept_ds_ebj_d3q_gk__opsRepairPrtRng> > > Using the nodetool repair -pr (–partitioner-range) option repairs only the > first range returned by the partitioner for a node. Other replicas for that > range still have to perform the Merkle tree calculation, causing a validation > compaction. > > Does it sound like -pr runs on one node? > I'm still don't understand "the first range returned by the partitioned for a > node"? > > On Mon, Apr 13, 2015 at 1:40 PM, Robert Coli <rc...@eventbrite.com > <mailto:rc...@eventbrite.com>> wrote: > On Mon, Apr 13, 2015 at 1:36 PM, Benyi Wang <bewang.t...@gmail.com > <mailto:bewang.t...@gmail.com>> wrote: > I need to run compaction one each node, > In general, there is no requirement to manually run compaction. Minor > compaction occurs in the background, automatically. > To repair a table (column family), I only need to run repair on any of nodes. > It depends on whether you are doing -pr or non -pr repair. > > If you are doing -pr repair, you run repair on all nodes. If you do non -pr > repair, you have to figure out what set of nodes to run it on. That's why -pr > exists, to simplify this. > > =Rob > >