[CentOS-devel] The status of our Vagrant images for Hyper-V

Mon Apr 10 14:57:05 UTC 2017
Michael Vermaes <mvermaes at gmail.com>

On Fri, Apr 7, 2017 at 7:51 PM, Laurentiu Pancescu <lpancescu at gmail.com> wrote:

>> We should probably either:
>> - call GNU tar from Image Factory to preserve the sparseness of our image
>> files (and hope that Windows handles them properly)
>> - use VBoxManage to convert to .vhd (VirtualBox is not in our repos, but
>> Oracle offers a .rpm for EL7 systems).
> I would prefer the second option, using VBoxManage to produce small
> non-sparse .VHD images for our Vagrant boxes, and avoid the compatibility
> problems posed by sparse files.  But this would need to be done in Image
> Factory, so it's actually for Ian to decide if using VirtualBox is
> acceptable.

After using qemu-img to convert the qcow2 image to VHD and then
extracting the resulting tar file on the Hyper V host, the resulting
image was back to being 40GB 'non-sparse'.

Using VBoxManage instead, 'vagrant up' time was reduced to be
comparable to the kozo/centos7 box:

centos7-hyperv (original image):             4m19.232s
kozo/centos-7:                                              51.069s
centos7-hyperv (converted with virtualbox): 48.041s

So I would also say the second option is the way to go if possible :)