Monday, November 24, 2008

With AVIO, swapper's the one doing all the job

If swapper has a high usage on a VM Host, that doesn't mean that your system is "swapping". In fact, I just discovered that AVIO I/O is handled by the swapper!

I'm benchmarking with iozone one of my VMs and noticed that on the HPVM 4.0 host, swapper usage was high. This is not normal, old school attendance thaught me that swapper should never be doing this, as when it is, your system is deactivating processes and you're deep trouble. Yet the VM Host is humming along, with plenty of memory left.

Since the I/O rate of the disk presented to my benchmark VM roughly matches the I/O rate of the swapper, I can only conclude that the AVIO engineers hacked the swapper so that it's now the sole responsible of doing I/O on behalf of the guests. I'm no kernel developper so the implementation details are beyond me. But it does makes sense in a way: since swapper is real-time priority process, it's sure that I/O handled by swapper will go out the door faster than if it's coming from hpvmapp.

Your VM Host should technically never start deactivating processes anyway, unless of your all the WBEM providers go haywire. Oups, I bashed the WBEM providers once again, sorry about that.
As all this I/O was labeled under the memory_management application in Glance, I modified my /var/opt/perf/parm file to add an application type for AVIO. Remove swapper from memory_management, and add a new type named "avio" which includes the swapper.

No comments: