Am Mittwoch 20 Mai 2009 10:45:50 schrieb Avi Kivity: > Christian Bornträger wrote: > > o shared guest kernels: The CMS operating system is build as a bootable > > DCSS (called named-saved-segments NSS). All guests have the same host > > pages for the read-only parts of the CMS kernel. The local data is stored > > in exclusive-write parts of the same NSS. Linux on System z is also > > capable of using this feature (CONFIG_SHARED_KERNEL). The kernel linkage > > is changed in a way to separate the read-only text segment from the other > > parts with segment size alignment > > How does patching (smp, kprobes/jprobes, markers/ftrace) work with this? It does not. :-) Because of that and since most distro kernels are fully modular and kernel updates are another problem this feature is not used very often for Linux. It is used heavily in CMS, though. Actually, we could do COW in the host but then it is really not worth the effort. > > o execute-in-place: This is a Linux feature to exploit the DCSS > > technology. The goal is to shared identical guest pages without the > > additional overhead of KSM etc. We have a block device driver for DCSS. > > This block device driver supports the direct_access function and > > therefore allows to use the xip option of ext2. The idea is to put > > binaries into an read-only ext2 filesystem. Whenever an mmap is made on > > this file system, the page is not mapped into the page cache. The ptes > > point into the DCSS memory instead. Since the DCSS is demand-paged by the > > host no memory is wasted for unused parts of the binaries. In case of COW > > the page is copied as usual. It turned out that installations with many > > similar guests (lets say 400 guests) will profit in terms of memory > > saving and quicker application startups (not the first guest of course). > > There is a downside: this requires a skilled administrator to setup. > > ksm might be easier to admin, at the cost of some cpu time. Yes, KSM is easier and it even finds duplicate data pages. On the other hand it does only provide memory saving. It does not speedup application startup like execute-in-place (major page faults become minor page faults for text pages if the page is already backed by the host) I am not claiming that KSM is useless. Depending on the scenario you might want the one or the other or even both. For typical desktop use, KSM is very likely the better approach. -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html