System information
Sharing and maintaining SLES 10 SP2 Linux under z/VM 63
1.8.3 Enabling Collaborative Memory Management (CMM)
VMRM is a z/VM tool that provides functions to dynamically tune the z/VM system. Groups of
virtual machines can be defined to be part of a workload. The workloads can then be
managed by VMRM to goals that are also defined
Cooperative Memory Management (CMM1) is a facility which provides z/VM with a way to
indirectly control the amount of memory that Linux uses. This technique is known as
ballooning, and is implemented by a special driver in Linux. When VMRM determines that the
system is becoming too constrained by memory, it will direct the driver to allocate and pin
memory within Linux, which forces Linux to relinquish or page out some of the memory it had
been using. In turn, the driver informs z/VM of the pages it has pinned. Since the driver was
designed never to use these pages, z/VM knows they are now available for it to use, and so
can reclaim them, thus reducing overall system memory pressure.
On the other hand, when VMRM determines that the system is no longer under memory
pressure, it will direct the ballooning driver to reduce the number of pages it has pinned, thus
allowing Linux to expand its memory usage once more.
More details about CMM1 can be found at:
http://www.vm.ibm.com/sysman/vmrm/vmrmcmm.html
Collaborative Memory Management Assist
Collaborative Memory Management Assist (CMMA) consists of changes in hardware, z/VM
5.3, and Linux. The hardware facility includes a new instruction (EXTRACT AND SET STORAGE
ATTRIBUTES - ESSA), which can be simulated by z/VM on machines where the facility is not
available (although, due to simulation overhead, it is generally not recommended to do so).
CMMA introduces new usage and state information for each memory page, thus enabling
Linux and z/VM to employ more efficient memory management algorithms which do not
conflict with one another.
More details about CMMA can be found in the manual z/VM V5R3.0 CP Programming
Services (SC24-6084), at:
http://publibz.boulder.ibm.com/epubs/pdf/hcse5b21.pdf
In both CMM flavors, the benefit is proportional to the potential. On systems where the guests
are poorly configured, or over-sized, you will see the most benefit. There was an early study
done by a group in IBM, z/VM Large Memory - Linux on System z, available at:
http://www.ibm.com/support/techdocs/atsmastr.nsf/WebIndex/WP101151
CMMA is mentioned for completeness, but it should be noted that CMMA is no longer
supported in SLES 11. So this function may become deprecated.
Configuring CMM1
CMM1 must be enabled on both the Linux and z/VM sides for it to function. To enable it for
Linux, the cmm module must be loaded at boot time.
To enable z/VM for CMM1, perform the following steps:
1. Log on to the user ID VMRMSVM
2. Create a new or edit the existing configuration file, VMRM CONFIG A. Add two lines as
follows:
==> x vmrm config