[vbox-dev] Docs on how page fusion works?
rbhkamal at gmail.com
Mon Apr 16 08:09:04 PDT 2012
What kind if obstacles would I face if I tried to implemented the
same behavior (Scan processes) for Linux guests? I plan on scanning every
process then check the memory maps from /proc/<pid>/maps. If the
permissions are set to r only or rx then I'll register the pages with the
host. This wouldn't cover the process it self, but a major portion of
the wasted memory.
Sounds simple (everything does these days) and I plan to work it. However,
I just need an expert to give me the go-ahead since this is all new to me.
On Fri, Apr 13, 2012 at 6:41 PM, Alexey Eromenko <al4321 at gmail.com> wrote:
> > The guest additions service scans the guest for modules (user/kernel) and
> > registers each module with the hypervisor on the host. Then notifies the
> > hypervisor to check if the pages are shared with other VMs. What I don't
> > understand is what happens when the hypervisor decides that two pages are
> > the same? And what happens if one of these pages change *after* it was
> > already "merged" with other similar pages.
> AFAIK if two pages are the same, only one is stored in RAM, with 2
> references from 2 VMs (or 2 references from same 1 VM, deduplicating
> mem inside 1 VM).
> If one VM changes page, it just copied to new location, so now VBox
> stops deduping this page.
> This is how KSM works, and how I expect PageFusion to work.
> > And ,sorry to ask this, is KSM utilized when it is enabled on the host?
> Of course not.
> VBox is cross-platform technology, while KSM is Linux only, so KSM is
> useless for VBox.
> One advantage of KSM, is that it doesn't depend on any guest drivers,
> and all logic is done host-side. VBox PageFusing requires GA,
> Guest-OS-specific drivers.
> But I didn't done any benchmarking to compare the efficiency of both
> -Alexey Eromenko "Technologov"
> vbox-dev mailing list
> vbox-dev at virtualbox.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the vbox-dev