root / doc / design-shared-storage.rst @ 333bd799
History | View | Annotate | Download (12.1 kB)
1 | e19f7095 | Constantinos Venetsanopoulos | ============================= |
---|---|---|---|
2 | e19f7095 | Constantinos Venetsanopoulos | Ganeti shared storage support |
3 | e19f7095 | Constantinos Venetsanopoulos | ============================= |
4 | a997cec5 | Apollon Oikonomopoulos | |
5 | a997cec5 | Apollon Oikonomopoulos | This document describes the changes in Ganeti 2.3+ compared to Ganeti |
6 | e19f7095 | Constantinos Venetsanopoulos | 2.3 storage model. It also documents the ExtStorage Interface. |
7 | a997cec5 | Apollon Oikonomopoulos | |
8 | a997cec5 | Apollon Oikonomopoulos | .. contents:: :depth: 4 |
9 | e7e2552e | Constantinos Venetsanopoulos | .. highlight:: shell-example |
10 | a997cec5 | Apollon Oikonomopoulos | |
11 | a997cec5 | Apollon Oikonomopoulos | Objective |
12 | a997cec5 | Apollon Oikonomopoulos | ========= |
13 | a997cec5 | Apollon Oikonomopoulos | |
14 | a997cec5 | Apollon Oikonomopoulos | The aim is to introduce support for externally mirrored, shared storage. |
15 | a997cec5 | Apollon Oikonomopoulos | This includes two distinct disk templates: |
16 | a997cec5 | Apollon Oikonomopoulos | |
17 | a997cec5 | Apollon Oikonomopoulos | - A shared filesystem containing instance disks as regular files |
18 | a997cec5 | Apollon Oikonomopoulos | typically residing on a networked or cluster filesystem (e.g. NFS, |
19 | a997cec5 | Apollon Oikonomopoulos | AFS, Ceph, OCFS2, etc.). |
20 | a997cec5 | Apollon Oikonomopoulos | - Instance images being shared block devices, typically LUNs residing on |
21 | a997cec5 | Apollon Oikonomopoulos | a SAN appliance. |
22 | a997cec5 | Apollon Oikonomopoulos | |
23 | a997cec5 | Apollon Oikonomopoulos | Background |
24 | a997cec5 | Apollon Oikonomopoulos | ========== |
25 | 855f9bad | Constantinos Venetsanopoulos | |
26 | a997cec5 | Apollon Oikonomopoulos | DRBD is currently the only shared storage backend supported by Ganeti. |
27 | a997cec5 | Apollon Oikonomopoulos | DRBD offers the advantages of high availability while running on |
28 | a997cec5 | Apollon Oikonomopoulos | commodity hardware at the cost of high network I/O for block-level |
29 | a997cec5 | Apollon Oikonomopoulos | synchronization between hosts. DRBD's master-slave model has greatly |
30 | a997cec5 | Apollon Oikonomopoulos | influenced Ganeti's design, primarily by introducing the concept of |
31 | a997cec5 | Apollon Oikonomopoulos | primary and secondary nodes and thus defining an instance's “mobility |
32 | a997cec5 | Apollon Oikonomopoulos | domain”. |
33 | a997cec5 | Apollon Oikonomopoulos | |
34 | a997cec5 | Apollon Oikonomopoulos | Although DRBD has many advantages, many sites choose to use networked |
35 | a997cec5 | Apollon Oikonomopoulos | storage appliances for Virtual Machine hosting, such as SAN and/or NAS, |
36 | a997cec5 | Apollon Oikonomopoulos | which provide shared storage without the administrative overhead of DRBD |
37 | a997cec5 | Apollon Oikonomopoulos | nor the limitation of a 1:1 master-slave setup. Furthermore, new |
38 | a997cec5 | Apollon Oikonomopoulos | distributed filesystems such as Ceph are becoming viable alternatives to |
39 | a997cec5 | Apollon Oikonomopoulos | expensive storage appliances. Support for both modes of operation, i.e. |
40 | a997cec5 | Apollon Oikonomopoulos | shared block storage and shared file storage backend would make Ganeti a |
41 | a997cec5 | Apollon Oikonomopoulos | robust choice for high-availability virtualization clusters. |
42 | a997cec5 | Apollon Oikonomopoulos | |
43 | a997cec5 | Apollon Oikonomopoulos | Throughout this document, the term “externally mirrored storage” will |
44 | a997cec5 | Apollon Oikonomopoulos | refer to both modes of shared storage, suggesting that Ganeti does not |
45 | a997cec5 | Apollon Oikonomopoulos | need to take care about the mirroring process from one host to another. |
46 | a997cec5 | Apollon Oikonomopoulos | |
47 | a997cec5 | Apollon Oikonomopoulos | Use cases |
48 | a997cec5 | Apollon Oikonomopoulos | ========= |
49 | 855f9bad | Constantinos Venetsanopoulos | |
50 | a997cec5 | Apollon Oikonomopoulos | We consider the following use cases: |
51 | a997cec5 | Apollon Oikonomopoulos | |
52 | a997cec5 | Apollon Oikonomopoulos | - A virtualization cluster with FibreChannel shared storage, mapping at |
53 | fcad6377 | Iustin Pop | least one LUN per instance, accessible by the whole cluster. |
54 | a997cec5 | Apollon Oikonomopoulos | - A virtualization cluster with instance images stored as files on an |
55 | a997cec5 | Apollon Oikonomopoulos | NFS server. |
56 | a997cec5 | Apollon Oikonomopoulos | - A virtualization cluster storing instance images on a Ceph volume. |
57 | a997cec5 | Apollon Oikonomopoulos | |
58 | a997cec5 | Apollon Oikonomopoulos | Design Overview |
59 | a997cec5 | Apollon Oikonomopoulos | =============== |
60 | a997cec5 | Apollon Oikonomopoulos | |
61 | a997cec5 | Apollon Oikonomopoulos | The design addresses the following procedures: |
62 | a997cec5 | Apollon Oikonomopoulos | |
63 | a997cec5 | Apollon Oikonomopoulos | - Refactoring of all code referring to constants.DTS_NET_MIRROR. |
64 | a997cec5 | Apollon Oikonomopoulos | - Obsolescence of the primary-secondary concept for externally mirrored |
65 | a997cec5 | Apollon Oikonomopoulos | storage. |
66 | a997cec5 | Apollon Oikonomopoulos | - Introduction of a shared file storage disk template for use with networked |
67 | a997cec5 | Apollon Oikonomopoulos | filesystems. |
68 | 855f9bad | Constantinos Venetsanopoulos | - Introduction of a shared block device disk template with device |
69 | a997cec5 | Apollon Oikonomopoulos | adoption. |
70 | 855f9bad | Constantinos Venetsanopoulos | - Introduction of the External Storage Interface. |
71 | a997cec5 | Apollon Oikonomopoulos | |
72 | a997cec5 | Apollon Oikonomopoulos | Additionally, mid- to long-term goals include: |
73 | a997cec5 | Apollon Oikonomopoulos | |
74 | a997cec5 | Apollon Oikonomopoulos | - Support for external “storage pools”. |
75 | a997cec5 | Apollon Oikonomopoulos | |
76 | a997cec5 | Apollon Oikonomopoulos | Refactoring of all code referring to constants.DTS_NET_MIRROR |
77 | a997cec5 | Apollon Oikonomopoulos | ============================================================= |
78 | a997cec5 | Apollon Oikonomopoulos | |
79 | a997cec5 | Apollon Oikonomopoulos | Currently, all storage-related decision-making depends on a number of |
80 | a997cec5 | Apollon Oikonomopoulos | frozensets in lib/constants.py, typically constants.DTS_NET_MIRROR. |
81 | a997cec5 | Apollon Oikonomopoulos | However, constants.DTS_NET_MIRROR is used to signify two different |
82 | a997cec5 | Apollon Oikonomopoulos | attributes: |
83 | a997cec5 | Apollon Oikonomopoulos | |
84 | a997cec5 | Apollon Oikonomopoulos | - A storage device that is shared |
85 | a997cec5 | Apollon Oikonomopoulos | - A storage device whose mirroring is supervised by Ganeti |
86 | a997cec5 | Apollon Oikonomopoulos | |
87 | a997cec5 | Apollon Oikonomopoulos | We propose the introduction of two new frozensets to ease |
88 | a997cec5 | Apollon Oikonomopoulos | decision-making: |
89 | a997cec5 | Apollon Oikonomopoulos | |
90 | a997cec5 | Apollon Oikonomopoulos | - constants.DTS_EXT_MIRROR, holding externally mirrored disk templates |
91 | a997cec5 | Apollon Oikonomopoulos | - constants.DTS_MIRRORED, being a union of constants.DTS_EXT_MIRROR and |
92 | a997cec5 | Apollon Oikonomopoulos | DTS_NET_MIRROR. |
93 | a997cec5 | Apollon Oikonomopoulos | |
94 | a997cec5 | Apollon Oikonomopoulos | Additionally, DTS_NET_MIRROR will be renamed to DTS_INT_MIRROR to reflect |
95 | a997cec5 | Apollon Oikonomopoulos | the status of the storage as internally mirrored by Ganeti. |
96 | a997cec5 | Apollon Oikonomopoulos | |
97 | a997cec5 | Apollon Oikonomopoulos | Thus, checks could be grouped into the following categories: |
98 | a997cec5 | Apollon Oikonomopoulos | |
99 | a997cec5 | Apollon Oikonomopoulos | - Mobility checks, like whether an instance failover or migration is |
100 | a997cec5 | Apollon Oikonomopoulos | possible should check against constants.DTS_MIRRORED |
101 | a997cec5 | Apollon Oikonomopoulos | - Syncing actions should be performed only for templates in |
102 | a997cec5 | Apollon Oikonomopoulos | constants.DTS_NET_MIRROR |
103 | a997cec5 | Apollon Oikonomopoulos | |
104 | a997cec5 | Apollon Oikonomopoulos | Obsolescence of the primary-secondary node model |
105 | a997cec5 | Apollon Oikonomopoulos | ================================================ |
106 | a997cec5 | Apollon Oikonomopoulos | |
107 | a997cec5 | Apollon Oikonomopoulos | The primary-secondary node concept has primarily evolved through the use |
108 | a997cec5 | Apollon Oikonomopoulos | of DRBD. In a globally shared storage framework without need for |
109 | a997cec5 | Apollon Oikonomopoulos | external sync (e.g. SAN, NAS, etc.), such a notion does not apply for the |
110 | a997cec5 | Apollon Oikonomopoulos | following reasons: |
111 | a997cec5 | Apollon Oikonomopoulos | |
112 | a997cec5 | Apollon Oikonomopoulos | 1. Access to the storage does not necessarily imply different roles for |
113 | a997cec5 | Apollon Oikonomopoulos | the nodes (e.g. primary vs secondary). |
114 | a997cec5 | Apollon Oikonomopoulos | 2. The same storage is available to potentially more than 2 nodes. Thus, |
115 | a997cec5 | Apollon Oikonomopoulos | an instance backed by a SAN LUN for example may actually migrate to |
116 | a997cec5 | Apollon Oikonomopoulos | any of the other nodes and not just a pre-designated failover node. |
117 | a997cec5 | Apollon Oikonomopoulos | |
118 | a997cec5 | Apollon Oikonomopoulos | The proposed solution is using the iallocator framework for run-time |
119 | a997cec5 | Apollon Oikonomopoulos | decision making during migration and failover, for nodes with disk |
120 | a997cec5 | Apollon Oikonomopoulos | templates in constants.DTS_EXT_MIRROR. Modifications to gnt-instance and |
121 | a997cec5 | Apollon Oikonomopoulos | gnt-node will be required to accept target node and/or iallocator |
122 | a997cec5 | Apollon Oikonomopoulos | specification for these operations. Modifications of the iallocator |
123 | a997cec5 | Apollon Oikonomopoulos | protocol will be required to address at least the following needs: |
124 | a997cec5 | Apollon Oikonomopoulos | |
125 | a997cec5 | Apollon Oikonomopoulos | - Allocation tools must be able to distinguish between internal and |
126 | a997cec5 | Apollon Oikonomopoulos | external storage |
127 | a997cec5 | Apollon Oikonomopoulos | - Migration/failover decisions must take into account shared storage |
128 | a997cec5 | Apollon Oikonomopoulos | availability |
129 | a997cec5 | Apollon Oikonomopoulos | |
130 | a997cec5 | Apollon Oikonomopoulos | Introduction of a shared file disk template |
131 | a997cec5 | Apollon Oikonomopoulos | =========================================== |
132 | a997cec5 | Apollon Oikonomopoulos | |
133 | a997cec5 | Apollon Oikonomopoulos | Basic shared file storage support can be implemented by creating a new |
134 | a997cec5 | Apollon Oikonomopoulos | disk template based on the existing FileStorage class, with only minor |
135 | a997cec5 | Apollon Oikonomopoulos | modifications in lib/bdev.py. The shared file disk template relies on a |
136 | a997cec5 | Apollon Oikonomopoulos | shared filesystem (e.g. NFS, AFS, Ceph, OCFS2 over SAN or DRBD) being |
137 | a997cec5 | Apollon Oikonomopoulos | mounted on all nodes under the same path, where instance images will be |
138 | a997cec5 | Apollon Oikonomopoulos | saved. |
139 | a997cec5 | Apollon Oikonomopoulos | |
140 | a997cec5 | Apollon Oikonomopoulos | A new cluster initialization option is added to specify the mountpoint |
141 | a997cec5 | Apollon Oikonomopoulos | of the shared filesystem. |
142 | a997cec5 | Apollon Oikonomopoulos | |
143 | a997cec5 | Apollon Oikonomopoulos | The remainder of this document deals with shared block storage. |
144 | a997cec5 | Apollon Oikonomopoulos | |
145 | a997cec5 | Apollon Oikonomopoulos | Introduction of a shared block device template |
146 | a997cec5 | Apollon Oikonomopoulos | ============================================== |
147 | a997cec5 | Apollon Oikonomopoulos | |
148 | a997cec5 | Apollon Oikonomopoulos | Basic shared block device support will be implemented with an additional |
149 | a997cec5 | Apollon Oikonomopoulos | disk template. This disk template will not feature any kind of storage |
150 | a997cec5 | Apollon Oikonomopoulos | control (provisioning, removal, resizing, etc.), but will instead rely |
151 | a997cec5 | Apollon Oikonomopoulos | on the adoption of already-existing block devices (e.g. SAN LUNs, NBD |
152 | a997cec5 | Apollon Oikonomopoulos | devices, remote iSCSI targets, etc.). |
153 | a997cec5 | Apollon Oikonomopoulos | |
154 | a997cec5 | Apollon Oikonomopoulos | The shared block device template will make the following assumptions: |
155 | a997cec5 | Apollon Oikonomopoulos | |
156 | a997cec5 | Apollon Oikonomopoulos | - The adopted block device has a consistent name across all nodes, |
157 | a997cec5 | Apollon Oikonomopoulos | enforced e.g. via udev rules. |
158 | a997cec5 | Apollon Oikonomopoulos | - The device will be available with the same path under all nodes in the |
159 | a997cec5 | Apollon Oikonomopoulos | node group. |
160 | a997cec5 | Apollon Oikonomopoulos | |
161 | 855f9bad | Constantinos Venetsanopoulos | Introduction of the External Storage Interface |
162 | e7e2552e | Constantinos Venetsanopoulos | ============================================== |
163 | 855f9bad | Constantinos Venetsanopoulos | |
164 | e7e2552e | Constantinos Venetsanopoulos | Overview |
165 | e7e2552e | Constantinos Venetsanopoulos | -------- |
166 | e7e2552e | Constantinos Venetsanopoulos | |
167 | e7e2552e | Constantinos Venetsanopoulos | To extend the shared block storage template and give Ganeti the ability |
168 | e7e2552e | Constantinos Venetsanopoulos | to control and manipulate external storage (provisioning, removal, |
169 | e7e2552e | Constantinos Venetsanopoulos | growing, etc.) we need a more generic approach. The generic method for |
170 | e7e2552e | Constantinos Venetsanopoulos | supporting external shared storage in Ganeti will be to have an |
171 | e7e2552e | Constantinos Venetsanopoulos | ExtStorage provider for each external shared storage hardware type. The |
172 | e7e2552e | Constantinos Venetsanopoulos | ExtStorage provider will be a set of files (executable scripts and text |
173 | e7e2552e | Constantinos Venetsanopoulos | files), contained inside a directory which will be named after the |
174 | e7e2552e | Constantinos Venetsanopoulos | provider. This directory must be present across all nodes of a nodegroup |
175 | e7e2552e | Constantinos Venetsanopoulos | (Ganeti doesn't replicate it), in order for the provider to be usable by |
176 | e7e2552e | Constantinos Venetsanopoulos | Ganeti for this nodegroup (valid). The external shared storage hardware |
177 | e7e2552e | Constantinos Venetsanopoulos | should also be accessible by all nodes of this nodegroup too. |
178 | e7e2552e | Constantinos Venetsanopoulos | |
179 | e7e2552e | Constantinos Venetsanopoulos | An “ExtStorage provider” will have to provide the following methods: |
180 | e7e2552e | Constantinos Venetsanopoulos | |
181 | e7e2552e | Constantinos Venetsanopoulos | - Create a disk |
182 | e7e2552e | Constantinos Venetsanopoulos | - Remove a disk |
183 | e7e2552e | Constantinos Venetsanopoulos | - Grow a disk |
184 | e7e2552e | Constantinos Venetsanopoulos | - Attach a disk to a given node |
185 | e7e2552e | Constantinos Venetsanopoulos | - Detach a disk from a given node |
186 | 855f9bad | Constantinos Venetsanopoulos | - SetInfo to a disk (add metadata) |
187 | e7e2552e | Constantinos Venetsanopoulos | - Verify its supported parameters |
188 | e7e2552e | Constantinos Venetsanopoulos | |
189 | e7e2552e | Constantinos Venetsanopoulos | The proposed ExtStorage interface borrows heavily from the OS |
190 | e7e2552e | Constantinos Venetsanopoulos | interface and follows a one-script-per-function approach. An ExtStorage |
191 | e7e2552e | Constantinos Venetsanopoulos | provider is expected to provide the following scripts: |
192 | e7e2552e | Constantinos Venetsanopoulos | |
193 | e7e2552e | Constantinos Venetsanopoulos | - ``create`` |
194 | e7e2552e | Constantinos Venetsanopoulos | - ``remove`` |
195 | e7e2552e | Constantinos Venetsanopoulos | - ``grow`` |
196 | e7e2552e | Constantinos Venetsanopoulos | - ``attach`` |
197 | e7e2552e | Constantinos Venetsanopoulos | - ``detach`` |
198 | 855f9bad | Constantinos Venetsanopoulos | - ``setinfo`` |
199 | e7e2552e | Constantinos Venetsanopoulos | - ``verify`` |
200 | e7e2552e | Constantinos Venetsanopoulos | |
201 | e7e2552e | Constantinos Venetsanopoulos | All scripts will be called with no arguments and get their input via |
202 | e7e2552e | Constantinos Venetsanopoulos | environment variables. A common set of variables will be exported for |
203 | e7e2552e | Constantinos Venetsanopoulos | all commands, and some of them might have extra ones. |
204 | e7e2552e | Constantinos Venetsanopoulos | |
205 | e7e2552e | Constantinos Venetsanopoulos | ``VOL_NAME`` |
206 | e7e2552e | Constantinos Venetsanopoulos | The name of the volume. This is unique for Ganeti and it |
207 | e7e2552e | Constantinos Venetsanopoulos | uses it to refer to a specific volume inside the external storage. |
208 | e7e2552e | Constantinos Venetsanopoulos | ``VOL_SIZE`` |
209 | e7e2552e | Constantinos Venetsanopoulos | The volume's size in mebibytes. |
210 | e7e2552e | Constantinos Venetsanopoulos | ``VOL_NEW_SIZE`` |
211 | e7e2552e | Constantinos Venetsanopoulos | Available only to the `grow` script. It declares the |
212 | e7e2552e | Constantinos Venetsanopoulos | new size of the volume after grow (in mebibytes). |
213 | e7e2552e | Constantinos Venetsanopoulos | ``EXTP_name`` |
214 | e7e2552e | Constantinos Venetsanopoulos | ExtStorage parameter, where `name` is the parameter in |
215 | e7e2552e | Constantinos Venetsanopoulos | upper-case (same as OS interface's ``OSP_*`` parameters). |
216 | 855f9bad | Constantinos Venetsanopoulos | ``VOL_METADATA`` |
217 | 855f9bad | Constantinos Venetsanopoulos | A string containing metadata to be set for the volume. |
218 | 855f9bad | Constantinos Venetsanopoulos | This is exported only to the ``setinfo`` script. |
219 | e7e2552e | Constantinos Venetsanopoulos | |
220 | e7e2552e | Constantinos Venetsanopoulos | All scripts except `attach` should return 0 on success and non-zero on |
221 | e7e2552e | Constantinos Venetsanopoulos | error, accompanied by an appropriate error message on stderr. The |
222 | e7e2552e | Constantinos Venetsanopoulos | `attach` script should return a string on stdout on success, which is |
223 | e7e2552e | Constantinos Venetsanopoulos | the block device's full path, after it has been successfully attached to |
224 | e7e2552e | Constantinos Venetsanopoulos | the host node. On error it should return non-zero. |
225 | e7e2552e | Constantinos Venetsanopoulos | |
226 | e7e2552e | Constantinos Venetsanopoulos | Implementation |
227 | e7e2552e | Constantinos Venetsanopoulos | -------------- |
228 | e7e2552e | Constantinos Venetsanopoulos | |
229 | e7e2552e | Constantinos Venetsanopoulos | To support the ExtStorage interface, we will introduce a new disk |
230 | e7e2552e | Constantinos Venetsanopoulos | template called `ext`. This template will implement the existing Ganeti |
231 | e7e2552e | Constantinos Venetsanopoulos | disk interface in `lib/bdev.py` (create, remove, attach, assemble, |
232 | 855f9bad | Constantinos Venetsanopoulos | shutdown, grow, setinfo), and will simultaneously pass control to the |
233 | 855f9bad | Constantinos Venetsanopoulos | external scripts to actually handle the above actions. The `ext` disk |
234 | 855f9bad | Constantinos Venetsanopoulos | template will act as a translation layer between the current Ganeti disk |
235 | e7e2552e | Constantinos Venetsanopoulos | interface and the ExtStorage providers. |
236 | e7e2552e | Constantinos Venetsanopoulos | |
237 | e7e2552e | Constantinos Venetsanopoulos | We will also introduce a new IDISK_PARAM called `IDISK_PROVIDER = |
238 | e7e2552e | Constantinos Venetsanopoulos | provider`, which will be used at the command line to select the desired |
239 | e7e2552e | Constantinos Venetsanopoulos | ExtStorage provider. This parameter will be valid only for template |
240 | e7e2552e | Constantinos Venetsanopoulos | `ext` e.g.:: |
241 | e7e2552e | Constantinos Venetsanopoulos | |
242 | e7e2552e | Constantinos Venetsanopoulos | $ gnt-instance add -t ext --disk=0:size=2G,provider=sample_provider1 |
243 | e7e2552e | Constantinos Venetsanopoulos | |
244 | e7e2552e | Constantinos Venetsanopoulos | The Extstorage interface will support different disks to be created by |
245 | e7e2552e | Constantinos Venetsanopoulos | different providers. e.g.:: |
246 | e7e2552e | Constantinos Venetsanopoulos | |
247 | e7e2552e | Constantinos Venetsanopoulos | $ gnt-instance add -t ext --disk=0:size=2G,provider=sample_provider1 \ |
248 | e7e2552e | Constantinos Venetsanopoulos | --disk=1:size=1G,provider=sample_provider2 \ |
249 | e7e2552e | Constantinos Venetsanopoulos | --disk=2:size=3G,provider=sample_provider1 |
250 | e7e2552e | Constantinos Venetsanopoulos | |
251 | e7e2552e | Constantinos Venetsanopoulos | Finally, the ExtStorage interface will support passing of parameters to |
252 | e7e2552e | Constantinos Venetsanopoulos | the ExtStorage provider. This will also be done per disk, from the |
253 | e7e2552e | Constantinos Venetsanopoulos | command line:: |
254 | e7e2552e | Constantinos Venetsanopoulos | |
255 | e7e2552e | Constantinos Venetsanopoulos | $ gnt-instance add -t ext --disk=0:size=1G,provider=sample_provider1,\ |
256 | e7e2552e | Constantinos Venetsanopoulos | param1=value1,param2=value2 |
257 | e7e2552e | Constantinos Venetsanopoulos | |
258 | e7e2552e | Constantinos Venetsanopoulos | The above parameters will be exported to the ExtStorage provider's |
259 | e7e2552e | Constantinos Venetsanopoulos | scripts as the enviromental variables: |
260 | e7e2552e | Constantinos Venetsanopoulos | |
261 | e7e2552e | Constantinos Venetsanopoulos | - `EXTP_PARAM1 = str(value1)` |
262 | e7e2552e | Constantinos Venetsanopoulos | - `EXTP_PARAM2 = str(value2)` |
263 | e7e2552e | Constantinos Venetsanopoulos | |
264 | e7e2552e | Constantinos Venetsanopoulos | We will also introduce a new Ganeti client called `gnt-storage` which |
265 | e7e2552e | Constantinos Venetsanopoulos | will be used to diagnose ExtStorage providers and show information about |
266 | e7e2552e | Constantinos Venetsanopoulos | them, similarly to the way `gnt-os diagose` and `gnt-os info` handle OS |
267 | e7e2552e | Constantinos Venetsanopoulos | definitions. |
268 | e7e2552e | Constantinos Venetsanopoulos | |
269 | a997cec5 | Apollon Oikonomopoulos | Long-term shared storage goals |
270 | a997cec5 | Apollon Oikonomopoulos | ============================== |
271 | e7e2552e | Constantinos Venetsanopoulos | |
272 | a997cec5 | Apollon Oikonomopoulos | Storage pool handling |
273 | a997cec5 | Apollon Oikonomopoulos | --------------------- |
274 | a997cec5 | Apollon Oikonomopoulos | |
275 | a997cec5 | Apollon Oikonomopoulos | A new cluster configuration attribute will be introduced, named |
276 | a997cec5 | Apollon Oikonomopoulos | “storage_pools”, modeled as a dictionary mapping storage pools to |
277 | e7e2552e | Constantinos Venetsanopoulos | external storage providers (see below), e.g.:: |
278 | a997cec5 | Apollon Oikonomopoulos | |
279 | a997cec5 | Apollon Oikonomopoulos | { |
280 | a997cec5 | Apollon Oikonomopoulos | "nas1": "foostore", |
281 | a997cec5 | Apollon Oikonomopoulos | "nas2": "foostore", |
282 | a997cec5 | Apollon Oikonomopoulos | "cloud1": "barcloud", |
283 | a997cec5 | Apollon Oikonomopoulos | } |
284 | a997cec5 | Apollon Oikonomopoulos | |
285 | a997cec5 | Apollon Oikonomopoulos | Ganeti will not interpret the contents of this dictionary, although it |
286 | a997cec5 | Apollon Oikonomopoulos | will provide methods for manipulating them under some basic constraints |
287 | a997cec5 | Apollon Oikonomopoulos | (pool identifier uniqueness, driver existence). The manipulation of |
288 | a997cec5 | Apollon Oikonomopoulos | storage pools will be performed by implementing new options to the |
289 | a997cec5 | Apollon Oikonomopoulos | `gnt-cluster` command:: |
290 | a997cec5 | Apollon Oikonomopoulos | |
291 | e7e2552e | Constantinos Venetsanopoulos | $ gnt-cluster modify --add-pool nas1 foostore |
292 | e7e2552e | Constantinos Venetsanopoulos | $ gnt-cluster modify --remove-pool nas1 # There must be no instances using |
293 | e7e2552e | Constantinos Venetsanopoulos | # the pool to remove it |
294 | a997cec5 | Apollon Oikonomopoulos | |
295 | a997cec5 | Apollon Oikonomopoulos | Furthermore, the storage pools will be used to indicate the availability |
296 | a997cec5 | Apollon Oikonomopoulos | of storage pools to different node groups, thus specifying the |
297 | a997cec5 | Apollon Oikonomopoulos | instances' “mobility domain”. |
298 | a997cec5 | Apollon Oikonomopoulos | |
299 | e7e2552e | Constantinos Venetsanopoulos | The pool, in which to put the new instance's disk, will be defined at |
300 | e7e2552e | Constantinos Venetsanopoulos | the command line during `instance add`. This will become possible by |
301 | e7e2552e | Constantinos Venetsanopoulos | replacing the IDISK_PROVIDER parameter with a new one, called `IDISK_POOL |
302 | e7e2552e | Constantinos Venetsanopoulos | = pool`. The cmdlib logic will then look at the cluster-level mapping |
303 | e7e2552e | Constantinos Venetsanopoulos | dictionary to determine the ExtStorage provider for the given pool. |
304 | a997cec5 | Apollon Oikonomopoulos | |
305 | e7e2552e | Constantinos Venetsanopoulos | gnt-storage |
306 | e7e2552e | Constantinos Venetsanopoulos | ----------- |
307 | a997cec5 | Apollon Oikonomopoulos | |
308 | e7e2552e | Constantinos Venetsanopoulos | The ``gnt-storage`` client can be extended to support pool management |
309 | e7e2552e | Constantinos Venetsanopoulos | (creation/modification/deletion of pools, connection/disconnection of |
310 | e7e2552e | Constantinos Venetsanopoulos | pools to nodegroups, etc.). It can also be extended to diagnose and |
311 | e7e2552e | Constantinos Venetsanopoulos | provide information for internal disk templates too, such as lvm and |
312 | e7e2552e | Constantinos Venetsanopoulos | drbd. |
313 | a997cec5 | Apollon Oikonomopoulos | |
314 | a997cec5 | Apollon Oikonomopoulos | .. vim: set textwidth=72 : |