From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47405) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Voa9h-00052p-9M for qemu-devel@nongnu.org; Thu, 05 Dec 2013 09:43:58 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Voa9Y-0003jn-JJ for qemu-devel@nongnu.org; Thu, 05 Dec 2013 09:43:53 -0500 Received: from nodalink.pck.nerim.net ([62.212.105.220]:44718 helo=paradis.irqsave.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Voa9Y-0003ja-89 for qemu-devel@nongnu.org; Thu, 05 Dec 2013 09:43:44 -0500 Date: Thu, 5 Dec 2013 15:43:36 +0100 From: =?iso-8859-1?Q?Beno=EEt?= Canet Message-ID: <20131205144336.GE2892@irqsave.net> References: <1386077165-19577-1-git-send-email-benoit@irqsave.net> <1386077165-19577-4-git-send-email-benoit@irqsave.net> <529FBEDA.9050409@redhat.com> <20131205142416.GD2892@irqsave.net> <52A08FED.7020305@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: <52A08FED.7020305@redhat.com> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [RFC V3 3/7] qapi: Add skeletton of command to query a drive bs graph. List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric Blake Cc: =?iso-8859-1?Q?Beno=EEt?= Canet , kwolf@redhat.com, famz@redhat.com, jcody@redhat.com, qemu-devel@nongnu.org, armbru@redhat.com, stefanha@redhat.com Le Thursday 05 Dec 2013 =E0 07:38:37 (-0700), Eric Blake a =E9crit : > On 12/05/2013 07:24 AM, Beno=EEt Canet wrote: >=20 > >> > >> Am I correct that it will be possible to have named nodes that are n= ot > >> currently associated with any device? If so, how do we learn about > >> those nodes? Would it be better to have a command that returns an a= rray > >> of structs for all known node roots, with an optional member describ= ing > >> which device owns that node root? Something like: > >=20 > > The code have a list of all named nodes but not a list of named nodes= roots. > > Also it's difficult to get the device name for a named node because t= he bses don't > > have any backward pointers to their parents. > > It could be done by recursing into all the blockbackend bs but it's t= wisted. >=20 > Still worth thinking about how to structure things so we could add it i= n > the future if it turns out to be useful to management, but I can > understand why you aren't providing it right away. >=20 > >=20 > > In fact I am wondering if we really need something to spit out the na= med nodes > > topology in QMP for the simple reason that the names of the nodes are= given by the > > management so the management should already know the topology. >=20 > There's one case where management might not know - if libvirtd gets > restarted while in the middle of an operation that was attempting to > create a named node, then on restart and reconnection to the monitor, > libvirt would want to query to see if the node actually got created or > if the command needs to be attempted again. I'm not a fan of write-onl= y > interfaces - and making management responsible to track all named nodes > with no way to query if qemu actually agrees with the topology that > management thinks it has commanded feels like a write-only interface. Would a command returning info about a specific named node be sufficient = for libvirt checks ? It's far less complex to implement than exposing the whole graph. We could also provide a simple command to list the names of the named nod= es. Best regards Beno=EEt >=20 > --=20 > Eric Blake eblake redhat com +1-919-301-3266 > Libvirt virtualization library http://libvirt.org >=20