Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why does vagrant use vmdk disk format as its standard package format?

I have a MacBook Air and space is a premium. I have a vagrant instance which has been growing in size from 2 GB to 8 GB.

I was looking at options for reducing the disk size found a few tutorials for VDI, but the actual file is a .vmdk file. Unfortunately, the tool to manage vmdk files is a commercially licensed tool from VMware.

Why does vagrant use the vmdk format as its default packaging format?

Is there a way to configure the vagrantfile and force it to use vdi instead of vmdk?

like image 525
Senthil Nayagam Avatar asked Aug 19 '13 06:08

Senthil Nayagam


People also ask

What is VMDK file in VirtualBox?

VMDK (short for Virtual Machine Disk) is a file format that describes containers for virtual hard disk drives to be used in virtual machines like VMware Workstation or VirtualBox.

What is VMDK file?

vmdk file - This is the actual raw disk file that is created for each virtual hard drive. Almost all of a . vmdk file's content is the virtual machine's data, with a small portion allotted to virtual machine overhead. This file will be roughly the same size as your virtual hard drive.


1 Answers

Simple answer is no.

VirtualBox only supports exporting images as OVF/OVA.

Vagrant 1.0.x base boxes are basically tar files of the VirtualBox exports. It changed a little bit in 1.1.x and 1.2+.

Anyway, technically you should still be able to convert the VMDK to VDI but you will have to re-attach it to the existing VM or create a new one using it, e.g.: VBoxManage clonehd in.vmdk out.vdi --format VDI

Refer to http://docs.vagrantup.com/v2/boxes/format.html

In the past, boxes were just tar files of VirtualBox exports. With Vagrant supporting multiple providers, box files are now tar files where the contents differ for each provider. They are still tar files, but they may now optionally be gzipped as well.

Box files made for Vagrant 1.0.x and VirtualBox continue to work with Vagrant 1.1+ and the VirtualBox provider.

like image 88
Terry Wang Avatar answered Oct 17 '22 05:10

Terry Wang