| CPC G06F 3/0644 (2013.01) [G06F 3/064 (2013.01); G06F 3/067 (2013.01); G06F 3/0604 (2013.01)] | 8 Claims |

|
1. A data partitioning method, wherein the method is applied to a master node in a distributed storage system, comprising:
receiving a partitioned storage capacity sent by each storage node in the distributed storage system; wherein the partitioned storage capacity is a storage capacity of each partition comprised in the storage node;
determining a storage capacity of an i-th rolling block according to the partitioned storage capacity, where i is a positive integer;
determining whether the storage capacity of the i-th rolling block meets a preset condition according to the storage capacity of the i-th rolling block;
creating an (i+1)-th rolling block in response to the fact that the storage capacity of the i-th rolling block meets a preset condition; wherein the (i+1)-th rolling block is capable of accommodating M pieces of data, where M is a positive integer;
splitting the (i+1)-th rolling block into N partitions on average, where N is an integer greater than or equal to 2; and
establishing a mapping relationship between N partitions in the (i+1)-th rolling block and storage nodes in the distributed storage system, so that the storage node writes data into the partitions according to the mapping relationship.
|