0

The guest was swapping, after adding 100% memory reservation it continued to do so. After a restart - after some time not much changed.

How can a VM who's memory is 'reserved' be swapping?


alt text

1 Answer 1

3

A reservation only ensures a given VM CAN have the memory resource it has been allocated IF it requests/uses it, it doesn't mean it won't be swapped out if it's not being used.

3
  • @chopper3. Do you have a reference for that? ESX's declared behaviour is that reservation requires physical memory to be allocated to a VM at power on, if the reservation cannot be met it wont power up and the .vswp file size is adjusted so that reserved memory is never covered by swap so I can't see how this could be true.
    – Helvick
    Nov 11, 2009 at 11:03
  • 1
    It has to be available in physical memory at power on yes, you're right, but if it's not requested after that it can be swapped but WILL be allocated physical memory if requests come in, to the detriment of other non-reserved VMs.
    – Chopper3
    Nov 11, 2009 at 11:58
  • 2
    True enough - the Physical RAM may be allocated by the Kernel to other VM's if it hasn't been actively used by the VM up to that point but I don't believe it can be swapped - there is no swap location for it. My understanding is that it is simply not allocated, there is no need to swap it because there is (by definition) nothing useful in it. Again I might be wrong, it's (somewhat) possible that the Kernel could use its dedicated swap partition for this but I don't see why this would be done, it would hit performance for no reason at all.
    – Helvick
    Nov 11, 2009 at 16:14

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .