RE: Question about host CPU usage/allocation by KVM

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



| -----Original Message-----
| From: kvm-owner@xxxxxxxxxxxxxxx [mailto:kvm-owner@xxxxxxxxxxxxxxx] On
| Behalf Of Brian Jackson
| Sent: Friday, April 20, 2012 8:01 AM
| To: Stuart Yoder; Alexander Lyakas
| Cc: kvm@xxxxxxxxxxxxxxx
| Subject: Re: Question about host CPU usage/allocation by KVM
| 
| On Thu, 19 Apr 2012 13:01:54 -0500, Alexander Lyakas
| <alex.bolshoy@xxxxxxxxx> wrote:
| 
| > Hi Stuart,
| > I have been doing some experiments, and I noticed that there are
| > additional QEMU threads, besides the ones reported by "info cpus"
| > command. In particular, the main QEMU thread (the one whose LWP is the
| > same as its PID), also consumes significant CPU time. Is this
| > expected?
| 
| The extra threads are for various things. It can be for the vnc server if
| you are using it. Threads are used to mimic aio in certain situations.
| Etc. The main thread also does a lot of the device emulation work
| (console, network, serial, block, etc.)

Is there some way to know what they are for ? or how many can get created ?

I noticed that the number of threads go from ~4 to ~70 if I do some I/O inside the guest.

Sunny

| 
| 
| >
| > Alex.
| >
| >
| > On Wed, Apr 18, 2012 at 8:24 PM, Stuart Yoder <b08248@xxxxxxxxx> wrote:
| >> On Tue, Apr 17, 2012 at 4:54 PM, Alexander Lyakas
| >> <alex.bolshoy@xxxxxxxxx> wrote:
| >>> Greetings everybody,
| >>>
| >>> Can anybody please point me to code/documentation regarding the
| >>> following questions I have:
| >>>
| >>> - What does it actually mean using "-smp N" option, in terms of CPU
| >>> sharing between the host and the guest?
| >>> - How are guest CPUs mapped to host CPUs (if at all)?
| >>
| >> Each guest CPU (vcpu) corresponds to a QEMU thread.
| >> You can see the thread ids in QEMU with "info cpus" in the QEMU
| >> monitor.
| >>
| >> Since a vcpu is a thread you can apply standard Linux mechanisms to
| >> managing those threads-- CPU affinity, etc.
| >>
| >> Stuart
| > --
| > 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
| --
| 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
��.n��������+%������w��{.n�����o�^n�r������&��z�ޗ�zf���h���~����������_��+v���)ߣ�

[KVM ARM]     [KVM ia64]     [KVM ppc]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]    [Yosemite Photos]    [Linux Kernel]     [Linux SCSI]     [XFree86]

Add to Google Powered by Linux