Revision dfba45b1
b/man/ganeti-os-interface.rst | ||
---|---|---|
18 | 18 |
REFERENCE |
19 | 19 |
--------- |
20 | 20 |
|
21 |
There are six required files: *create*, *import*, *export*, *rename*,
|
|
21 |
There are eight required files: *create*, *import*, *export*, *rename*,
|
|
22 | 22 |
*verify* (executables), *ganeti_api_version*, *variants.list* and |
23 | 23 |
*parameters.list* (text files). |
24 | 24 |
|
... | ... | |
114 | 114 |
|
115 | 115 |
OSP_*name* |
116 | 116 |
Each OS parameter (see below) will be exported in its own |
117 |
variable, prefixed with ``OSP``, and upper-cased. For example, a |
|
117 |
variable, prefixed with ``OSP_``, and upper-cased. For example, a
|
|
118 | 118 |
``dhcp`` parameter will be exported as ``OSP_DHCP``. |
119 | 119 |
|
120 | 120 |
DEBUG_LEVEL |
... | ... | |
141 | 141 |
environment. |
142 | 142 |
|
143 | 143 |
The ``INSTANCE_REINSTALL`` variable is set to ``1`` when this create |
144 |
request is reinstalling and existing instance, rather than creating
|
|
144 |
request is reinstalling an existing instance, rather than creating |
|
145 | 145 |
one anew. This can be used, for example, to preserve some data in the |
146 | 146 |
old instance in an OS-specific way. |
147 | 147 |
|
... | ... | |
156 | 156 |
The specific disk to backup is denoted by two additional environment |
157 | 157 |
variables: ``EXPORT_INDEX`` which denotes the index in the instance |
158 | 158 |
disks structure (and could be used for example to skip the second disk |
159 |
if not needed for backup) and ``EXPORT_PATH`` which has the same value
|
|
160 |
as ``DISK_N_PATH`` but is duplicate here for easier usage by shell |
|
159 |
if not needed for backup) and ``EXPORT_DEVICE`` which has the same value
|
|
160 |
as ``DISK_N_PATH`` but is duplicated here for easier usage by shell
|
|
161 | 161 |
scripts (rather than parse the ``DISK_...`` variables). |
162 | 162 |
|
163 | 163 |
To provide the user with an estimate on how long the export will take, |
... | ... | |
179 | 179 |
those passed to **export**, whose output will be provided on |
180 | 180 |
stdin. |
181 | 181 |
|
182 |
The difference in variables is that the current disk is called by
|
|
182 |
The difference in variables is that the current disk is denoted by
|
|
183 | 183 |
``IMPORT_DEVICE`` and ``IMPORT_INDEX`` (instead of ``EXPORT_...``). |
184 | 184 |
|
185 | 185 |
rename |
... | ... | |
214 | 214 |
|
215 | 215 |
Currently (API version 20), only one parameter is supported: |
216 | 216 |
``parameters``. This should validate the ``OSP_`` variables from the |
217 |
environment, and output diagnostic message in case the validation |
|
217 |
environment, and output diagnostic messages in case the validation
|
|
218 | 218 |
fails. |
219 | 219 |
|
220 | 220 |
.. highlight:: sh |
... | ... | |
245 | 245 |
|
246 | 246 |
The ganeti_api_version file is a plain text file containing the |
247 | 247 |
version(s) of the guest OS API that this OS definition complies |
248 |
with, one per line. The version documented by this man page is 15,
|
|
249 |
so this file must contain the number 15 followed by a newline if
|
|
248 |
with, one per line. The version documented by this man page is 20,
|
|
249 |
so this file must contain the number 20 followed by a newline if
|
|
250 | 250 |
only this version is supported. A script compatible with more than |
251 | 251 |
one Ganeti version should contain the most recent version first |
252 |
(i.e. 15), followed by the old version(s) (in this case 10 and/or
|
|
253 |
5).
|
|
252 |
(i.e. 20), followed by the old version(s) (in this case 15 and/or
|
|
253 |
10).
|
|
254 | 254 |
|
255 | 255 |
variants.list |
256 | 256 |
~~~~~~~~~~~~~ |
... | ... | |
281 | 281 |
Backwards compatibility |
282 | 282 |
~~~~~~~~~~~~~~~~~~~~~~~ |
283 | 283 |
|
284 |
Ganeti 2.3 and up is compatible with API version 10, 15 and 20. The OS |
|
284 |
Ganeti 2.3 and up is compatible with API versions 10, 15 and 20. The OS
|
|
285 | 285 |
parameters and related scripts (verify) are only supported in |
286 | 286 |
version 20. The variants functionality (variants.list, and OS_VARIANT |
287 | 287 |
env. var) are supported/present only in version 15 and up. |
Also available in: Unified diff