]> git.proxmox.com Git - ceph.git/blob - ceph/doc/rados/operations/erasure-code-jerasure.rst
update ceph source to reef 18.1.2
[ceph.git] / ceph / doc / rados / operations / erasure-code-jerasure.rst
1 ============================
2 Jerasure erasure code plugin
3 ============================
4
5 The *jerasure* plugin is the most generic and flexible plugin, it is
6 also the default for Ceph erasure coded pools.
7
8 The *jerasure* plugin encapsulates the `Jerasure
9 <https://github.com/ceph/jerasure>`_ library. It is
10 recommended to read the ``jerasure`` documentation to
11 understand the parameters. Note that the ``jerasure.org``
12 web site as of 2023 may no longer be connected to the original
13 project or legitimate.
14
15 Create a jerasure profile
16 =========================
17
18 To create a new *jerasure* erasure code profile:
19
20 .. prompt:: bash $
21
22 ceph osd erasure-code-profile set {name} \
23 plugin=jerasure \
24 k={data-chunks} \
25 m={coding-chunks} \
26 technique={reed_sol_van|reed_sol_r6_op|cauchy_orig|cauchy_good|liberation|blaum_roth|liber8tion} \
27 [crush-root={root}] \
28 [crush-failure-domain={bucket-type}] \
29 [crush-device-class={device-class}] \
30 [directory={directory}] \
31 [--force]
32
33 Where:
34
35 ``k={data chunks}``
36
37 :Description: Each object is split in **data-chunks** parts,
38 each stored on a different OSD.
39
40 :Type: Integer
41 :Required: Yes.
42 :Example: 4
43
44 ``m={coding-chunks}``
45
46 :Description: Compute **coding chunks** for each object and store them
47 on different OSDs. The number of coding chunks is also
48 the number of OSDs that can be down without losing data.
49
50 :Type: Integer
51 :Required: Yes.
52 :Example: 2
53
54 ``technique={reed_sol_van|reed_sol_r6_op|cauchy_orig|cauchy_good|liberation|blaum_roth|liber8tion}``
55
56 :Description: The more flexible technique is *reed_sol_van* : it is
57 enough to set *k* and *m*. The *cauchy_good* technique
58 can be faster but you need to chose the *packetsize*
59 carefully. All of *reed_sol_r6_op*, *liberation*,
60 *blaum_roth*, *liber8tion* are *RAID6* equivalents in
61 the sense that they can only be configured with *m=2*.
62
63 :Type: String
64 :Required: No.
65 :Default: reed_sol_van
66
67 ``packetsize={bytes}``
68
69 :Description: The encoding will be done on packets of *bytes* size at
70 a time. Choosing the right packet size is difficult. The
71 *jerasure* documentation contains extensive information
72 on this topic.
73
74 :Type: Integer
75 :Required: No.
76 :Default: 2048
77
78 ``crush-root={root}``
79
80 :Description: The name of the crush bucket used for the first step of
81 the CRUSH rule. For instance **step take default**.
82
83 :Type: String
84 :Required: No.
85 :Default: default
86
87 ``crush-failure-domain={bucket-type}``
88
89 :Description: Ensure that no two chunks are in a bucket with the same
90 failure domain. For instance, if the failure domain is
91 **host** no two chunks will be stored on the same
92 host. It is used to create a CRUSH rule step such as **step
93 chooseleaf host**.
94
95 :Type: String
96 :Required: No.
97 :Default: host
98
99 ``crush-device-class={device-class}``
100
101 :Description: Restrict placement to devices of a specific class (e.g.,
102 ``ssd`` or ``hdd``), using the crush device class names
103 in the CRUSH map.
104
105 :Type: String
106 :Required: No.
107
108 ``directory={directory}``
109
110 :Description: Set the **directory** name from which the erasure code
111 plugin is loaded.
112
113 :Type: String
114 :Required: No.
115 :Default: /usr/lib/ceph/erasure-code
116
117 ``--force``
118
119 :Description: Override an existing profile by the same name.
120
121 :Type: String
122 :Required: No.
123