I have worked with guests wich have vdi virtual disks of fixed size, till now.
For hardware limitations on the host I would like to create a Kubuntu guest machine using dynamically allocated vdi. I have tried such solution, plus enabling LVM during Kubuntu installation.
With such solution I have experienced relevant performance decrease, compared with the previous fixed size one (same linux distro release, same resource configs except for the vdi).
I am wondering if I followed a correct procedure or if dynamic vdi + guest LVM is a redundant approach (maybe solely dynamic vdi suffice?).
My host specs:
* Intel i5 5300U
* RAM 16GB DDR3
* SSD mSATA 238GB
Dynamically sized disk
-
- Site Moderator
- Posts: 39134
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: Dynamically sized disk
If "fixed size" means "fixed size VDI" then VDI is VDI, there is no average performance difference, I don't know why anyone would expect one. The only difference is when the work of allocation is done. So yes, if the disk grows (because software is creating lots of new files in new areas of the disk) then that might be extra overhead at that instant in time, but that can't keep happening because the disk still has a size limit. Plus even that assumes a mechanical hdd. No way you see any difference at all on an SSD.
Frankly, the most likely reason for the apparant performance difference is: you expect to see one, so it's a reverse placebo effect.
Frankly, the most likely reason for the apparant performance difference is: you expect to see one, so it's a reverse placebo effect.
Re: Dynamically sized disk
No placebo at all: the guest OS (with dynamically sized VDI) really run slowly, compared to the "fixed size VDI" one.mpack wrote:If "fixed size" means "fixed size VDI" then VDI is VDI, there is no average performance difference, I don't know why anyone would expect one. The only difference is when the work of allocation is done. So yes, if the disk grows (because software is creating lots of new files in new areas of the disk) then that might be extra overhead at that instant in time, but that can't keep happening because the disk still has a size limit. Plus even that assumes a mechanical hdd. No way you see any difference at all on an SSD.
Frankly, the most likely reason for the apparant performance difference is: you expect to see one, so it's a reverse placebo effect.
Probably the reason could be due to
don't know how often such event may happens, considering the incremental grow of cache in some softwares like Firefox or Chrome, for instance.if the disk grows (because software is creating lots of new files in new areas of the disk) then that might be extra overhead at that instant in time
The real question is: Does dynamically sized VDI suffice? Do I have to enable LVM during guest OS installation (or it is an optional additional feature)?
-
- Site Moderator
- Posts: 39134
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: Dynamically sized disk
LVM has nothing to do with this. The guest OS sees the same disk with the same capacity the entire time. It literally has no way to tell the difference: it is oblivious to the details of when host resources are allocated.korda wrote:Do I have to enable LVM during guest OS installation (or it is an optional additional feature)?
Re: Dynamically sized disk
Ok... I thought that the overhead issue maybe could be due to such a cumulative effect.mpack wrote:LVM has nothing to do with this. The guest OS sees the same disk with the same capacity the entire time. It literally has no way to tell the difference: it is oblivious to the details of when host resources are allocated.korda wrote:Do I have to enable LVM during guest OS installation (or it is an optional additional feature)?
In summary I have no need of LVM. I suppose.
I will try wirh a guest without it (btw: mSATA seem to perform worse than "classic" SATA3)
-
- Volunteer
- Posts: 5677
- Joined: 14. Feb 2019, 03:06
- Primary OS: Mac OS X other
- VBox Version: PUEL
- Guest OSses: Linux, Windows 10, ...
- Location: Germany
Re: Dynamically sized disk
In Linux, LVM is often used to realize hard disk encryption in software, which will influence the disk I/O performance. You're probably comparing apples to oranges.
If you want a fair comparison, create two new VMs, one with a fixed VDI and one with a dynamic VDI, and install the same guest OS in both without LVM.
If you want a fair comparison, create two new VMs, one with a fixed VDI and one with a dynamic VDI, and install the same guest OS in both without LVM.
-
- Site Moderator
- Posts: 39134
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: Dynamically sized disk
If I was you I would let VirtualBox use template defaults for everything except VM RAM, graphics RAM, CPU cores (make it 2). Other things would not be the default if there were better choices.korda wrote: I will try with a guest without it (btw: mSATA seem to perform worse than "classic" SATA3)
For example, your disk I/O performance is mainly a product of host disk I/O performance. Playing with disk controllers is just messing around in the statistical noise.
Re: Dynamically sized disk
In my case I would adopt LVM for dynamic allocation of partitions, not for encryption purposes. So, it seems to me a fuzzy comparison indeed.fth0 wrote:In Linux, LVM is often used to realize hard disk encryption in software, which will influence the disk I/O performance. You're probably comparing apples to oranges.
If you want a fair comparison, create two new VMs, one with a fixed VDI and one with a dynamic VDI, and install the same guest OS in both without LVM.
Anyway I have tested "dynamic" vdi without LVM on the guest. Seems to work well, except for those slowdowns due to the hungry caching of Chrome (I just have to be patient to get to plateau).