LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Cannot create VirtualBox hd image - VBoxManage: error: Failed to create hard disk (https://www.linuxquestions.org/questions/linux-software-2/cannot-create-virtualbox-hd-image-vboxmanage-error-failed-to-create-hard-disk-4175444853/)

Vanyel 01-09-2013 01:37 PM

Cannot create VirtualBox hd image - VBoxManage: error: Failed to create hard disk
 
Code:

VBoxManage createhd --filename hard_drive --size 6144 --format VDI --variant Split2G
0%...
Progress state: VBOX_E_FILE_ERROR
VBoxManage: error: Failed to create hard disk
VBoxManage: error: Could not create the medium storage unit 'hard_drive.vdi' (VERR_VD_INVALID_TYPE)
VBoxManage: error: Details: code VBOX_E_FILE_ERROR (0x80bb0004), component Medium, interface IMedium
VBoxManage: error: Context: "int handleCreateHardDisk(HandlerArg*)" at line 423 of file VBoxManageDisk.cpp

This is actually a SOLUTION and not a problem, as I spent a few hours this morning wondering why this was failing and could not google anything that gave me an answer.

You can't use the Split2G variant with a .VDI format. You need to use another (I chose .VHD). The error message is rather uninformative and didn't point to the answer. I hope this helps someone else to a quick resolution.

Vanyel 01-10-2013 09:06 AM

addendum
 
I caught later that, while .VHD format stops the errors and creates a disk file, you need to choose .VMDK to accomplish what I wanted, the Split2G.


All times are GMT -5. The time now is 11:20 PM.