Page 2 of 4

Re: CloneVDI tool: Linux part

PostPosted: 13. Aug 2012, 17:34
by paddler
Thanks mpack. Thought I was going to need vboxmanage to do this. "Release" was grayed out in my case, because I had already replaced/"removed" the original .vdi through <Settings - Storage - IDE Controller>. The "Remove" option worked fine though. Vm starts up now without the error message. cheers

Re: CloneVDI tool: Linux part

PostPosted: 4. Sep 2012, 21:50
by flomow
Hey,

I am using clonevdi on CENTOS through wine. Unfortunally I can not compact vdis. Cloning with old and new UUUID works great, but when compacting a vdi the partition table ist always set to none (if i load the new vdi into the programm). I am using vclonecdi not with admin rights (is this a problem)? Sorry but I am not the fittest using linux, please write me what additional info you need!

Thanks, flomow

Re: CloneVDI tool: Linux part

PostPosted: 4. Sep 2012, 22:51
by stefan.becker
You have to check the option, its not checked as default.

Re: CloneVDI tool: Linux part

PostPosted: 4. Sep 2012, 23:06
by flomow
Hey,

flomow wrote:Unfortunally I can not compact vdis. Cloning with old and new UUUID works great, but when compacting a vdi the partition table ist always set to none (if i load the new vdi into the programm).

as written above, the file size is smaller, but the partition table is "gone". BTW: Starting the vm with the "new" vdi results in "no operating system found", etc

stefan.becker wrote:You have to check the option, its not checked as default.

What do you mean with that?

Thanks, flomow

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 10:53
by mpack
flomow wrote:when compacting a vdi the partition table ist always set to none

I can guarantee that CloneVDI is not erasing partition tables - I think others would have noticed that by now. I can think of two strong possibilities, first is that you are cloning the wrong file, e.g. you are cloning the base VDI of a snapshot chain. Second is that you don't have appropriate read or write permission for either the source or destination folders.

I would like to know how you are using CloneVDI - is it under Wine, or are you trying to use in inside a Windows VM while writing to a shared folder?

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 12:59
by flomow
Hey mpack,

thanks for you reply.

I am using it with wine. Yesterday I tried compacting a WinXp-disk 15GB. one partition with ntfs. no snapshot chain. after processing just in clone-mode (new or keep uuuid) and loading the new vdi into clonevdi it shows at the partition-field: ,ntfs like before. After checking the compact option (in both new or keep uuuid) the part-field shows: none. The vdi was not bootable anymore. I tried this with user and root privileges. All the same.

Today I tried the following:

generate a new vdi. Add it to a winxp vm, format it with ntfs add dummy-data 800MB, then remove part of that data 700MB. .

then tried the mentioned above.
Obviosly every thing worked fine.I tried it with other vdis every thing worked fine.

I am sorry, but I dont know where the problem is just with this secial vdi.
I attached some snapshots.

Thanks in advance.

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 15:03
by mpack
Well, the obvious thing that leaps out at me is that there is only one partition defined on that drive, but it isn't defined in the first partition entry as it normally would be. Instead the first partition entry is all zeros, with a start LBA of zero (coincidentally where the partition map is also stored). CloneVDI shouldn't be upset by that, but it's a credible bug (perhaps my earlier guarantee was a bit rash...) : part of the compaction job done by CloneVDI is to discard blocks in unpartitioned areas, and the empty and zero size partition entry at the top of the list may be confusing its identification of "between partitions" areas.

Is there any way you can delete that zero partition to test this idea?

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 16:19
by flomow
Hey,

the problem is that the first zero partition isnt recognized by gparted nor fdisk -l. Its somehoe not there... :x

I'll try to copy the big partition only to another disk using qparted boot-iso.
(or do you have some other suggestion)

flomow

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 16:26
by mpack
flomow wrote:the problem is that the first zero partition isnt recognized by gparted nor fdisk -l. Its somehoe not there... :x

Well, just to be clear: there is no such partition, so of course fdisk/gparted will not list one. My point is that CloneVDI may be confused by the fact that slot 2 in the partition map is defined, while slot 1 has been left blank (as have slots 3 and 4 of course). Added to that is the fact that the first partition is defined to start 2MB into the disk image, which I suspect means that CloneVDI may be considering the first 2MB between slots 1 and 2 as unpartitioned - and therefore discardable from the clone when compacting.

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 16:28
by flomow
What do you suggest to "move" the partition to slot 1?
thanks, flomow

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 16:30
by mpack
flomow wrote:What do you suggest to "move" the partition to slot 1?
thanks, flomow

If your partition manager allows that, then yes if you will.

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 16:57
by flomow
flomow wrote:I'll try to copy the big partition only to another disk using qparted boot-iso.


That worked for me, so far, Compacting works without errors.

Best regards, flomow

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 17:44
by mpack
Sorry, please clarify: are you saying that the operation, which previously did not work, now works on the modified disk which has the same big partition in the first slot of the partition table?

Also (if yes to the above): does the partition still start at LBA 2048?

Re: CloneVDI tool: Linux part

PostPosted: 5. Sep 2012, 20:27
by flomow
Hey, I did the following:

  • Creating a new vdi disk with the same size as the "broken" one
  • Adding it to the WinXP-VM
  • Booting with a qpartesd live image
  • Writing the partitiontalbe to sdb
  • copying sda1 to sdb
  • set the boot flag to sdb1
  • shutdown
  • compactig it with clone vdi

Note: CloneVDI said now "NTFS" instead of",NTFS" in the partitions-field.

Screenshots attached.

Flomow

Re: CloneVDI tool: Linux part

PostPosted: 6. Sep 2012, 12:19
by mpack
Thanks for the info, that gives me a lot to go on. I'll have a look at the code this weekend.