Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents
maxLevel2

There are three types of storage policies in Swarm: replication, erasure coding, and versioning which can be customized at the level of domains and buckets, but this section concerns the Swarm settings that control the cluster-wide requirements. Thesepolicies These policies appear in the Policy section of the Cluster Settings in the Swarm UI:

...

Excerpt

What EC Protection Level is needed?

The EC protection level determines how strictly EC segments must be distributed for a write to succeed, or else return an error (412 Precondition Failed) to the writing application. After Swarm writes an object to the cluster, the health processor attempts to maintain the requested protection level. If cluster resources become unavailable, it degrades gracefully. When this occurs, the health processor logs errors, alerting you that the requested protection cannot be maintained and data may be at risk.

Regardless of the protection level set, Swarm always makes a best effort to distribute segments as broadly as possible across hardware, to protect data.

ec.protectionLevel

Cluster requirements

Effect

subcluster

>= (k+p)/p subclusters

Requires a subcluster for every p segments. Use only if geographical or systems-based subclusters are defined to factor into content protection.

node (default)

>= (k+p)/p nodes

Requires a node for every p segments. Use for most situations.

Important: When working with a small number of nodes, verify the EC encoding can support what exists. 

  • With 3 nodes, use 3:2 encoding ((3 + 2) ÷ 2 = 3 nodes required), but not 3:1 encoding ((3 + 1) ÷ 1 = 4 nodes required).

  • With 4 nodes, use 4:2 encoding ((4 + 2) ÷ 2 = 3 nodes required), but not 4:1 encoding ((4 + 1) ÷ 1 = 5 nodes required).

volume

>= k+p volumes

Least protection. Requires k+p volumes, but p+1 nodes are still needed because the manifest must be written to separate nodes. Use only if you have insufficient nodes for node-based protection. 

< k+p volumes

Unsupportable. EC writes fail.

Note

Using ec.subclusterLossTolerance = volume is not recommended as it may not provide data availability when one or more nodes are down for maintenance.

Note

Deprecated

The setting  ec.subclusterLossTolerance has been deprecated, therefore, remove it from configurations when upgrading to Swarm 10.

Versioning Policy

Swarm has policy support for object versioning. Versioning can be enabled for specific contexts (domains and buckets) after the cluster is configured to permit versioning of objects. 

...