Page 1 of 1

Question about CloneVDI

Posted: 1. Sep 2013, 04:53
by sisyphus876
I saw where someone created a cloneVDI tool for VirtualBox, and I'm wondering if it could help me out of a bind that I'm in. Here are the details of my problem as I posted yesterday:

viewtopic.php?f=1&t=57137

However, I'm not currently using any VDI files in VirtualBox. My snapshots are all .VMDK files.
Does this tool convert .VMDK to .VDI? Should it solve the problem I'm having? If not, perhaps I could install VMWare and try to run the same .VMDK files there instead? Do I run the most recent snapshot?

I'm in a bind, so your assistance would be greatly appreciated.

Re: Question about CloneVDI

Posted: 1. Sep 2013, 09:07
by mpack
Yes, CloneVDI can read VMDKs - CloneVDI might work for this, there's no way to know except to try it. It doesn't change your existing files (it creates a new one), so it can't do any harm.

If you want the clone to be a merge of a snapshot chain then in CloneVDI you must select the most recent snapshot vmdk as the source file, do not select the base file. If it works then you would build a new VM around the resulting VDI - don't attempt to continue using the old VM with all that snapshot guff still in there.

Might I suggest that in future you avoid snapshots. And, if the data is so critical, keep backups.

Re: Question about CloneVDI

Posted: 1. Sep 2013, 10:06
by sisyphus876
It worked! Thanks so much for creating this mpack.

There I was all this time, thinking that keeping several snapshots and making a copy of all my VirtualBox .vbox and .vmdk files on nightly basis was in fact the prudent thing to do. I even selected the .vmdk format in the first place because I assumed that I could easily port them to VMWare in the even that VirtualBox failed. I was so very wrong on many levels.

I presume that the .vdi file can be backed-up and restored to a new .vbox if necessary? Or must I periodically export the .vdi file to an .ova file and keep that backed-up instead?

Re: Question about CloneVDI

Posted: 1. Sep 2013, 11:08
by mpack
Back up the entire VM, not just the storage element of it. The best way IMHO to make a backup is simply to copy the entire VM folder off to secondary storage. Speaking of which - hopefully you located the new VDI inside the VM folder, so that the whole folder can be treated as one unit. If not then I would take the trouble to move the VDI in there now, because any future advice here will usually assume a standard layout.

To move the VDI: go to File|Virtual Media Manager, find and select the VDI, click Release (disconnects it from the VM), then Remove to unregister it. Answer no when it asks if you want to delete the physical file. Then shut down VirtualBox, move the VDI into the VM folder, restart VBox and use the VM settings Storage session to reattach the disk from its new location.

Re: Question about CloneVDI

Posted: 1. Sep 2013, 11:12
by mpack
Snapshots are a way of preserving multiple working states of the guest. They are quite useless as a backup tool for the host. In fact from the hosts point of view it takes one rather simple file and replaces it with a complex and interdependent arrangment of file fragments. It's quite obvious that this will be less reliable if host errors are possible (and they always are).