You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by Nux! <nu...@li.nux.ro> on 2014/04/02 23:54:13 UTC

Converting QCOW2 to VHD

Hello,

I have used qemu-img to successfully convert a qcow2 image to vpc (vhd, 
these names give me head aches). I do have a problem with these 
converted images, XenServer complains that they were not created by 
itself and refuses to resize them for example.
Can anyone advise if there is another way of converting qcow2 to vhd 
without having Xenserver complaining? Vhd-util binary is missing the 
"convert" functionality.

Lucian

-- 
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro

Re: Converting QCOW2 to VHD

Posted by Nux! <nu...@li.nux.ro>.
On 03.04.2014 17:48, Rohit Yadav wrote:
> To add, I've this patched vhd-util that has convert. For some reason 
> my
> apache login and the web dir including the vhd-util file is not 
> accessible:
> people.apache.org/~bhaisaab/vhd-util-patched
> 
> This is the google cache:
> http://webcache.googleusercontent.com/search?q=cache:vZPgSRlk9LwJ:people.apache.org/~bhaisaab/vhd-util-patched/+&cd=1&hl=en&ct=clnk&gl=in
> 
> Here is a link from my blog which can help you while working with vhds 
> for
> xen:
> http://blogs.citrix.com/2012/10/04/convert-a-raw-image-to-xenserver-vhd/
> 

Thanks, I've seen that in the past. Was hoping something simpler 
happened in the meantime. :)

-- 
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro

Re: Converting QCOW2 to VHD

Posted by Rohit Yadav <bh...@apache.org>.
To add, I've this patched vhd-util that has convert. For some reason my
apache login and the web dir including the vhd-util file is not accessible:
people.apache.org/~bhaisaab/vhd-util-patched

This is the google cache:
http://webcache.googleusercontent.com/search?q=cache:vZPgSRlk9LwJ:people.apache.org/~bhaisaab/vhd-util-patched/+&cd=1&hl=en&ct=clnk&gl=in

Here is a link from my blog which can help you while working with vhds for
xen:
http://blogs.citrix.com/2012/10/04/convert-a-raw-image-to-xenserver-vhd/

Cheers.



On Thu, Apr 3, 2014 at 10:13 PM, Rohit Yadav <bh...@apache.org> wrote:

> Hi Lucian,
>
> Yes you can and we've been hacking like that with systemvms [1]. Here's
> how you may do it using:
>
> - Packer: http://www.packer.io
> - Hack you own using vboxmanage, qemu, vhd-utils etc. and work on raw hdd
> image, checkout the code marked here:
> https://github.com/apache/cloudstack/blob/master/tools/appliance/build.sh#L80-L99
>
> [1]
> https://github.com/apache/cloudstack/blob/master/tools/appliance/build.sh
>
> Hope this helps.
>
>
> On Thu, Apr 3, 2014 at 3:24 AM, Nux! <nu...@li.nux.ro> wrote:
>
>> Hello,
>>
>> I have used qemu-img to successfully convert a qcow2 image to vpc (vhd,
>> these names give me head aches). I do have a problem with these converted
>> images, XenServer complains that they were not created by itself and
>> refuses to resize them for example.
>> Can anyone advise if there is another way of converting qcow2 to vhd
>> without having Xenserver complaining? Vhd-util binary is missing the
>> "convert" functionality.
>>
>> Lucian
>>
>> --
>> Sent from the Delta quadrant using Borg technology!
>>
>> Nux!
>> www.nux.ro
>>
>
>

Re: Converting QCOW2 to VHD

Posted by Nux! <nu...@li.nux.ro>.
On 03.04.2014 17:43, Rohit Yadav wrote:
> Hi Lucian,
> 
> Yes you can and we've been hacking like that with systemvms [1]. 
> Here's how
> you may do it using:
> 
> - Packer: http://www.packer.io
> - Hack you own using vboxmanage, qemu, vhd-utils etc. and work on raw 
> hdd
> image, checkout the code marked here:
> https://github.com/apache/cloudstack/blob/master/tools/appliance/build.sh#L80-L99
> 
> [1]
> https://github.com/apache/cloudstack/blob/master/tools/appliance/build.sh
> 
> Hope this helps.

I think it does, thanks. I was hoping more for a miracle from vhd-util 
though, something nice and clean.
I guess that would have to do.

-- 
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro

Re: Converting QCOW2 to VHD

Posted by Rohit Yadav <bh...@apache.org>.
Hi Lucian,

Yes you can and we've been hacking like that with systemvms [1]. Here's how
you may do it using:

- Packer: http://www.packer.io
- Hack you own using vboxmanage, qemu, vhd-utils etc. and work on raw hdd
image, checkout the code marked here:
https://github.com/apache/cloudstack/blob/master/tools/appliance/build.sh#L80-L99

[1]
https://github.com/apache/cloudstack/blob/master/tools/appliance/build.sh

Hope this helps.


On Thu, Apr 3, 2014 at 3:24 AM, Nux! <nu...@li.nux.ro> wrote:

> Hello,
>
> I have used qemu-img to successfully convert a qcow2 image to vpc (vhd,
> these names give me head aches). I do have a problem with these converted
> images, XenServer complains that they were not created by itself and
> refuses to resize them for example.
> Can anyone advise if there is another way of converting qcow2 to vhd
> without having Xenserver complaining? Vhd-util binary is missing the
> "convert" functionality.
>
> Lucian
>
> --
> Sent from the Delta quadrant using Borg technology!
>
> Nux!
> www.nux.ro
>

Re: Converting QCOW2 to VHD

Posted by Marcus <sh...@gmail.com>.
I've only ever gone the other way, but I know there's some
documentation lingering around about a two-step process for converting
to vhd.

On Wed, Apr 2, 2014 at 3:54 PM, Nux! <nu...@li.nux.ro> wrote:
> Hello,
>
> I have used qemu-img to successfully convert a qcow2 image to vpc (vhd,
> these names give me head aches). I do have a problem with these converted
> images, XenServer complains that they were not created by itself and refuses
> to resize them for example.
> Can anyone advise if there is another way of converting qcow2 to vhd without
> having Xenserver complaining? Vhd-util binary is missing the "convert"
> functionality.
>
> Lucian
>
> --
> Sent from the Delta quadrant using Borg technology!
>
> Nux!
> www.nux.ro