[libvirt-users] Can LXC and KVM run in a single node at the same time? How does LXC vcpu map to cgroups cpu.shares?
Eric Blake
eblake at redhat.com
Sat Feb 23 21:01:07 UTC 2013
[please start a new topic with a new thread, instead of using
in-reply-to an unrelated thread]
On 02/22/2013 07:42 PM, 张章 wrote:
>
> hi,all
> I want to run LXC and KVM in a single node at the same time. Is it possible?
Yes, you can have both hypervisor drivers running on the same machine;
you choose which hypervisor you connect to according to the URI that you
pass to 'virsh -c' or virConnectOpen().
> If so, can resource isolation work properly? that is, can LXC and KVM get their corresponding shares of resources(vcpu, memeory, etc..)?
> In that case, how does LXC vcpu map to cgroups cpu.shares?
Yes, both LXC and qemu hypervisors know how to limit guest resources
using cgroups under the hood; in particular, see
http://libvirt.org/formatdomain.html#elementsCPUTuning for the XML to
use. <cputune> has a sub-element <shares> that maps nicely to the
cgroups cpu.shares.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 621 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvirt-users/attachments/20130223/5901d0a2/attachment.sig>
More information about the libvirt-users
mailing list