umamaheswararao commented on a change in pull request #3006: URL: https://github.com/apache/ozone/pull/3006#discussion_r791393277
########## File path: hadoop-hdds/docs/content/feature/ErasureCoding.md ########## @@ -0,0 +1,215 @@ +--- +title: "Ozone Erasure Coding" +weight: 1 +menu: + main: + parent: Features +summary: Erasure Coding Support for Ozone. +--- +<!--- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +## Background + +Distributed systems basic expectation is to provide the data durability. +To provide the higher data durability, many popular storage systems use replication +approach which is expensive. The Apache Ozone supports `RATIS/THREE` replication scheme. +The Ozone default replication scheme `RATIS/THREE` has 200% overhead in storage +space and other resources (e.g., network bandwidth). +However, for warm and cold datasets with relatively low I/O activities, additional +block replicas rarely accessed during normal operations, but still consume the same +amount of resources as the first replica. + +Therefore, a natural improvement is to use Erasure Coding (EC) in place of replication, +which provides the same level of fault-tolerance with much less storage space. +In typical Erasure Coding (EC) setups, the storage overhead is no more than 50%. +The replication factor of an EC file is meaningless. Instead of replication factor, +we introduced ReplicationConfig interface to specify the required type of replication, +either `RATIS/THREE` or `EC`. + +Integrating EC with Ozone can improve storage efficiency while still providing similar +data durability as traditional replication-based Ozone deployments. +As an example, a 3x replicated file with 6 blocks will consume 6*3 = `18` blocks of disk space. +But with EC (6 data, 3 parity) deployment, it will only consume `9` blocks of disk space. + +## Architecture + +The storage data layout is a key factor in the implementation of EC. After deep analysis +and several technical consideration, the most fitting data layout is striping model. +The data striping layout is not new. The striping model already adapted by several other +file systems(Ex: Quantcast File System, Hadoop Distributed File System etc) successfully before. + +For example, with the EC (6 data, 3 parity) scheme, the data chunks will be distributed to first 6 data nodes in order +and then client generates the 3 parity chunks and transfer to remaining 3 nodes in order. +These 9 chunks together we call as "Stripe". Next 6 chunks will be distributed to the same first 6 data nodes again +and the parity to remaining 3 nodes. These 9 data nodes stored blocks together called as "BlockGroup". + +If the application is continuing to write beyond teh size of `6 * BLOCK_SIZE`, then client will request new block group from Ozone Manager. Review comment: done -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
