Erasure Coding
In short: Erasure coding is the storage of data in multiple locations by segmenting it, expanding it, and encoding it with redundant information.
Erasure coding is the storage of data in multiple locations by segmenting it, expanding it, and encoding it with redundant information. The original data can then be rebuilt from only a subset of the pieces, even if some of them are lost.
Why it matters
Keeping full copies of data in several places is simple but expensive, because every extra copy costs the full storage again. Erasure coding reaches the same resilience with much less space, which is why it is used in data centers, cloud storage, and decentralized storage networks that spread file pieces across independent operators. Some blockchain scaling designs also rely on it for data availability sampling: block data is extended with redundancy so that light nodes can check it was published by downloading only a few random pieces. The price is extra computation to encode and rebuild the data, and extra network traffic when a lost piece has to be repaired.
Example
Using a Reed-Solomon code, a file is split into four data pieces, and two extra parity pieces are calculated from them. The six pieces are stored on six different servers, and any four of them are enough to rebuild the file. The file survives the loss of any two servers while using one and a half times its original size, whereas keeping three full copies to survive two failures would use three times the size.