Need help cloning HD not located in ~/.VirtualBox
Posted: 26. Jan 2009, 03:22
Home directories on are a network server. Keeping virtual machine drive images there would be very slow.
Created a local directory (/vm/vb) for these images.
Created the "New" drive image there when the VM was created. Also change the snapshot location to be in a subdirectory (/vm/vb/VW2K).
Installed Win2K and configured lots of stuff. Want to now clone it for use, so I never have to install Windows again!
I have tries 3 ways, and it appears that VirtualBox insists on disk images being kept in ~/.VirtualBox.
Is there a way that I can keep the images where I want them, and clone them when and where I want them, and move them around? Or as a fallback, simply respecify the one "magic" location to move it out of ~/.VirtualBox?
Thanks.
--Ray
[Try #1] Naively assume that "filename" means a typical UNIX filename, that will be interpreted relative to the current directory:
cd /vm/vb
VBoxManage clonehd VW2K32G.1.0.vdi VW2K32G.1.1.vdi -remember
Fails:
VirtualBox Command Line Management Interface Version 2.1.2
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.
[!] FAILED calling a->virtualBox->OpenHardDisk2(src, srcDisk.asOutParam()) at line 369!
[!] Primary RC = VBOX_E_IPRT_ERROR (0x80BB0005) - Runtime subsystem error
[!] Full error info present: true , basic error info present: true
[!] Result Code = VBOX_E_IPRT_ERROR (0x80BB0005) - Runtime subsystem error
[!] Text = Could not get the storage format of the hard disk '/home/jennifer/.VirtualBox/HardDisks/VW2K32G.Base.1.0.vdi' (VERR_FILE_NOT_FOUND)
[!] Component = HardDisk2, Interface: IHardDisk2, {ed6e2525-c2fd-42a4-917a-7a9045ac9e15}
[!] Callee = IVirtualBox, {339abca2-f47a-4302-87f5-7bc324e6bbde}
[Try #2] Try a full path, pointing it to the source disk image since it appears to be assuming that filenames are in ~/.VirtualBox:
VBoxManage clonehd /vm/vb/VW2K32G.Base.1.0.vdi /vb/vm/VW2K32G.Base.1.1.vdi -remember
Fails saying that it cannot create the target directory. /vm is owned by root, mode 755, /vm/vb is owned by root, mode 777:
VirtualBox Command Line Management Interface Version 2.1.2
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.
0%...FAILED
Error: failed to clone hard disk. Error message: Could not create the directory '/vb/vm' (VERR_ACCESS_DENIED)
[Try #3] Use full paths everywhere:
VBoxManage clonehd /vm/vb/VW2K32G.Base.1.0.vdi /vb/vm/VW2K32G.Base.1.1.vdi -remember
Fails, again saying that it cannot create /vb/vm:
VirtualBox Command Line Management Interface Version 2.1.2
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.
0%...FAILED
Error: failed to clone hard disk. Error message: Could not create the directory '/vb/vm' (VERR_ACCESS_DENIED)
Created a local directory (/vm/vb) for these images.
Created the "New" drive image there when the VM was created. Also change the snapshot location to be in a subdirectory (/vm/vb/VW2K).
Installed Win2K and configured lots of stuff. Want to now clone it for use, so I never have to install Windows again!
I have tries 3 ways, and it appears that VirtualBox insists on disk images being kept in ~/.VirtualBox.
Is there a way that I can keep the images where I want them, and clone them when and where I want them, and move them around? Or as a fallback, simply respecify the one "magic" location to move it out of ~/.VirtualBox?
Thanks.
--Ray
[Try #1] Naively assume that "filename" means a typical UNIX filename, that will be interpreted relative to the current directory:
cd /vm/vb
VBoxManage clonehd VW2K32G.1.0.vdi VW2K32G.1.1.vdi -remember
Fails:
VirtualBox Command Line Management Interface Version 2.1.2
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.
[!] FAILED calling a->virtualBox->OpenHardDisk2(src, srcDisk.asOutParam()) at line 369!
[!] Primary RC = VBOX_E_IPRT_ERROR (0x80BB0005) - Runtime subsystem error
[!] Full error info present: true , basic error info present: true
[!] Result Code = VBOX_E_IPRT_ERROR (0x80BB0005) - Runtime subsystem error
[!] Text = Could not get the storage format of the hard disk '/home/jennifer/.VirtualBox/HardDisks/VW2K32G.Base.1.0.vdi' (VERR_FILE_NOT_FOUND)
[!] Component = HardDisk2, Interface: IHardDisk2, {ed6e2525-c2fd-42a4-917a-7a9045ac9e15}
[!] Callee = IVirtualBox, {339abca2-f47a-4302-87f5-7bc324e6bbde}
[Try #2] Try a full path, pointing it to the source disk image since it appears to be assuming that filenames are in ~/.VirtualBox:
VBoxManage clonehd /vm/vb/VW2K32G.Base.1.0.vdi /vb/vm/VW2K32G.Base.1.1.vdi -remember
Fails saying that it cannot create the target directory. /vm is owned by root, mode 755, /vm/vb is owned by root, mode 777:
VirtualBox Command Line Management Interface Version 2.1.2
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.
0%...FAILED
Error: failed to clone hard disk. Error message: Could not create the directory '/vb/vm' (VERR_ACCESS_DENIED)
[Try #3] Use full paths everywhere:
VBoxManage clonehd /vm/vb/VW2K32G.Base.1.0.vdi /vb/vm/VW2K32G.Base.1.1.vdi -remember
Fails, again saying that it cannot create /vb/vm:
VirtualBox Command Line Management Interface Version 2.1.2
(C) 2005-2009 Sun Microsystems, Inc.
All rights reserved.
0%...FAILED
Error: failed to clone hard disk. Error message: Could not create the directory '/vb/vm' (VERR_ACCESS_DENIED)