Typical workflow for the import is very simple:
-- read the ``.ovf`` file info memory
+- read the ``.ovf`` file into memory
- verify manifest
- parse each element of the configuration file: name, disk template,
hypervisor, operating system, backend parameters, network and disks
- save gathered information in ``config.ini`` file
+Export
+------
+
+Similar to import, export functionality also uses two classes -
+OVFWriter and OVFExporter.
+
+OVFWriter class produces XML output based on the information given. Its
+sole role is to separate the creation of ``.ovf`` file content.
+
+OVFExporter class gathers information from ``config.ini`` file or
+command line and performs necessary operations like disk conversion, disk
+compression, manifest creation and OVA package creation.
+
+Typical workflow for the export is even simpler, than for the import:
+
+- read the ``config.ini`` file into memory
+- gather information about certain parts of the instance, convert and
+ compress disks if desired
+- save each of these elements as a fragment of XML tree
+- save the XML tree as ``.ovf`` file
+- create manifest file and fill it with appropriate checksums
+- if ``--ova`` option was chosen, pack the results into ``.ova`` tarfile
+
.. vim: set textwidth=72 :
.. Local Variables:
gnt-instance import -n node1.xen xen.test.i1
+
+Export example
+==============
+
+Exporting instance into ``.ovf`` format is pretty streightforward and
+requires little - if any - explanation. The only compulsory detail is
+the required disk format, provided using the ``--format`` option.
+
+Export to another Ganeti instance
+---------------------------------
+If for some reason it is convenient for you to use ``ovfconverter`` to
+move instance between clusters (e.g. because of the disk compression),
+the complete example of export may look like this::
+
+ gnt-backup export -n node1.xen xen.test.i1
+ [...]
+ ovfconverter export --format=vmdk --ova \
+ /srv/ganeti/export/xen.i1.node1.xen/config.ini
+ [...]
+
+The result is then in
+``/srv/ganeti/export/xen.i1.node1.xen/xen.test.i1.ova``
+
+Export to Virtualbox/VMWare/other external tool
+-----------------------------------------------
+Typically, when exporting to external tool we do not want
+Ganeti-specific configuration to be saved. In that case, simply use the
+``--external`` option::
+
+ gnt-backup export -n node1.xen xen.test.i1
+ [...]
+ ovfconverter export --external --output-dir ~/ganeti-instance/ \
+ /srv/ganeti/export/xen.i1.node1.xen/config.ini
+
+
+Known issues
+============
+
+Export
+------
+When exporting to **VirtualBox**, you may encounter errors regarding
+network. If that is the case, simply change the network type in options
+to ``NAT``.
+
+
.. vim: set textwidth=72 :
.. Local Variables:
.. mode: rst