A server configured to form part of a data protection group, wherein the server comprises: a memory (344, 346); a transceiver configured to receive a request to store a data file from another device; and a processor coupled to the memory and the transceiver and configured to: acquire the request to store a data file, write the data file to a container in the memory; and encode the container contents when the container becomes full to generate a plurality of encoded blocks, wherein the transceiver is further configured to: distribute the plurality of encoded blocks over peer servers in the data protection group, wherein the server further comprises a cache, wherein the container contents forms a data block, and wherein encoding the container contents comprises: determine a size of a coding matrix; determine a size of a submatrix of the data block such that the sum of the size of the coding matrix and the size of the submatrix is smaller than the size of the cache; request that the submatrix of the data block and the coding matrix be written to the cache from the memory, wherein the cache is configured to store the submatrix of the data block and the coding matrix; and compute a portion of an encoded block by selecting and computing the exclusive or of at least two rows of the submatrix of the data block, wherein the at least two rows are selected according to elements of the coding matrix. a memory (344, 346); a transceiver configured to receive a request to store a data file from another device; and a processor coupled to the memory and the transceiver and configured to: acquire the request to store a data file, write the data file to a container in the memory; and encode the container contents when the container becomes full to generate a plurality of encoded blocks, acquire the request to store a data file, write the data file to a container in the memory; and encode the container contents when the container becomes full to generate a plurality of encoded blocks, wherein the transceiver is further configured to: distribute the plurality of encoded blocks over peer servers in the data protection group, wherein the server further comprises a cache, wherein the container contents forms a data block, and wherein encoding the container contents comprises: determine a size of a coding matrix; determine a size of a submatrix of the data block such that the sum of the size of the coding matrix and the size of the submatrix is smaller than the size of the cache; request that the submatrix of the data block and the coding matrix be written to the cache from the memory, wherein the cache is configured to store the submatrix of the data block and the coding matrix; and compute a portion of an encoded block by selecting and computing the exclusive or of at least two rows of the submatrix of the data block, wherein the at least two rows are selected according to elements of the coding matrix. determine a size of a coding matrix; determine a size of a submatrix of the data block such that the sum of the size of the coding matrix and the size of the submatrix is smaller than the size of the cache; request that the submatrix of the data block and the coding matrix be written to the cache from the memory, wherein the cache is configured to store the submatrix of the data block and the coding matrix; and compute a portion of an encoded block by selecting and computing the exclusive or of at least two rows of the submatrix of the data block, wherein the at least two rows are selected according to elements of the coding matrix.