Screwed up a VirtualBox VM resize
-
- 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
So that created a 60GB img file. Took forever lol. Now to see if I can get at a Windows PC and use cloneVDI or try that winebottler thing.
-
- 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
Hurrah, that worked! I have it all working again.
However, CloneVDI does not have a function to reduce the size of the drive from 60GB down.
However, CloneVDI does not have a function to reduce the size of the drive from 60GB down.
-
- Site Moderator
- Posts: 39134
- 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
Congratulations.
If you tried to shrink the drive, rather than compact it, then its certainly true that CloneVDI does not allow that.
You mean, other than the "Compact" option??omro wrote:However, CloneVDI does not have a function to reduce the size of the drive from 60GB down.
If you tried to shrink the drive, rather than compact it, then its certainly true that CloneVDI does not allow that.
-
- 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
That's what I tried to do all along that resulted in this issue in the first place lol
I wanted to prevent my drive expanding towards the 60gb size originally set.
However, I'm glad that it's working again and I really appreciate all your help getting me to that point!
I wanted to prevent my drive expanding towards the 60gb size originally set.
However, I'm glad that it's working again and I really appreciate all your help getting me to that point!
-
- Site Moderator
- Posts: 39134
- 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
You can shrink the partition size using gparted, down to some number - lets say 32GB. You musn't shrink it so much that the partition becomes congested - no more than half full. You then clone with CloneVDI, with the "compact" option enabled. This causes any data, on the drive but stored outside the partition, to be discarded. The drive will still be a 60GB drive, but from then onwards the host file cannot grow any larger than the internal partition allows.omro wrote:I wanted to prevent my drive expanding towards the 60gb size originally set.
-
- 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
Awesome information, great to know.
So far the VM seems to work ok, though for some reason a few glitches seem to be occurring. When I run internet explorer (the vm is an XP install) some of the graphics files file to load and some sites are a little corrupt looking. I'm wondering if the DD didn't copy the old drive entirely accurately.
So far the VM seems to work ok, though for some reason a few glitches seem to be occurring. When I run internet explorer (the vm is an XP install) some of the graphics files file to load and some sites are a little corrupt looking. I'm wondering if the DD didn't copy the old drive entirely accurately.
-
- Site Moderator
- Posts: 39134
- 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
Running chkdsk/f on the drive, from inside the guest, is probably a good idea anyway.
-
- 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
Did that and it doesn't help.
I attempted to use clonezilla to recreate the image, just out of curiosity, but it created an image file that lists as having a corrupt ntfs partition table which I can't fix.
All in all, it's not perfect, but it's better than having lost all my data and the application that I needed still runs, so I'm happy enough about that.
I attempted to use clonezilla to recreate the image, just out of curiosity, but it created an image file that lists as having a corrupt ntfs partition table which I can't fix.
All in all, it's not perfect, but it's better than having lost all my data and the application that I needed still runs, so I'm happy enough about that.
-
- 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
I'm going to keep the original vm and if the resize option ever allows you to decrease the size of the VDi I can restore from there.
I'm guessing no one knows if or when this might happen.
I'm guessing no one knows if or when this might happen.
-
- Site Moderator
- Posts: 39134
- 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
I guessing it will never happen, given how catastrophic the results could be in the wrong hands. There are very good reasons why neither CloneVDI nor VBoxManage allows that.omro wrote:I'm going to keep the original vm and if the resize option ever allows you to decrease the size of the VDi I can restore from there.
I'm guessing no one knows if or when this might happen.
-
- 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
Ah well, thanks for all your help!
Re: Screwed up a VirtualBox VM resize
I hope it's not necrobumping for me to say thanks for this information. Years later, and searching didn't find any better way for me to deal with this. I got the correct values to use by creating a new empty vdi file of the desired size, The hex editor (qhexedit on Gentoo Linux) claimed it couldn't save the file, but it did save it fine - it just quit after deleting the original but before renaming the temporary saved file to the proper name. I just renamed it, and was good to go.mpack wrote:...
Run the hex editor, .... Move the cursor to offset 0x170 (hex 170, decimal 368). Edit the 8 bytes starting from that offset so that they are "00 00 00 00 05 00 00 00". Next move to offset 0x180 (hex 180, decimal 384). Edit the 4 bytes starting from that offset so that they are "00 50 00 00".
-
- Site Moderator
- Posts: 39134
- 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
Hmm. Or you could have just ran the CloneVDI repair function, a feature it's had for a couple of years now.