I have an iMac Core i5 host computer, 1TB Hard drive, 8GB Memory.
I have created a Virtual Box VM to run Fedora 14 64bit with a 200 GB Dynamically allocated hard drive.
Virtual Box version 4.1.6 r74713
I have tried twice to import a 40+ GB database sql file and I keep running out of hard drive space.
Each time I've tried this my VM's hard drive stops expanding at ~50 GB.
df -h
output:
/dev/mapper/VolGroup-lv_root
50G 47G 96M 100% /
tmpfs 981M 260K 981M 1% /dev/shm
/dev/sda1 485M 30M 430M 7% /boot
/dev/mapper/VolGroup-lv_home
144G 213M 136G 1% /home
ds 931G 169G 763G 19% /media/sf_ds
ds 931G 169G 763G 19% /var/www/site-example.org
I have plenty of space on the host computer (800+ GB)
Virtual Box reports the actual size of the disk is 46.88 GB
Any ideas on why Virtual Box stops expanding the disk and how to fix it?
Update
I've run GParted on the VM and it says all 200 GB are used even though df -h
doesn't report that.
Best Answer
You assigned most of the space on your virtual disk to your LVM
/dev/mapper/VolGroup-lv_home
volume. Now you're trying to import your database into a file that is (most likely) not located in your home directory.So the space from your
root
volume is used. That volume is only 50G in size.You need to resize your LVM volumes.
I would assume that you chose to have your home directories in a separate partition during the installation of Fedora.
Given that you only use 1% of the free space in that partition and given that you're running out of space on your root partition, that choice might not have been optimal.
You're going to want to use
lvresize
to shrink your home volume and grow your root volume. If you have no experience with that tool, there seem to be plenty of guides online. Like this one: LVM Resizing Guide.