This feature is available since CLI version 2.7.0.
Usage
To initialize a storage with erasure coding enabled, run this command (assuming 5 data shards and 2 parity shards):
Then you can run backup, check, prune, etc as usual.
When a bad chunk is detected, you'll see log messages like this:
To check if a storage is configured with erasure coding, run duplicacy -d list and it should report the numbers of data and parity shards:
Encoding Format
The encoded chunk file starts with a 10 byte unique banner, then a 14 byte header containing the chunk size and parity parameters, followed by hashes of each shard, then the contents of shards, and finally the 14 byte header again for redundancy: