OVF format support

1,415 views
Skip to first unread message

John Lund

unread,
Feb 29, 2012, 12:21:11 AM2/29/12
to kiwi, matt.sc...@emc.com
Hello everyone,

I'm trying to use our existing kiwi config.xml to build a kiwi vmx
type image with the output in the OVF format. I'm getting an error
that says: Not enough or Missing OFV config data.

I looked for an example OVF configuration to test with, but don't see
one. Is there a kiwi sample that generates an ovf, that I can test
with? (I am using r5.0.2.14)

Also is there any updated documentation for using the ovf output
feature? Is there some OVF config data that should be included in the
config.xml (I checked the current kiwi pdf, and didn't see anything in
the vmx image section about any ovf settings)

Thank you,
John Lund
john...@emc.com

Marcus Schäfer

unread,
Feb 29, 2012, 3:26:45 AM2/29/12
to kiwi-...@googlegroups.com, matt.sc...@emc.com
Hi John,

> I'm trying to use our existing kiwi config.xml to build a kiwi vmx
> type image with the output in the OVF format. I'm getting an error
> that says: Not enough or Missing OFV config data.

yep the ovftype is missing in your machine section. The plan is
to support ofv's suitable for zvm povervm xen and vmware. I guess
you want your ovf to run on VMware's virtualization architecture ?
In that case take a look at the section below:

<machine memory="512" guestOS="suse" HWversion="4" ovftype="vmware">
<vmdisk controller="scsi" id="0"/>
<vmnic driver="e1000" interface="0" mode="bridged"/>
</machine>

> I looked for an example OVF configuration to test with, but don't see
> one. Is there a kiwi sample that generates an ovf, that I can test
> with? (I am using r5.0.2.14)

Basically it's all controlled by the contents of the machine section
and what's new is the ovftype.

> Also is there any updated documentation for using the ovf output
> feature? Is there some OVF config data that should be included in the
> config.xml (I checked the current kiwi pdf, and didn't see anything in
> the vmx image section about any ovf settings)

I'm afraid I did a bad job documenting this and I'm pretty sure the
ovf support currently implemented is far away from being complete. It would
be great to receive some feedback if the result is acceptable or if there
are urgently missing parts. the ovf spec is like the cim spec, you can
define everything and nothing there and each virtualization architecture
evaluates it differently.

If kiwi's ovf did not work correctly for you there is still the
binary only ovftool from VMware which allows you to convert a vmdk image
produced by kiwi into an ovf. But that would be a solution for the
VMware virtualization architecture only

In any case it would be great to receive some feedback here
because my feeling tells me there is some work still not done in
that area

Thanks

Regards,
Marcus
--
Public Key available
gpg --keyserver gpg-keyserver.de --recv-keys 0xCCE3C6A2
-------------------------------------------------------
Marcus Schäfer (Res. & Dev.) SUSE LINUX Products GmbH
Tel: 0911-740 53 0 Maxfeldstrasse 5
FAX: 0911-740 53 479 D-90409 Nürnberg
GF: Jeff Hawn,Jennifer Guild, Felix Imendörffer
HRB: 21284 (AG Nürnberg) Germany
http://www.suse.de
-------------------------------------------------------

natcho....@emc.com

unread,
Mar 13, 2012, 12:02:43 PM3/13/12
to kiwi-...@googlegroups.com, matt.sc...@emc.com
Hi Marcus et all,

Getting the same error that John reported (kiwi 5.02.18):

...
Mar-12 23:19:08 <1> : Starting vmx image machine configuration
Mar-12 23:19:08 <1> : Creating image OVF configuration file...
skipped
Mar-12 23:19:08 <2> : Not enough or Missing OFV config data
skipped
...

Here is a copy of the preferences section in config.xml:
...
<preferences>
<type image="vmx" primary="true" filesystem="ext3" boot="vmxboot/suse-SLES11" format="ovf">
<machine memory="1024" ncpus="1" guestOS="suse" HWversion="4" ovftype="vmware">


<vmdisk controller="scsi" id="0"/>

<vmnic driver="vmxnet3" interface="0" mode="bridged"/>
</machine>
</type>
<version>1.0.0</version>
<packagemanager>zypper</packagemanager>
<rpm-check-signatures>false</rpm-check-signatures>
<rpm-force>true</rpm-force>
<locale>en_US</locale>
<keytable>us.map.gz</keytable>
</preferences>
....

Any ideas about what is wrong or how to debug?

Also, it would be nice if kiwi gave some indication about what is missing :-).

Thanks,
Natcho

Marcus Schäfer

unread,
Mar 13, 2012, 1:05:16 PM3/13/12
to kiwi-...@googlegroups.com, matt.sc...@emc.com
Hi,

> Getting the same error that John reported (kiwi 5.02.18):
>
> ...
> Mar-12 23:19:08 <1> : Starting vmx image machine configuration
> Mar-12 23:19:08 <1> : Creating image OVF configuration file...
> skipped
> Mar-12 23:19:08 <2> : Not enough or Missing OFV config data
> skipped
> ...
>
> Here is a copy of the preferences section in config.xml:
> ...
> <preferences>
> <type image="vmx" primary="true" filesystem="ext3" boot="vmxboot/suse-SLES11" format="ovf">
> <machine memory="1024" ncpus="1" guestOS="suse" HWversion="4" ovftype="vmware">
> <vmdisk controller="scsi" id="0"/>
> <vmnic driver="vmxnet3" interface="0" mode="bridged"/>
> </machine>
> </type>

Hmm, this one worked here for me. I just cut&pasted it

> Any ideas about what is wrong or how to debug?

not at the moment



> Also, it would be nice if kiwi gave some indication about what is missing :-).

yes it's a bad message, will make it more useful

Marcus Schäfer

unread,
Mar 14, 2012, 4:56:53 AM3/14/12
to kiwi-...@googlegroups.com, matt.sc...@emc.com
Hi,

> Also, it would be nice if kiwi gave some indication about what is missing :-).

I 'fixed' the messages and also added a "for me" working example
to examples/suse-12.1/suse-vm-guest (kiwi-doc package or git source)

natcho....@emc.com

unread,
Mar 14, 2012, 11:27:32 AM3/14/12
to kiwi-...@googlegroups.com, matt.sc...@emc.com
Thanks Marcus,

I will test how the new version works.

But I guess something was messed up on my build system ... even though it failed a number of times before I sent my previous e-mail, I also cannot reproduce this right now ...

Thanks again,
N.

-----Original Message-----
From: kiwi-...@googlegroups.com [mailto:kiwi-...@googlegroups.com] On Behalf Of Marcus Schäfer
Sent: Wednesday, March 14, 2012 4:57 AM
To: kiwi-...@googlegroups.com
Cc: Schmaelzle, Matt
Subject: Re: [kiwi] OVF format support

natcho....@emc.com

unread,
Mar 15, 2012, 6:37:35 PM3/15/12
to kiwi-...@googlegroups.com
Hi Marcus,
 
I am continuing to test OVF builds and I noticed that the OVF file generated by kiwi 5.02.18 is malformed - the Envelope properties xmlns:rasd and xmlns:vssd are split in two lines with an extra quote ("):
 
<?xml version="1.0" encoding="UTF-8"?>
<Envelope vmw:buildId="build-260188"
wbem/wscim/1/cim-schema/2/CIM_ResourceAllocationSettingData"
wbem/wscim/1/cim-schema/2/CIM_VirtualSystemSettingData"
<ovf:References>
        <ovf:File ovf:href="test.x86_64-1.1.2.ovf"
        ovf:id="file1"
        ovf:size="770572288"/>
</ovf:References>
<ovf:DiskSection>
        <ovf:Info>Disk Section</ovf:Info>
        <ovf:Disk ovf:capacity="770572288" ovf:capacityAllocationUnits="byte" ovf:diskId="vmRef1disk" ovf:fileRef="file1" ovf:format="http://www.vmware.com/interfaces/specifications/vmdk.html#streamOptimized" ovf:populatedSize="770572288"/>
</ovf:DiskSection>
<VirtualSystem ovf:id="vm">
        <Info>A virtual machine</Info>
        <Name>test.x86_64-1.1.2.ovf</Name>
        <OperatingSystemSection ovf:id="84" vmw:osType="">
                <Info>Appliance created by KIWI</Info>
        </OperatingSystemSection>
        <VirtualHardwareSection>
                <Info>Virtual hardware requirements</Info>
                <System>
                <vssd:ElementName>Virtual Hardware Family</vssd:ElementName>
                <vssd:InstanceID>0</vssd:InstanceID>
                <vssd:VirtualSystemIdentifier>Bourne.x86_64-1.1.2.ovf</vssd:VirtualSystemIdentifier>
                <vssd:VirtualSystemType>vmx-04</vssd:VirtualSystemType>
                </System>
        </VirtualHardwareSection>
        </VirtualSystem>
</Envelope>
 
After applying the following patch, I was able to deploy the resulting OVF:
 
diff -Naur KIWIImageFormat.pm.orig KIWIImageFormat.pm
--- KIWIImageFormat.pm.orig  2012-03-15 21:55:32.000000000 +0000
+++ KIWIImageFormat.pm  2012-03-15 21:55:00.000000000 +0000
@@ -1056,10 +1056,10 @@
                'xmlns="http://schemas.dmtf.org/ovf/envelope/1"'."\n".
                'xmlns:cim="http://schemas.dmtf.org/wbem/wscim/1/common"'."\n".
                'xmlns:ovf="http://schemas.dmtf.org/ovf/envelope/1"'."\n".
-               'xmlns:rasd="http://schemas.dmtf.org/'.
+               'xmlns:rasd="http://schemas.dmtf.org/"'."\n".
                'wbem/wscim/1/cim-schema/2/CIM_ResourceAllocationSettingData"'."\n".
                'xmlns:vmw="http://www.vmware.com/schema/ovf"'."\n".
-               'xmlns:vssd="http://schemas.dmtf.org/'.
+               'xmlns:vssd="http://schemas.dmtf.org/"'."\n".
                'wbem/wscim/1/cim-schema/2/CIM_VirtualSystemSettingData"'."\n".
                'xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">'."\n";
        #==========================================
 
Thanks,
N.
 
-----Original Message-----
From: kiwi-...@googlegroups.com [mailto:kiwi-...@googlegroups.com] On Behalf Of Marcus Schäfer
Sent: Wednesday, March 14, 2012 4:57 AM
To: kiwi-...@googlegroups.com
Cc: Schmaelzle, Matt
Subject: Re: [kiwi] OVF format support
 

natcho....@emc.com

unread,
Mar 15, 2012, 9:34:36 PM3/15/12
to kiwi-...@googlegroups.com

Hi all,

 

I also tried building in OVA format, the build succeeded, but when I attempted to import it into ESX, the server complained: Did not find OVF file at the beginning of OVA archive.

 

Based on http://www.vmware.com/pdf/ovf_spec_draft.pdf:

“OVF restricts the TAR format in that duplication is not allowed within the archive, and furthermore requires that the TAR implementation guarantee that the following three files will be placed at the front of the archive, in specified order:

1. .ovf descriptor file

2. .mf manifest file (optional)

3. .cert certificate (optional)”

 

tar -tf out/test.x86_64-1.1.2.ova

./

./test.x86_64-1.1.2.mf

./test.x86_64-1.1.2.ovf

./test.x86_64-1.1.2.vmdk

 

So, seems that the order of the mf and ovf files needs to be adjusted to follow the OVF spec draft.

 

Thanks,

N.

Marcus Schäfer

unread,
Mar 16, 2012, 5:04:09 AM3/16/12
to kiwi-...@googlegroups.com
Hi,

> I am continuing to test OVF builds and I noticed that the OVF file
> generated by kiwi 5.02.18 is malformed - the Envelope properties
> xmlns:rasd and xmlns:vssd are split in two lines with an extra quote
> ("):

Thanks much for your investigations and the patch in that area.
I opened bugzilla:

https://bugzilla.novell.com/show_bug.cgi?id=752580
https://bugzilla.novell.com/show_bug.cgi?id=752581

to track this. I will include your ovf patch today with the new
release. The ova stuff seems to be a bit more work.

Thanks again for the doc references that's really much appreciated

Reply all
Reply to author
Forward
0 new messages