Total and max shard conflict

A finite cluster.routing.allocation.total_shards_per_node hard cap on your data nodes conflicts with cluster.max_shards_per_node or leaves too little headroom to place shards after a node loss or during rebalancing. Elasticsearch defaults this hard cap to unlimited (-1) so allocation can move shards freely.

Note

For a complete list of insights, refer to AutoOps insights.

Field Value
Component Elasticsearch
Severity Medium
Scope Cluster
Domains configuration, shard-allocation, stability

The following is an example of what you might see when this insight is triggered. Real insights use live data and links from your deployment or cluster.

cluster.routing.allocation.total_shards_per_node is 800. cluster.max_shards_per_node is 1000. Data nodes: 3. One-node-loss headroom needs at least 1500 shards per node at full budget.

Note

AutoOps shows different recommendations depending on how their conditions match your deployment or cluster.

cluster.max_shards_per_node sets a cluster-wide shard budget (roughly the setting times the number of data nodes). cluster.routing.allocation.total_shards_per_node is a hard per-node placement cap. When that hard cap is finite and tighter than the budget share, or too close to the load you need after losing a data node, Elasticsearch can leave shards unassigned during recovery or rebalancing.

Elasticsearch defaults the hard cap to unlimited (-1) so nodes can absorb shards when topology changes. Prefer raising or clearing a conflicting hard cap, adding data nodes, or reducing shard count. Lower cluster.max_shards_per_node only when the cluster budget itself should shrink.

Troubleshoot shard capacity health issues