Virtual nodes
Virtual nodes distribute data across nodes at a finer granularity than single-token architecture. Virtual nodes simplify many tasks in Hyper-Converged Database (HCD):
HCD automatically:
-
Calculates and assigns tokens to each node.
-
Rebalances the cluster when you add or remove nodes.
When a node joins the cluster, it assumes responsibility for an even portion of data from the other nodes in the cluster. If a node fails, HCD spreads the load evenly across other nodes in the cluster. * HCD rebuilds a dead node faster because it involves every other node in the cluster. * You can assign different proportions of vnodes to each machine in a cluster, allowing you to use both smaller and larger computers when building a cluster.
While vnodes provide considerable operational benefits, keep in mind that the number of vnodes you assign to a given node can impact cluster-wide operations. For instance, when you increase the number of vnodes, you also increase the number of repairs that run during a repair cycle, which increases full cluster repair times. |
Distribute data using vnodes
Virtual nodes use consistent hashing to distribute data without requiring new token generation and assignment.
In single-token architecture clusters, you must calculate and assign a single token to each node in a cluster. Each token determines the node’s position in the cluster, also known as the ring, and its portion of data according to its hash value. Vnodes allow each node to own a large number of small partition ranges distributed throughout the cluster.
Although vnodes use consistent hashing to distribute data, using them doesn’t require token generation and assignment.

The top portion of the graphic shows a cluster without vnodes. In the single-token architecture paradigm, you assign each node a single token that represents a location in the ring. Each node stores data determined by mapping the partition key to a token value within a range from the previous node to its assigned value. Each node also contains copies of each row from other nodes in the cluster. For example, if the replication factor is 3, range E replicates to nodes 5, 6, and 1. A node owns exactly one contiguous partition range in the ring space.
The bottom portion of the graphic shows a ring with vnodes. Within a cluster, HCD randomly selects vnodes, making them non-contiguous. The hash of the partition key determines the placement of a row within many smaller partition ranges belonging to each node.