Hi,
I have Virtualbox 5.0.2 installed under Windows 7 professional 64bit, and I created an Ubuntu server 15.04 guest under it and all things works fine but recently the free space available under the VDI HDD (4Gb) started to become smaller day by day and I decided to expand it to 10Gb, and since it is a fixed VDI HDD, the process is diferent from dynamic one, so, I searched forum by forum to find a solution for the problem resulted by the resizing process, here is what I did:
Via VB disks manager, I created a new fixed VDI HDD 10Gb, since, I wanted that the final HDD will be fixed type also as the original due to performance needs. Then, I copied the original HDD to the new one with:
VBoxMange clonehd ./original_HDD.vdi ./expanded_HDD.vdi --existing
I attached the new HDD to the VB machine and booted with a gparted live CD. With gparted, I can see that the HDD volume was increased, I then resized the extended partition to fit the entire unllocated space, see first screen shoot, I applied the changes, and did the same to the logical partition inside the parent extended one.
Now, I can see that the partition was expanded and its data is still intactes. The problem is when I boot to the guest HDD, the fdisk shows the same as gparted, but, the df -h command tells that no change was applied to partition size, see 2nd and third screen shoot, and since than the free available space remains intacte as before, I am so confuzed and stressed, any help please?
Sorry, the screen shoots are not visible because, I am newer here and to post images, I should past one day and have posted one post before.
Resizing a fixed vdi hdd
-
noteirak
- Site Moderator
- Posts: 5231
- Joined: 13. Jan 2012, 11:14
- Primary OS: Debian other
- VBox Version: OSE Debian
- Guest OSses: Debian, Win 2k8, Win 7
- Contact:
Re: Resizing a fixed vdi hdd
Fixed size VDI will NOT perform better than a dynamic one. The data allocation is simply done at a different time. I can only very strongly advise you to not use fixed size VDI.
That being said, you still need to resize your file system to occupy the new partition size. Once you've done that, you'll see the extended space reflected in df -h.
That being said, you still need to resize your file system to occupy the new partition size. Once you've done that, you'll see the extended space reflected in df -h.
Hyperbox - Virtual Infrastructure Manager - https://apps.kamax.lu/hyperbox/
Manage your VirtualBox infrastructure the free way!
Manage your VirtualBox infrastructure the free way!
-
mpack
- Site Moderator
- Posts: 39134
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Mostly XP
Re: Resizing a fixed vdi hdd
In fact it will usually perform worse, despite all the untested assumptions and myths floating around.noteirak wrote:Fixed size VDI will NOT perform better than a dynamic one.
The classic mistake - as in this topic - is to go for a fixed size drive and make it way too small because you are worried about hogging host disk space. Result? Performance is FAR worse due to congestion than would have been the case if you chose a dynamic disk and let it find its own working size. I mean, a 64bit server with a 10GB drive? I mean come on now...