
2011/1/26 Justin Clift <jclift@redhat.com>:
On 20/01/2011, at 11:30 PM, Matthias Bolte wrote:
2011/1/19 Justin Clift <jclift@redhat.com>:
This completes the man page updates required for BZ # 622534:
-Change the maximum memory allocation limit in the guest domain. This should -not change the current memory use. The memory limit is specified in -kilobytes. +Change the maximum memory allocation limit for an active guest domain. + +Some hypervisors require a larger granularity than kilobytes, and requests +that are not an even multiple will either be rounded down or rejected. For +example, vSphere/ESX rejects the parameter unless the kB argument is evenly +divisible by 1024 (that is, the kB argument happens to represent megabytes).
Actually vSphere/ESX truncates in this case. It rejects in other cases (virsh define).
As Dan suggested, I might change this to round up.
With vSphere/ESX, does the virsh "setmaxmem" command work on running guest domains, or only inactive ones, or ?
I'd *really* like to update the man page docs around this in the next few days, and I'm still not sure what this command is actually doing in the real world. Heh. ;(
setmaxmem works on inactive guest only. Thanks for making me test this again, because I found a bug in the ESX driver, actually in the vSphere API. The API call allows to set max memory to values that aren't a multiple of 4 megabyte. But such a virtual machine fails to start as ESX reports a general config fault for it. The vSphere Client only allows to change this value in 4 mb steps. I'll have to fix that. Matthias