Bug 1211518 - Please provide API for getting NUMA vCPU mapping
Summary: Please provide API for getting NUMA vCPU mapping
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libvirt
Version: unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Libvirt Maintainers
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-04-14 08:34 UTC by Martin Sivák
Modified: 2016-12-12 10:46 UTC (History)
15 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-12-12 10:46:03 UTC
Embargoed:


Attachments (Terms of Use)

Description Martin Sivák 2015-04-14 08:34:54 UTC
Description of problem:

We (oVirt's VDSM) need to know vCPU to NUMA node mapping for reporting purposes. We are getting the information by querying for ./vcpus/vcpu/pid nodes in the domain XML which is slow (and requires parsing of the whole domain every time).

We would appreciate if there was an API call to give us NUMA information directly.

Comment 1 Daniel Berrangé 2015-04-14 08:38:43 UTC
I'm unclear why the performance of parsing XML is a problem in this case. The mapping of VCPUs <-> NUMA nodes never changes once a guest has been booted. In addition VDSM is in full control of the guest configuration. So VDSM should already know what mapping it configured, and if it doesn't it merely needs to parse the XML once after boot to figure it out, which is not going to be a performance hit. So based on your description, I don't really see any compelling reason to add an API for getting this info.

Comment 2 Cole Robinson 2015-09-21 23:07:01 UTC
Closing as WONTFIX per Dan's comment #1

Comment 3 Martin Sivák 2015-09-22 14:57:05 UTC
Uh guys.. the mapping might change, ever heard about auto-numa? It might not be the best thing the kernel does, but it is here and might rebalance the nodes without us knowing about it.

Comment 4 Michal Skrivanek 2016-10-13 09:21:01 UTC
redirecting the needinfo

Comment 5 Cole Robinson 2016-10-14 14:07:15 UTC
Moving needinfo to danpb since he wrote Comment 1, but maybe pkrempa has thoughts since he's done VCPU API work in libvirt recently

Comment 6 Daniel Berrangé 2016-11-07 12:29:27 UTC
We should already be reporting the vCPU <-> pCPU mapping via the virDomainGetVcpuPinInfo() API, and you can map pCPUs to NUMA cells using the capabilities XML, so I'm still not seeing a need for new APIs.

Comment 7 Martin Sivák 2016-12-12 10:46:03 UTC
We decided to remove the numa status runtime reporting so we do not need this anymore.


Note You need to log in before you can comment on or make changes to this bug.