Re: [PATCH] metadata: track title edits across libvirtd restart

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

 



On Wed, Jul 23, 2014 at 06:46:24AM -0600, Eric Blake wrote:
On 07/22/2014 11:09 PM, Martin Kletzander wrote:
On Tue, Jul 22, 2014 at 01:11:03PM -0600, Eric Blake wrote:
https://bugzilla.redhat.com/show_bug.cgi?id=1122205

Although the edits were changing in-memory XML, it was not flushed
to disk; so unless some other action changes XML, a libvirtd restart
would lose the changed information.


And there are more places like that.  Take a
qemuDomainSetNumaParameters() for example.

That's what I was afraid of - that I'd be stuck with auditing other uses
all because I stumbled on this one while testing a similar fix to
blockcopy. :/

 Would it be possible (as
in "not devastatingly hard" to create a syntax-check rule for
*_driver.c files (only those that are applicable, mostly stateful)
that would check if virCheckFlags is called with
VIR_DOMAIN_AFFECT_LIVE and if yes, then that function would have to
call virDomainSaveStatus() as well?

Via a .pl script maybe, but even that is hard, because sometimes (as in
this patch) the call to virDomainSaveStatus() is delegated to a helper
function in another file than where the API call checks flags.  It's not
just AFFECT_LIVE, but any time where we modify a virDomainDefPtr
(whether live or config), then those modifications have to be written
back to disk before ending the API.


Or maybe CIL or something similar can be used for that.  Having
syntax-check work with the intermediate language would have both pros
and cons, I guess.

Martin

Attachment: signature.asc
Description: Digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]