Cockroach Labs Estate economics What idle nodes, provisioned bytes and peak-sized bills cost, worked out from your estate.

Estate summary

  1. Nodes 3 baseline
  2. Avg CPU utilization 15.0% idle hardware
  3. Storage provisioned 6.0 TB 1.0 TB of data
  4. Est. monthly saving 0%

Step 5 of 8 - Storage

A replacement KV node has nothing to copy

The same node killed in both models.

Kill a KV node n1 n2 n3 n4 n5
KV nodesn1servingn2servingn3servingn4servingn5servingLocal disks: the store dies with the nodeKV node topologyAll KV nodes serving. Click one to kill it.

Stateful node on EBS

Replacement must be re-populated before it can serve

not started: 8 h 53 m to doStateful node on EBS progressReplacement must be re-populated before it can serve. Not started: 8 h 53 m to do.

Data to re-populate2000 ranges x 512 MB1.0 TB
Copy raterebalance snapshots are rate-limited per store32 MiB/s
Time to serving1.0 TB at 32 MiB/s, and the docs give a band of minutes to hours8 h 53 m
Serving?not until the copy completesno
KV nodesn1servingn2servingn3servingn4servingn5servingShared storage layer: the store outlives the nodeKV node topologyAll KV nodes serving. Click one to kill it.

Stateless KV node

A new node locks the same store and resumes

not started: under a second to doStateless KV node progressA new node locks the same store and resumes. Not started: under a second to do.

Data movednone: the store is in the storage layer already0 GB
Metadatastore lock handoff125 KB
Time to serving125 KB at 32 MiB/sunder a second
Serving?as soon as the lock is heldyes

How the handoff stays safe

A replacement locks the same store from Plenum and resumes. Fencing the old owner's write authorization is what makes the handoff safe.

How this is worked out
  • Both bars run in real time, like the scaling page. Bringing a node back is the same rate-limited copy: 1.0 TB onto the replacement at 32 MiB/s, CockroachDB's default kv.snapshot_rebalance.max_rate, so it can't serve for 8 h 53 m. That's the optimistic end, and it lands inside the "minutes to hours" the design docs give.
  • The other lane writes 125 KB to hand the store's lock to the replacement, which at the same rate is under a second. Nothing is waiting on a copy.