|
1 |
==============================================================
|
|
2 |
Ganeti Instance Import/Export using Open Virtualization Format
|
|
3 |
==============================================================
|
|
4 |
|
|
5 |
Background
|
|
6 |
==========
|
|
7 |
|
|
8 |
Open Virtualization Format is an open standard for packaging
|
|
9 |
information regarding virtual machines. It is used, among other, by
|
|
10 |
VMWare, VirtualBox and XenServer. OVF allows users to migrate between
|
|
11 |
virtualization software without the need of reconfiguring hardware,
|
|
12 |
network or operating system.
|
|
13 |
|
|
14 |
Currently, exporting instance in Ganeti results with a configuration
|
|
15 |
file that is readable only for Ganeti. It disallows the users to
|
|
16 |
change the platform they use without loosing all the machine's
|
|
17 |
configuration. Import function in Ganeti is also currently limited to
|
|
18 |
the previously prepared instances.
|
|
19 |
|
|
20 |
Implementation of OVF support allows users to migrate to Ganeti from
|
|
21 |
other platforms, thus potentially increasing the usage. It also
|
|
22 |
enables virtual machine end-users to create their own machines
|
|
23 |
(e.g. in VirtualBox or SUSE Studio) and then add them to Ganeti
|
|
24 |
cluster, thus providing better personalization.
|
|
25 |
|
|
26 |
Overview
|
|
27 |
========
|
|
28 |
|
|
29 |
Open Virtualization Format description
|
|
30 |
--------------------------------------
|
|
31 |
|
|
32 |
According to the DMTF document introducing the standard: "The Open
|
|
33 |
Virtualization Format (OVF) Specification describes an open, secure,
|
|
34 |
portable, efficient and extensible format for the packaging and
|
|
35 |
distribution of software to be run in virtual machines." OVF supports
|
|
36 |
both single and multiple- configurations of VMs in one package, is
|
|
37 |
host- and virtualization platform-independent and optimized for
|
|
38 |
distribution (e.g. by allowing usage of public key infrastructure and
|
|
39 |
providing tools for management of basic software licensing).
|
|
40 |
|
|
41 |
There are no limitations regarding hard drive images used, as long as
|
|
42 |
the description is provided. Any hardware described in a proper
|
|
43 |
i.e. CIM - Common Information Model) format is accepted, although
|
|
44 |
there is no guarantee that every virtualization software will support
|
|
45 |
all types of hardware.
|
|
46 |
|
|
47 |
OVF package should contain one file with .ovf extension, which is an
|
|
48 |
XML file specifying the following (per virtual machine):
|
|
49 |
|
|
50 |
- virtual disks
|
|
51 |
- network description
|
|
52 |
- list of virtual hardware
|
|
53 |
- operating system, if any
|
|
54 |
|
|
55 |
Each of the elements in .ovf file may, if desired, contain a
|
|
56 |
human-readable description to every piece of information given.
|
|
57 |
|
|
58 |
Additionally, the package may have some disk image files and other
|
|
59 |
additional resources (e.g. ISO images).
|
|
60 |
|
|
61 |
Supported disk formats
|
|
62 |
----------------------
|
|
63 |
|
|
64 |
Although OVF is claimed to support 'any disk format', what we are
|
|
65 |
interested in is which of the formats are supported by VM managers
|
|
66 |
that currently use OVF.
|
|
67 |
|
|
68 |
- VMWare: ``.vmdk`` (which comes in at least 3 different flavours:
|
|
69 |
``sparse``, ``compressed`` and ``streamOptimized``)
|
|
70 |
- VirtualBox: ``.vdi`` (VirtualBox's format), ``.vmdk``, ``.vhd``
|
|
71 |
(Microsoft and XenServer); export disk format is always ``.vmdk``
|
|
72 |
- XenServer: ``.vmdk``, ``.vhd``; export disk format is always
|
|
73 |
``.vhd``
|
|
74 |
- Red Hat Enterprise Virtualization: ``.raw`` (raw disk format),
|
|
75 |
``.cow`` (qemu's ``QCOW2``)
|
|
76 |
- other: AbiCloud, OpenNode Cloud, SUSE Studio, Morfeo Claudia,
|
|
77 |
OpenStack
|
|
78 |
|
|
79 |
In our implementation of the OVF we plan to allow a choice between
|
|
80 |
raw, cow and vmdk disk formats for both import and export. The
|
|
81 |
justification is the following:
|
|
82 |
|
|
83 |
- Raw format is supported as it is the main format of disk images used
|
|
84 |
in Ganeti, thus it is effortless to provide support for this format
|
|
85 |
- Cow is used in Qemu, [TODO: ..why do we support it, again? That is,
|
|
86 |
if we do?]
|
|
87 |
- Vmdk is most commonly supported in virtualization software, it also
|
|
88 |
has the advantage of producing relatively small disk images, which
|
|
89 |
is extremely important advantage when moving instances.
|
|
90 |
|
|
91 |
The conversion between RAW and the other formats will be done using
|
|
92 |
qemu-img, which transforms, among other, raw disk images to monolithic
|
|
93 |
sparse vmdk images.
|
|
94 |
|
|
95 |
|
|
96 |
Planned limitations
|
|
97 |
===================
|
|
98 |
|
|
99 |
The limitations regarding import of the OVF instances generated
|
|
100 |
outside Ganeti will be (in general) the same, as limitations for
|
|
101 |
Ganeti itself. The desired behavior in case of encountering
|
|
102 |
unsupported element will be to ignore this element's tag and inform
|
|
103 |
the user on console output, if possible - without interruption of the
|
|
104 |
import process.
|
|
105 |
|
|
106 |
Package
|
|
107 |
-------
|
|
108 |
|
|
109 |
There are no limitations regarding support for multiple files in
|
|
110 |
package or packing the ovf package into one OVA (Open Virtual
|
|
111 |
Appliance) file. As for certificates and licenses in the package,
|
|
112 |
their support will be under discussion after completion of the basic
|
|
113 |
features implementation.
|
|
114 |
|
|
115 |
Multiple Virtual Systems
|
|
116 |
------------------------
|
|
117 |
|
|
118 |
At first only singular instances (i.e. VirtualSystem, not
|
|
119 |
VirtualSystemCollection) will be supported. In the future multi-tiered
|
|
120 |
appliances containing whole nodes (or even clusters) are considered an
|
|
121 |
option.
|
|
122 |
|
|
123 |
Disks
|
|
124 |
-----
|
|
125 |
|
|
126 |
As mentioned, Ganeti will allow exporting only ``raw``, ``cow`` and
|
|
127 |
``vmdk`` formats. As for import, we will support all that
|
|
128 |
``qemu-img`` can convert to raw format. At this point this means
|
|
129 |
``raw``, ``cow``, ``qcow``, ``qcow2``, ``vmdk`` and ``cloop``. We do
|
|
130 |
not plan for now to support ``vdi`` or ``vhd``.
|
|
131 |
|
|
132 |
We support compression both for import and export - for export this
|
|
133 |
will use ovftools with chosen level of compression. There is also a
|
|
134 |
possibility to provide virtual disk in chunks of equal size.
|
|
135 |
|
|
136 |
When no ``ovf:format`` tag is provided during import, we assume that
|
|
137 |
the disk is to be created on import and proceed accordingly.
|
|
138 |
|
|
139 |
Network
|
|
140 |
-------
|
|
141 |
|
|
142 |
There are no known limitations regarding network support.
|
|
143 |
|
|
144 |
Hardware
|
|
145 |
--------
|
|
146 |
|
|
147 |
TODO
|
|
148 |
|
|
149 |
Operating Systems
|
|
150 |
-----------------
|
|
151 |
|
|
152 |
TODO
|
|
153 |
|
|
154 |
Other
|
|
155 |
-----
|
|
156 |
|
|
157 |
Implementation details
|
|
158 |
======================
|
|
159 |
|
|
160 |
TODO
|
|
161 |
|
|
162 |
.. vim: set textwidth=72 :
|
|
163 |
.. Local Variables:
|
|
164 |
.. mode: rst
|
|
165 |
.. fill-column: 72
|
|
166 |
.. End:
|