Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1415
  • Last Modified:

How to resize Virtual Box VM

I have a new iMac. It has a 250 gig SSD drive and a one TB sata drive.

There is a Windows 7 VM installed on this iMac, using Virtual Box.  I need to resize the hard drive space of this VM.  It currently is allotted 20 gigs and only has one gig left.  

Thank You.
0
PCGalOfCal
Asked:
PCGalOfCal
  • 18
  • 11
  • 2
  • +1
2 Solutions
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
Edit the Virtual Machine disk, and increase the size,  and then use a third party application as described in my EE Article to Expand the OS inside the VM.


HOW TO:  Resize a VMware (VMDK) Virtual Disk
0
 
PCGalOfCalAuthor Commented:
I'm using Virtual Box.  Does this still apply because I see how to edit the VM disk and increase the size.
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
Yes the procedure is the same, edit the disk and resize the OS partition.
0
Restore individual SQL databases with ease

Veeam Explorer for Microsoft SQL Server delivers an easy-to-use, wizard-driven interface for restoring your databases from a backup. No expert SQL background required. Web interface provides a complete view of all available SQL databases to simplify the recovery of lost database

 
PCGalOfCalAuthor Commented:
I'm sorry.  I don't get it.  First you said "Edit the Virtual Machine disk, and increase the size" AND THEN use third party software to do the rest, correct?  If correct, I don't know how to do step one which is "Edit the Virtual Machine disk, and increase the size".
Thank You.
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
see this article for command line options to resize the disk

http://trivialproof.blogspot.co.uk/2011/01/resizing-virtualbox-virtual-hard-disk.html

edit options not made it in the release version yet!
0
 
PCGalOfCalAuthor Commented:
Please help.... What am I doing wrong.  Syntax error, why???

daryls-imac:snapshots darylwesterback$ vboxmanage modifyhd modifyhd win\ 7,\ 64\ bit\ via\ mac\ os\ x.vdi --resize 75000
Oracle VM VirtualBox Command Line Management Interface Version 4.1.18
(C) 2005-2012 Oracle Corporation
All rights reserved.

Usage:

VBoxManage modifyhd         <uuid>|<filename>
                            [--type normal|writethrough|immutable|shareable|
                                    readonly|multiattach]
                            [--autoreset on|off]
                            [--compact]
                            [--resize <megabytes>|--resizebyte <bytes>]


Syntax error: Invalid parameter 'win 7, 64 bit via mac os x.vdi'
daryls-imac:snapshots darylwesterback$
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
probably does not like the filename you have specified

try surrounding the filename in quotes
0
 
PCGalOfCalAuthor Commented:
same thing
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
what syntax are you using?
0
 
PCGalOfCalAuthor Commented:
ok, so I cloned the VM and renamed the clone to win7 (to make to name very simple).  I deleted the original VM and verified the new one opens with no issues.   I've been going all day at this, :(.  Do you know of any good Mac forums (just a thought)?  So here is my latest error...

Last login: Sat Aug 18 17:39:53 on ttys000
daryls-imac:~ darylwesterback$ cd virualbox\ vms
-bash: cd: virualbox vms: No such file or directory
daryls-imac:~ darylwesterback$ cd virtualbox \vms
-bash: cd: virtualbox: No such file or directory
daryls-imac:~ darylwesterback$ cd \virtualbox/ vms
-bash: cd: virtualbox/: No such file or directory
daryls-imac:~ darylwesterback$ cd
daryls-imac:~ darylwesterback$ cd virtualbox\ vms
daryls-imac:virtualbox vms darylwesterback$ cd win7
daryls-imac:win7 darylwesterback$ vboxmanage modifyhd win7.vdi --resize 65000
VBoxManage: error: Cannot register the hard disk '/Users/darylwesterback/VirtualBox VMs/Win7/win7.vdi' {c8ba0ab1-5edf-4b26-8f39-6d1433096a40} because a hard disk '/Users/darylwesterback/VirtualBox VMs/Win7/Win7.vdi' with UUID {c8ba0ab1-5edf-4b26-8f39-6d1433096a40} already exists
VBoxManage: error: Details: code NS_ERROR_INVALID_ARG (0x80070057), component VirtualBox, interface IVirtualBox, callee nsISupports
Context: "OpenMedium(Bstr(pszFilenameOrUuid).raw(), enmDevType, AccessMode_ReadWrite, fForceNewUuidOnOpen, pMedium.asOutParam())" at line 210 of file VBoxManageDisk.cpp
daryls-imac:win7 darylwesterback$
0
 
PCGalOfCalAuthor Commented:
UUID already exists error.  Any last thoughts?
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
maye because its already registered with the vm
0
 
PCGalOfCalAuthor Commented:
Ok, forget that.  I'm starting over.  So now I'm trying to create a new VM. But, the problem I'm having now is with changing the default location that the VM is installed to.  It automatically puts it on the small SSD drive, or drive 0.  I need it to go to the 2 TB Sata drive, or secondary drive, drive 1.  I already changed the location of the user home folder to the secondary drive thinking that Virtualbox would then automatically put it in the user home folder but it didn't.  :(  Any idea how to change the default location when creating the VM?  I only did the first easy step in creating the new VM. I did not actually install the OS yet so it's no big deal to try again.  

Thanks for sticking with me.
0
 
PCGalOfCalAuthor Commented:
I think I got it.
0
 
rogerorenCommented:
You have a chance to say where the virtual disk is when you set it up, just watch for hard disk image location, and change it to where you want.

Resizing the hard drive is a two step process.
Tell Virtual box to resize the drive (will go through the procedure)
Tell Windows to use all the space (have to use disk management to resize the partition to the new drive size)

I've done it, but I don't remember all the steps, sorry.
0
 
PCGalOfCalAuthor Commented:
OMG, I don't like Virtualbox!  I've used parallels and that was soooo easy.  I'm installing vmware fusion.   I'll just make it a VM software learning WEEK, UGH!  And the drama continues... I installed a new VM using vmware.  Install went fine but I obviously missed a critical option.  Most everything is in a different language.  My icons on the desktop are in English but if I click on the start icon, the entire list is in some foreign language.  I can't navigate because I can't read it, lol.
0
 
PCGalOfCalAuthor Commented:
HERES THE ANSWER....
Cause
This issue can occur if you select Easy Install when creating the virtual machine when using a Windows 7 OEM install DVD that came with your PC.

Note:  OEM discs are not supported as valid install media for virtual machines.  They are created to be installed on the hardware they came with.  For more information, see Support for OEM Windows installations (1012881).

Resolution
To resolve this issue, do not use Easy Install when installing Windows. During the install process for Fusion, deselect Use Easy Install. When you do not use Easy Install, the Windows installer prompts you for the license key, language preferences, user names, and passwords. For Workstation, you must create a custom virtual machine. See the information below for details.

This issue can also be resolved by creating a custom virtual machine. For more information, see:

    Fusion: Creating a custom virtual machine in Fusion (1013810)
    Workstation: Select I will install the operating system later when on the Guest Operating System Installation screen.
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
Correct OEM software should never be installed on Virtual Machines. (however that does not stop, the virtual disk being resized!)

Original Equipment Manufacturers (OEM) versions

Note: Physical-to-virtual hard drive migration of a Windows installation is a valid function for customers with Software Assurance and full retail copies of Windows XP, Windows Vista, and Windows 7. Software Assurance provides users valuable benefits—please contact Microsoft Corporation for further information. Windows XP, Windows Vista and Windows 7 installed by Original Equipment Manufacturers (OEM) using OEM versions of these products may not be transferred to a virtual hard drive in accordance with Microsoft licensing terms.

Source
http://technet.microsoft.com/en-us/sysinternals/ee656415

http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Windows/XP/A_3721-Can-I-transfer-my-OEM-version-of-Windows-to-another-PC.html
0
 
PCGalOfCalAuthor Commented:
I gave up on resizing a long time ago.  Hanccoka, you mentioned vmware in your original post.  On a scale of 1 to 10, how would you rank vmware over virtual box???
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
15 if I was at a PC, otherwise I would recommend Parallels over VMware Fusion! Performance is much better, and most Mac users prefer Parallels to VMware Fusion.

VMware Player 4.0 Free Download
http://downloads.vmware.com/d/info/desktop_end_user_computing/vmware_player/4_0

VMware Workstation 8.0 (60 day trial, $199)
http://downloads.vmware.com/d/info/desktop_end_user_computing/vmware_workstation/8_0
0
 
PCGalOfCalAuthor Commented:
I love Parallels.  Client told me his industry software wouldn't work on Parallels. I don't think I believe that but anyway...  Do you know why I can't give my new vm install (vmware) a larger drive space than 60 gigs???  I'm at the "where do you want to install windows" option.  Normally you can adjust the drive space here but it thinks there is only 60 gigs available when there is really 800 gigs left.
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
maybe the size of the virtual machine disk, you've created is 60GB?
0
 
PCGalOfCalAuthor Commented:
never saw such an option.
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
if you complete an easy installation you'll not, you will need to create a manual setup of the VM.
0
 
PCGalOfCalAuthor Commented:
It defaulted to 60 gigs.  But, there was a point where I could have clicked on one of about 10 icons (the hard drive icon) and changed it from 60 gig  to whatever.  So here I go again.  Drum roll please!
0
 
PCGalOfCalAuthor Commented:
Have you heard of any software that doesn't run on Parallels but does run on both vmware and vbox?
0
 
Andrew Hancock (VMware vExpert / EE MVE^2)VMware and Virtualization ConsultantCommented:
Yes, newer 3D Graphical applications, because VMware and Virtualbox, have recent 3D graphic support. But it will only be a matter of time, for Parallels to get a fix.
0
 
serialbandCommented:
Here's a reason for the error you got from VBoxManage:

http://muffinresearch.co.uk/archives/2009/07/23/virtualbox-error-cannot-register-the-hard-disk/

If that doesn't fix the problem try the VirtualBox Instructions here:

http://www.my-guides.net/en/content/view/122/26/

It has the screen captures of the first few steps instead of just the word descriptions, maybe that will work easier.  Which version of VirtualBox are you running?  Do you know which version of VirtualBox was used to create the VDI?  You may have to follow the pre-4.0 instructions, which should still work for the 4.0+ versions.
0
 
PCGalOfCalAuthor Commented:
I'm sorry  serialband but I've had so many issues that I'm not totally sure which problem your solution is referring to.  I haven't even posted all my issues with VBOX and I'm trying to move forward but THANK YOU for your post. VBOX version is 4.1.18. and it was originally created only a couple mouths ago.   I gave up on the resizing issue and reinstalled.  Then to my disappointment I ran into the usb device issue.  It's a pain to have to deal with the filter tool and it doesn't really seem to work anyway.  Very BUGGY.  One usb device will show up and another will not.  I will never recommend VBOX to anyone except to those that can afford to loose a lot of hair . VBox, is not user friendly in my opinion.  But hey, free is free, right?  After a couple of days of playing with VM software I have learned a lot.  I personally would use VBox in a pinch but I would never recommend it to a client.
0
 
PCGalOfCalAuthor Commented:
I should have a final post tomorrow.  I've installed VMware and so far so good!  Thanks to all that gave input.  :)
0
 
serialbandCommented:
If VMWare works for you then that's the way to go.

I manage a mix of VirtualBox and VMWare images and I have repartitioned a few VMware disk images several times which were quite easy to do.  I haven't  had any issues, so far, with any VirtualBox images that I've created either.


Well it's moot now, but I was referring to the post where you had the "VBoxManage: error: Cannot register the hard disk"  The solution provided in the link was to use the full path to the disk image.

I ran VBoxManage on my Mac to resize 2 images, and it ran without producing an error.  I happen to run the command as root.  Maybe that makes a difference.  I didn't actually repartition the drives with gparted yet.

I also noticed in your comment that you have vboxmanage modifyhd win7.vdi --resize 65000 in lower case instead of mixed case as your error message showed.  Did you type that in instead of cut and pasting?
0
 
PCGalOfCalAuthor Commented:
Thanks for all your posts.  My solution in this case was to use VMWare.  :)
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

  • 18
  • 11
  • 2
  • +1
Tackle projects and never again get stuck behind a technical roadblock.
Join Now