Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm using Virtualbox on a macosx host and unfortunately my hosted system, a linux mint installation, has run out of space. I thought it was dynamic but evidently it is not. It is a vdi filesystem.

In any case, how can i unerstand if a vobx vdi partition is dynamic or not? I searched out on the internet, mostrly on vbox website, but could not find any valuable information.

Also, in case it is not dynamic, is there a way to turn a fixed partition into a dynamic allocated one? (also some non-orthodox system as copying content of the partition is fine to me)

share|improve this question
    
So with the "Dynamic" or thin provisioning, the guest sees the full space you allocated when you created it, but it only consumes the space on the host when you actually put data there. With "Fixed" or thick provisioning, the guest consumes the full amount immediately even if it hasn't written any data. Either way, it sounds like you didn't allocate enough maximum space (thin or thick). The good news is that it's not hard to expand a disk using virtualbox, though you will have to go to the command line. –  khaki54 Jun 5 '13 at 14:11
    
wow, great! Can you provide information about how to reallocate space in the answer? Thanks. –  Daniele B Jun 5 '13 at 14:26
    
I did a little search and I found out that what you say can be done via VBoxManage modifyhd IMAGENAME.vdi --resize SIZE but wher I run it on my box it looks like the resize option does not exist... I'm working on a macosx with version 3.2.14 –  Daniele B Jun 5 '13 at 14:48
    
Version 3.2.x is pretty old. You should probably upgrade first before messing with any of this. –  khaki54 Jun 5 '13 at 15:05
    
great, I updated my vbox and it partially worked: the max size is now 20 GB but it does not grow... any hint about how to make it grow dynamically? –  Daniele B Jun 5 '13 at 15:56

1 Answer 1

up vote 3 down vote accepted

How to check to see if virtual hard drive is "dynamic(thin)" or "fixed(thick)":

  • File --> Virtual Media Manager
  • Select the Hard Drive in question
  • Check storage details in info panel

How to convert clone a fixed virtual hard drive to dynamic:

  • You can't convert the image currently, but you can clone a new one then remove the old.
  • VBoxManage clonehd [old.VDI] [new.VDI] --variant Standard
  • You will have to detatch the old and attach the new in your VM properties.

How to expand a dynamic hard drive max size if it is full:

  • VBoxManage modifyhd IMAGENAME.vdi --resize SIZE Size is an integer in MB

How to expand hard drive partition within Linux OS after expanding .vdi:

  • apt-get update && apt-get install gparted
  • unmount the affected partition umount [mountpoint]
  • open gparted, select the partition in question and choose resize/move and expand it to the end of the unallocated space.
  • NOTE: you may have to boot your vm into a GParted live cd to make the change if you are expanding a partition that you can't unmount first such as /, you can get one here: http://gparted.sourceforge.net/livecd.php
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.