Gregory Haskins wrote: > On Wed, 2007-08-15 at 11:07 +0300, Avi Kivity wrote: >> Farkas Levente wrote: >>> this rise another question if swapping will be used the it moves the >>> guest memory to the guest's swap or the host's swap? if to the host's >>> swap then this implies i should have to allocate large enough swap for >>> the host. ie. even if i give only 256mb to the host still have to gives >>> 6-8GB swap partition to the host. >>> >> Yes, when swapping is implemented then guest memory will be swapped to >> the host swap. Of course, if the guest has its own swap file, then it >> will swap to the guest's swap independently. > > And to clarify: FYI, I believe the guest-swap option should actually > work today. If you assign a partition as a swap device in the guest it > should use it. kvm-host will simply see it as disk io as any other. > This is in contrast to the host-swap and/or balloon driver which is > still a work-in-progress. > > On thing that is interesting about this (to me) is that, in a way it > kind of is a "poor mans" swap for the guests memory on the host. E.g. > you could give your guests a really small amount of "physical" ram (say, > I dunno, 64MB/ea) and a large swap file (say several gigs). Since the > disk-io emanating from the guest would likely be mediated by the hosts > buffercache, its kind of like you just gave the guest a large chunk of > (indirectly accessible) pageable ram.
i just imagine th opposite setup. suppose i've got 4 guest and 4gb ram. most of the time guest are idle they just used as a compile server for different platforms (centos, mandrake, fedora, windows etc). i can schedule the compiles (ie. 1:00 guest1, 2:00 guest 2 etc). in this case i gives the host 1-2gb and all guest 2-3gb logical ram. which is in sum 9-14gb ram even i have only 4gb physical ram. _BUT_ as i know that the guests are usually idle _and_ they have high resource requirement at different time, probably all of them can use 2-3gb real ram as memory. and in this setup if all other time most of the guest's ram are swapped out it's not really bother me since they are idle. or did is something misunderstood? -- Levente "Si vis pacem para bellum!" ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ kvm-devel mailing list kvm-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/kvm-devel