From: px@jack.fr.eu.org
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] ovf duplicate AddressOnParent
Date: Wed, 2 Dec 2020 14:50:51 +0100 [thread overview]
Message-ID: <a22cf741-c1b6-309f-eecc-2149d4c23d45@jack.fr.eu.org> (raw)
Hello,
We are moving VMs from vmware to proxmox
The process follows:
- export the VM using ovftool
- import using qm importovf
We are facing an issue on multi-disk VM: all the disks are attached as
scsi0 (which fails, and abort the process)
From /usr/share/perl5/PVE/CLI/qm.pm, that value came from
PVE::QemuServer::OVF::parse_ovf
And from /usr/share/perl5/PVE/QemuServer/OVF.pm, that value came from
rasd:AddressOnParent, from the OVF file
And indeed, in the OVF file:
<Item>
<rasd:AddressOnParent>0</rasd:AddressOnParent>
<rasd:ElementName>Hard disk 1</rasd:ElementName>
<rasd:HostResource>ovf:/disk/vmdisk1</rasd:HostResource>
<rasd:InstanceID>11</rasd:InstanceID>
<rasd:Parent>5</rasd:Parent>
<rasd:ResourceType>17</rasd:ResourceType>
<vmw:Config ovf:required="false" vmw:key="backing.writeThrough"
vmw:value="false"/>
</Item>
<Item>
<rasd:AddressOnParent>0</rasd:AddressOnParent>
<rasd:ElementName>Hard disk 2</rasd:ElementName>
<rasd:HostResource>ovf:/disk/vmdisk2</rasd:HostResource>
<rasd:InstanceID>12</rasd:InstanceID>
<rasd:Parent>4</rasd:Parent>
<rasd:ResourceType>17</rasd:ResourceType>
<vmw:Config ovf:required="false" vmw:key="backing.writeThrough"
vmw:value="false"/>
</Item>
-> both disk has the same AddressOnParent, 0, because they do not share
the same Parent (respectively 5 and 4)
Parents are, according to the OVF's spec, "The InstanceID of the parent
controller"
So now, what should we do ?
I wonder if we could simply increment that number for each disk found,
in the loop: first disk gets scsi0, second gets scsi1 etc
Thanks
next reply other threads:[~2020-12-02 14:00 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-02 13:50 px [this message]
2020-12-03 7:36 ` Dominic Jäger
2020-12-21 15:32 ` alexandre derumier
2020-12-21 15:45 ` Thomas Lamprecht
2020-12-21 17:04 ` alexandre derumier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a22cf741-c1b6-309f-eecc-2149d4c23d45@jack.fr.eu.org \
--to=px@jack.fr.eu.org \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox