DrvVD_DiskFull

Discussions related to using VirtualBox on Linux hosts.
Post Reply
RNone
Posts: 2
Joined: 25. Aug 2021, 00:24

DrvVD_DiskFull

Post by RNone »

I have a guest where the 'VirtualBox VMs'/guestname folder is a mounted block device with a ~200K of free space. If the guest (Fedora 34) is created on a host (Fedora 33) with a fixed storage VDI and snapshots are not being used, why would the VM be suspended with VD#1 Host disk full and DrvVD_DiskFull error? Am I wrong to assume that a fixed storage VDI should never ever increase in size on it's own?
scottgus1
Site Moderator
Posts: 20965
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: DrvVD_DiskFull

Post by scottgus1 »

RNone wrote:Am I wrong to assume that a fixed storage VDI should never ever increase in size on it's own?
I have to parse this sentence a bit to sort out the double negatives.... :lol:

No, you're not wrong, and a fixed drive will not increase in size on its own. Actually a dynamic disk doesn't either. The dynamic disk has a target storage size and will increase its file size on the host disk over time as needed until the target size is reached. The fixed disk will appropriate all its host disk space at first creation. Neither will get bigger than the target size, plus a couple MB overhead.

A dynamic disk's target size can be made bigger. See How to Resize a Drive. A fixed disk cannot be increased, but it can be cloned to a bigger disk.

There may be the slightest theoretical hint of speed increase (maybe) if a fixed disk is used on a host platter drive, since all the disk sectors are preallocated on a host drive. And since a fixed disk does not get bigger one can be sure of not running out of host disk space because the disk file is overprovisioned. But a host SSD moots all objections of fragmenting in dynamic drives, and careful husbandry of disk sizes will help keep the host disk from running out of space, making dynamic the choice to use in almost all situations.
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: DrvVD_DiskFull

Post by mpack »

RNone wrote:why would the VM be suspended with VD#1 Host disk full and DrvVD_DiskFull error?
VirtualBox will alert a user about the disk full condition some time before the point of catastrophic failure. I don't know exactly what the safe margin is, but I'd be surprised if it's less than 200K.

If you're that short of host space then don't use fixed size drives! Then VMs will use no more space than they need. There are very few good reasons to use fixed sized drives, e.g. they are usually slower, not faster, because noobs always make them too small and congested. The one thing they do is guarantee that you can't consume additional disk space on the host, since the host allocation is fixed. Better however IMO to buy a bigger host drive.
RNone
Posts: 2
Joined: 25. Aug 2021, 00:24

Re: DrvVD_DiskFull

Post by RNone »

As you pointed out a fixed size VDI "guarantee that you can't consume additional disk space on the host", yet a disk full error message is being generated anyway. Without the use of snapshots, the amount of free space in the mounted encrypted container is more than enough for the files in the Logs directory and the vbox configuration files. Before the guest was suspended the file system space it sees was only 50% used - so space within the VDI is no where near being all used.
I tried using dynamic disk and they are even worse for running out of space when guests are in fixed size encryption containers (a dynamic disk with a maximum defined size of 65 GB created a 95 GB vdi file). At this point I consider this to be a virtualbox defect as it should not be possible for a fixed size VDI to run out of space on the host. If a guest uses all the space provided by a VDI, that's a guest issue and should not result in a suspended guest.
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: DrvVD_DiskFull

Post by mpack »

RNone wrote:... yet a disk full error message is being generated anyway.
Yes, I covered that. VirtualBox produces this error when the host partition is almost full. It doesn't matter that the drive is fixed: there is no real difference between fixed and dynamc VDI, the only real difference is that one gets preallocated space and the other gets allocation on demand, so it doesn't surprise me that VirtualBox takes little account of their difference.

You could raise a BugTracker ticket for this, the fix is probably trivial so it might get done. Or the devs might regard it as too niche. Who knows. The ticket should point out that any drive which is already fully allocated (whether originally fixed or dynamic) can't overflow the host partition and so this error should be suppressed.
Post Reply