[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Xen-devel] what happens when a PoD page is touched?
At 11:16 +0100 on 15 May (1305458171), James Harper wrote:
> I'm finding that the time of boot and hibernation of Windows under
> xen-4.0.2-rc3 when maxmem is set is a big problem - 40 seconds to
> balloon down 512MB on my system. Hibernation is even worse with delays
> of minutes or hours.
> What happens when such a PoD page is touched? Does Xen or qemu handle
Xen handles it. When you touch a PoD page the frame is backed with a
fresh, zeroed page from the pool of PoD pages. The slowdown comes when
the PoD pages run low; then Xen has to scan guest memory looking for
pages that are all zeroes and reclaim them into the PoD pool.
This is all pretty unpleasant, as you can imagine. The practical
- get your balloon driver loaded as soon as you possibly can,
so you can balloon down before the Windows page scrubber pointlessly
touches all of RAM (AIUI on SMP systems this is pretty hard; it may be
that once we get UEFI firmware it will be eaiser);
- alloc pages to be ballooned using an interface that doesn't scrub them;
- don't be too aggressive about how much you overcommit.
Ideally, once Hyper-V brings in an interface for dynamic memory
ballooning in guests, we can use that and avoid this whole rigmarole for
new windows version.
CC'ing George, who knows this code best. IIRC there were some tweaks to
this code for XenServer, which I hope are all now upstream. Do you know
whether 4.1-testing has the full set or are they only in -unstable?
Tim Deegan <Tim.Deegan@xxxxxxxxxx>
Principal Software Engineer, Xen Platform Team
Citrix Systems UK Ltd. (Company #02937203, SL9 0BG)
Xen-devel mailing list