VirtualBox

Opened 15 years ago

Closed 15 years ago

#4080 closed defect (fixed)

Unable to clone VHD images => fixed in svn

Reported by: Alex Tran Owned by:
Component: other Version: VirtualBox 2.2.2
Keywords: clonehd clonevdi VHD Cc:
Guest type: other Host type: Windows

Description

When I use the clonehd command to clone a VHD image, it errors with the following:

VBoxManage.exe clonehd IE7.vhd IE7-cloned.vhd --format VHD
VirtualBox Command Line Management Interface Version 2.2.2
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.

0%...FAILED
Error: failed to clone hard disk. Error message: Could not create the clone hard
 disk 'IE7-cloned.vhd' (VERR_INVALID_PARAMETER)

The VHD image is Microsoft's VirtualPC image of IE7. I am trying to clone it in order to get a new UUID so that I can also use the IE8 image in VirtualBox. Right now both images share the same UUID so I am only able to use one of them.

I am creating this ticket based on a recommendation from the forums.

Change History (9)

comment:1 by DavidS, 15 years ago

I got the identical error message with:

VBoxManage clonehd fn1.vhd fn2.vhd or VBoxManage clonehd fn1.vhd fn2.vdi --format VDI

For additional reports of the same bug, see http://forums.virtualbox.org/viewtopic.php?f=6&t=17481.

comment:2 by Frank Mehnert, 15 years ago

Reproduced.

comment:3 by Frank Mehnert, 15 years ago

Should be fixed in 2.2.4. However, the .vhd backend is currently not able to omit writing empty blocks with the result that the target .vhd will be blown to the full final size. In the case of the MS IE7 .vhd this is 16GB. For the moment I suggest you to copy the .vhd and assign a new UUID to the target. VBoxManage internalcommands sethduuid works for .vhd images since VirtualBox 2.2.4.

comment:4 by aeichner, 15 years ago

Summary: Unable to clone VHD imagesUnable to clone VHD images => fixed in svn

clonehd should be fixed in svn now.

comment:5 by romkyns, 15 years ago

This exact error is still happening for me in 2.2.4, using the same command as in the original report.

comment:6 by Alex Tran, 15 years ago

I just tested it with 2.2.4 and it appears to have been fixed. I tested it with the IE7 VHD from the site linked to in the original post. But as noted by frank in the comments, the file size is huge so it is recommended to use the VBoxManage internalcommands sethduuid command.

The is the better solution IMHO. Just copy the VHD and change the UUID. Repeat for as many copies as you need.

comment:7 by romkyns, 15 years ago

I'm sorry, I should have been more specific.

I was attempting to convert my own .VHD drive, not the IE7 image. My drive is a 64 GB dynamic VHD with 18 GB of actual data (=file size as seen by host os).

Both of the commands mentioned in the first post by DavidS (which I confused with the original report) fail on this drive:

  • "VBoxManage clonehd fn1.vhd fn2.vdi --format VDI"
  • "VBoxManage clonehd fn1.vhd fn2.vhd --format VHD"

VirtualBox Command Line Management Interface Version 2.2.4 (C) 2005-2009 Sun Microsystems, Inc. All rights reserved.

0%...FAILED Error: failed to clone hard disk. Error message: Could not create the clone hard disk 'fn2.vhd' (VERR_INVALID_PARAMETER)

comment:8 by romkyns, 15 years ago

I'm sorry, I should have been more specific.

I was attempting to convert my own .VHD drive, not the IE7 image. My drive is a 64 GB dynamic VHD with 18 GB of actual data (=file size as seen by host os).

Both of the commands mentioned in the first post by DavidS (which I confused with the original report) fail on this drive:

- "VBoxManage clonehd fn1.vhd fn2.vdi --format VDI"
- "VBoxManage clonehd fn1.vhd fn2.vhd --format VHD"
VirtualBox Command Line Management Interface Version 2.2.4
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.

0%...FAILED
Error: failed to clone hard disk. Error message: Could not create the clone hard disk 'fn2.vhd' (VERR_INVALID_PARAMETER)

[sorry for not previewing the first time round!....]

comment:9 by Sander van Leeuwen, 15 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use