[libvirt] [PATCH v2 5/5] qemu: Enable memory-backend-file.discard-data whenever possible

Peter Krempa pkrempa at redhat.com
Tue Apr 17 12:57:50 UTC 2018


On Tue, Apr 17, 2018 at 13:18:02 +0100, Daniel Berrange wrote:
> On Tue, Apr 17, 2018 at 01:16:42PM +0200, Michal Privoznik wrote:
> > https://bugzilla.redhat.com/show_bug.cgi?id=1480668
> > 
> > The cases when we cannot enable this optimization are:
> >   1) nvdimms
> >   2) if memAccess='shared'
> > 
> > Otherwise it is safe to enable it.
> 
> This is basically saying that if memAccess==private, then no person/app cares
> about the contents of the memory-backend-file storage after QEMU has exited,
> because (implicitly) whatever data was in that storage is not going to be used
> again. While I accept that's going to be a common case, I'm wary of saying that
> is a 100% safe/valid assumption for every user.
> 
> I tend think it should require an explicit opt-in to turn on this behaviour

Well, we used that behaviour prior to storing the backing files in a
"predictible" path as the file was unlinked right after creating it
(so that some memory management software can do some magic behind our
backs with that) so I don't think anybody would depend on the described
behaviour.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20180417/e364e1b1/attachment-0001.sig>


More information about the libvir-list mailing list