From mboxrd@z Thu Jan 1 00:00:00 1970 From: Manish Jaggi Subject: Re: [libvirt] libvirt/libxl implemetation of get_online_cpu / virNodeGetCPUMap? Date: Tue, 24 Mar 2015 14:17:20 +0530 Message-ID: <55112498.1060905@caviumnetworks.com> References: <20150224124101.GX1345@perard.uk.xensource.com> <20150224124644.GK21611@redhat.com> <20150224131557.GY1345@perard.uk.xensource.com> <20150224132219.GL21611@redhat.com> <20150224150016.GZ1345@perard.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20150224150016.GZ1345@perard.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Anthony PERARD , "Daniel P. Berrange" Cc: libvir-list@redhat.com, Ian Jackson , Ian Campbell , Xen Devel List-Id: xen-devel@lists.xenproject.org On Tuesday 24 February 2015 08:30 PM, Anthony PERARD wrote: > On Tue, Feb 24, 2015 at 01:22:19PM +0000, Daniel P. Berrange wrote: >> On Tue, Feb 24, 2015 at 01:15:57PM +0000, Anthony PERARD wrote: >>> On Tue, Feb 24, 2015 at 12:46:44PM +0000, Daniel P. Berrange wrote: >>>> On Tue, Feb 24, 2015 at 12:41:01PM +0000, Anthony PERARD wrote: >>>>> Hi, >>>>> >>>>> A recent OpenStack nova commit make use of virNodeGetCPUMap to get the list >>>>> of online cpu of a host. But this API is not implemented for the libvirt >>>>> xen driver. >>>>> >>>>> The commit: >>>>> Add handling for offlined CPUs to the nova libvirt driver. >>>>> https://review.openstack.org/gitweb?p=openstack/nova.git;a=commitdiff;h=0696a5cd5f0fdc08951a074961bb8ce0c3310086 >>>> FWIW, this should not impact Xen based on my understanding. The code >>>> path in question should only be used when Nova is setup todo NUMA >>>> pinning support, and that is not supported with Xen in OpenStack, >>>> only KVM. Did it actually cause failures for you, or are you simply >>>> keeping track of all used APIs in Nova as a sanity check ? >>> It prevent nova from starting. I do the setup with DevStack. >>> >>> The error: >>> libvirtError: this function is not supported by the connection driver: virNodeGetCPUMap >>> >>> And a part of the traceback: >>> File "/opt/stack/nova/nova/openstack/common/service.py", line 491, in run_service >>> service.start() >>> File "/opt/stack/nova/nova/service.py", line 181, in start >>> self.manager.pre_start_hook() >>> File "/opt/stack/nova/nova/compute/manager.py", line 1188, in pre_start_hook >>> self.update_available_resource(nova.context.get_admin_context()) >>> File "/opt/stack/nova/nova/compute/manager.py", line 6062, in update_available_resource >>> rt.update_available_resource(context) >>> File "/opt/stack/nova/nova/compute/resource_tracker.py", line 315, in update_available_resource >>> resources = self.driver.get_available_resource(self.nodename) >>> File "/opt/stack/nova/nova/virt/libvirt/driver.py", line 4896, in get_available_resource >>> numa_topology = self._get_host_numa_topology() >>> File "/opt/stack/nova/nova/virt/libvirt/driver.py", line 4749, in _get_host_numa_topology >>> online_cpus = self._host.get_online_cpus() >>> File "/opt/stack/nova/nova/virt/libvirt/host.py", line 599, in get_online_cpus >>> (cpus, cpu_map, online) = self.get_connection().getCPUMap() >>> >>> I'll look into why nova is going through NUMA code paths then. >> Oh damn, yes, I understand why now. Please file a bug against Nova for >> this, as we must fix it as a high pripority. It was certainly not my >> intention to break Xen when I approved this change I applied the patch, not getting this python libvirtError, but libvirt deamon is throwing error. 2015-03-24 08:46:31.169+0000: 1030: error : virNodeGetCPUMap:1342 : this function is not supported by the connection driver: virNodeGetCPUMap > Here is the bug report: https://bugs.launchpad.net/nova/+bug/1425115 > > Regards, >