Screwed up a VirtualBox VM resize

This is for discussing general topics about how to use VirtualBox.
omro
Posts: 26
Joined: 15. Jan 2012, 22:03
Primary OS: Mac OS X other
VBox Version: OSE other
Guest OSses: Windows XP

Re: Screwed up a VirtualBox VM resize

Post by omro »

So I opened the hex editor and I am a little lost! I can't see the elements you say to edit.
Attachments
Clipboard03.gif
Clipboard03.gif (70.65 KiB) Viewed 6667 times
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Screwed up a VirtualBox VM resize

Post by mpack »

The status line (bottom left) tells you the current offset. Try moving the cursor around. I can't make it any simpler I'm afraid.

ps. I see that this disk is a CloneVDI clone. Whyever did you elect to use a VBoxManage command line to resize the disk when you had access to CloneVDI?
omro
Posts: 26
Joined: 15. Jan 2012, 22:03
Primary OS: Mac OS X other
VBox Version: OSE other
Guest OSses: Windows XP

Re: Screwed up a VirtualBox VM resize

Post by omro »

Because the Clone was done using my work's windows PC and the resize was done on my mac at home.
omro
Posts: 26
Joined: 15. Jan 2012, 22:03
Primary OS: Mac OS X other
VBox Version: OSE other
Guest OSses: Windows XP

Re: Screwed up a VirtualBox VM resize

Post by omro »

So, just to confirm

Hex 170 = 00
Hex 171 = 00
Hex 172 = 00
Hex 173 = 00
Hex 174 = 05
Hex 175 = 00
Hex 176 = 00
Hex 177 = 00
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Screwed up a VirtualBox VM resize

Post by mpack »

Correct, but I'll warn you now: I tend to get quite tetchy when asked to restate a point I think I made quite clearly at the first attempt!

If you have the backup I warned you to make then there's no need to be this nervous: get on with it! :)

ps. CloneVDI can be used on a Mac host if you install Wine / Winebottler. Details in the CloneVDI discussion thread, no doubt you can find it in google.
omro
Posts: 26
Joined: 15. Jan 2012, 22:03
Primary OS: Mac OS X other
VBox Version: OSE other
Guest OSses: Windows XP

Re: Screwed up a VirtualBox VM resize

Post by omro »

Sadly this did not work :-(
Result Code:
VBOX_E_IPRT_ERROR (0x80BB0005)
Component:
Medium
Interface:
IMedium {53f9cc0c-e0fd-40a5-a404-a7a5272082cd}
Callee:
IVirtualBox {c28be65f-1a8f-43b4-81f1-eb60cb516e66}
Attachments
Clipboard04.gif
Clipboard04.gif (15.77 KiB) Viewed 6659 times
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Screwed up a VirtualBox VM resize

Post by mpack »

Hmm. The hex editor method should have been quite straightforward: I'm not sure what could have messed it up, other than failing to use the "Open Partially" feature. What you could do is open the first 10000 bytes again using "Open Partially", then "Save as" something.bin, and post the zipped bin here - that way I can check your work.

If you really can't get this fix to work then its back to one of the earlier suggestions I'm afraid.
omro
Posts: 26
Joined: 15. Jan 2012, 22:03
Primary OS: Mac OS X other
VBox Version: OSE other
Guest OSses: Windows XP

Re: Screwed up a VirtualBox VM resize

Post by omro »

Definitely partially open, the screenshot shows that.

I'll definitely give the other options a try. Thanks!
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: Screwed up a VirtualBox VM resize

Post by Perryg »

Just wondering but you said that you cloned this off your work machine. Can't you just get another clone?
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Screwed up a VirtualBox VM resize

Post by mpack »

omro wrote:Definitely partially open, the screenshot shows that
Does it? Is that what the 'P' stands for? I've never noticed that before!
omro
Posts: 26
Joined: 15. Jan 2012, 22:03
Primary OS: Mac OS X other
VBox Version: OSE other
Guest OSses: Windows XP

Re: Screwed up a VirtualBox VM resize

Post by omro »

Perryg wrote:Just wondering but you said that you cloned this off your work machine. Can't you just get another clone?
Don't have access to this machine for a while :-(
omro
Posts: 26
Joined: 15. Jan 2012, 22:03
Primary OS: Mac OS X other
VBox Version: OSE other
Guest OSses: Windows XP

Re: Screwed up a VirtualBox VM resize

Post by omro »

OK,

So I created a new Linux Mint VM and attached the damaged VDI as a drive and when I boot into Mint, this shows up and I can access it.

When I tried dding, it fails.
Attachments
Clipboard05.gif
Clipboard05.gif (10.18 KiB) Viewed 6650 times
omro
Posts: 26
Joined: 15. Jan 2012, 22:03
Primary OS: Mac OS X other
VBox Version: OSE other
Guest OSses: Windows XP

Re: Screwed up a VirtualBox VM resize

Post by omro »

ok, I fixed that by unmounting the drive and going via /dev/sdb1 instead

Is the img file the raw file mentioned earlier?
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Screwed up a VirtualBox VM resize

Post by mpack »

Yes, img file, raw file, is the same thing. At least in this context. Just be aware that the trick of turning a partition image into a disk image is AFAIK unique to CloneVDI. E.g. if you try it with VBoxManage it will seem to work but the result will be garbage (boot tracks missing, and nor can you fix them because no space was allocated for them).
omro
Posts: 26
Joined: 15. Jan 2012, 22:03
Primary OS: Mac OS X other
VBox Version: OSE other
Guest OSses: Windows XP

Re: Screwed up a VirtualBox VM resize

Post by omro »

Still waiting for the image file to be created, so will update when it's created.
Post Reply