EC Storage Policy
Enable EC3+2
Cloudian Support a number of different Erasure Coding Policies for storage protection. These are based on best practice and offer known good By default, EC3+2 Storage Policy is disabled. In circumstances where this policy is desired (small clusters / performance requirements), it can be enabled by agreement with your SE or support through hsctl commands. Once enabled we can investigate a Hybrid Policy
Warning
You should never create or use a Storage Policy that is unsupported by Cloudian. Doing so may invalidate support and can cause significant performance issues. When in doubt, discuss options with your SE or your Professional Services representative.
In our case, we have 5 nodes which will allow us to use EC3+2 policy.
Instructions
- SSH into your Config Controller Node (node1) as sa_admin and start a new session or sessionless shell
-
Issue the following command to modify the default Erasure Coding setting to include EC 3+2
hsctl config set hyperstore.storagePolicy.EC.singleDC=3:2,4:2,6:2,8:2,9:3,12:4
-
Next we need to apply the new setting.
hsctl config apply hyperstore
-
Finally we restart the s3 service to commit the new setting.
hsctl service restart s3 --nodes=ALL
Note
We do not need to restart the CMC service as the setting will dynamically be applied in the relavent field
Warning
Remember to exit the ssh session on completion
Create EC Storage Policy
Instructions
- Login as Admin User
- Select Cluster Tab
- Select Storage Policies Sub-Tab
- Click + Create Storage Policy
- Type “ec32hybrid” as Policy Name
- Type “Erasure Coding 3+2 Hybrid” under description
- Leave Number of Datacenters as 1
- Ensure EC Within Single Datacenter is selected
- Check or Change Erasure Coding K + M Value to 3+2
Instructions
- Select a Hybrid Policy Threshold of 32KiB
- Leave all other settings to default and click Save
Instructions
- Confirm the new Storage Policy is correctly defined
Note the number of replicas in the policy - can you explain why each policy has the shown number of replicas?
Create EC bucket
Instructions
- Login as User Account or use View User Data as admin user.
- Click +Add New Bucket
- Type “myhybridbucket” in Bucket Name
- Select ec32hybrid Storage Policy
- Click Create
Upload Data to bucket
Note
We are now going to upload 2 files, one below and one above the hybrid threshold
Instructions
- Click Objects Tab
- Select “myhybridbucket”
- Click Upload File
- Upload the 5k and 50k File
- Click Start Upload
- Ensure Upload completes successfully
Locate EC Object
Instructions
- Login as Admin User
- Select Analytics Tab
- Select Object Locator Sub-Tab
- Type “myhybridbucket” in Bucket Name
- Type 50k in Object Name
- Click Find
- Validate Type as “EC”
- Validate that there are 5 Separate Fragments (3 + 2)
Instructions
- Login as Admin User
- Select Analytics Tab
- Select Object Locator Sub-Tab
- Type “myhybridbucket” in Bucket Name
- Type 5k in Object Name
- Click Find
- Validate Type as “Replica”
- Validate that there are 3 Replicas (m+1)