Changelog from v3: * Add unsigned int flags to the public api and make corresponding changes further down till the drivers(qemu, lxc and remote) * Move exporting of the api's to patch two * Added memtune test in tests/qemuxml2xmltest.c * Fix: src/conf/domain_conf.c - print memtune element only if tunable is present * Fix: src/qemu/qemu_driver.c - call cgroup apis only if nonzero * Fix: src/lxc/lxc_controller.c - call cgroup apis only if nonzero Changelog from v2: * Implement virDomainGetMemoryParameters api * Add virDomainGetMemoryParameters to memtune command in virsh * Provide domainGetMemoryParameters implementation for remote, QEmu and LXC drivers * Auto-generate code using rpcgen and remote_generate_stubs.pl * Squash all the changes related to remote driver and remote protocol into one single patch. * Patch re-ordering Changelog from v1: * Patch re-ordering for compilation * Folded python bindings changes to patch 01 * Added defines for string constants for memory tunables * Typo fix: min_guarantee * Moved initialization of function pointers in driver.h patch This patch series implement public api for controlling various memory tunables exported by the OS. This is based on the following RFC[1]. * Implement virDomainSetMemoryParameters api * Provide implementation for remote, QEmu and LXC drivers * Enable memory controller support fro QEmu * virsh command for runtime changes to the memory parameters * Domain configuration parsing for memory control parameters * Cgroup memory controller code for memory hard_limit/soft_limit, swap hard_limit To Do * Python bindings is just a place holder, need to implement 1. https://www.redhat.com/archives/libvir-list/2010-August/msg00607.html 2. https://www.redhat.com/archives/libvir-list/2010-August/msg00699.html --- Nikunj A. Dadhania (13): Adding structure and defines for virDomainSet/GetMemoryParameters Adding virDomainSetMemoryParameters and virDomainGetMemoryParameters API Adds xml entries for memory tunables XML parsing for memory tunables Implement cgroup memory controller tunables Implement driver interface domainSetMemoryParamters for QEmu Implement driver interface domainGetMemoryParamters for QEmu Adding memtunables to qemuSetupCgroup Adding memtunables to libvirt-lxc command Implement driver interface domainSetMemoryParamters for LXC Implement driver interface domainGetMemoryParamters for LXC Adding memtune command to virsh tool Remote protocol changes and implements virDomainSet/GetMemoryParameters daemon/remote.c | 162 +++++++++++++ daemon/remote_dispatch_args.h | 2 daemon/remote_dispatch_prototypes.h | 16 + daemon/remote_dispatch_ret.h | 1 daemon/remote_dispatch_table.h | 10 + docs/schemas/domain.rng | 31 +++ include/libvirt/libvirt.h.in | 63 +++++ python/generator.py | 2 python/libvirt-override-api.xml | 12 + python/libvirt-override.c | 14 + src/conf/domain_conf.c | 54 ++++ src/conf/domain_conf.h | 12 + src/driver.h | 14 + src/esx/esx_driver.c | 2 src/esx/esx_vmx.c | 30 +- src/libvirt.c | 104 +++++++++ src/libvirt_private.syms | 6 src/libvirt_public.syms | 6 src/lxc/lxc_controller.c | 32 +++ src/lxc/lxc_driver.c | 215 +++++++++++++++++- src/openvz/openvz_driver.c | 10 - src/phyp/phyp_driver.c | 2 src/qemu/qemu.conf | 4 src/qemu/qemu_conf.c | 11 - src/qemu/qemu_driver.c | 265 +++++++++++++++++++++- src/remote/remote_driver.c | 151 +++++++++++++ src/remote/remote_protocol.c | 88 +++++++ src/remote/remote_protocol.h | 58 +++++ src/remote/remote_protocol.x | 44 ++++ src/test/test_driver.c | 14 + src/uml/uml_conf.c | 2 src/uml/uml_driver.c | 16 + src/util/cgroup.c | 106 +++++++++ src/util/cgroup.h | 7 + src/xen/xen_driver.c | 2 tests/qemuxml2argvdata/qemuxml2argv-memtune.args | 1 tests/qemuxml2argvdata/qemuxml2argv-memtune.xml | 30 ++ tests/qemuxml2xmltest.c | 1 tools/virsh.c | 130 +++++++++++ 39 files changed, 1662 insertions(+), 68 deletions(-) create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-memtune.args create mode 100644 tests/qemuxml2argvdata/qemuxml2argv-memtune.xml -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list