|
From: | Max Reitz |
Subject: | Re: [Qemu-block] [PATCH 2/3] qcow2: add option to clean unused cache entries after some time |
Date: | Thu, 28 May 2015 17:06:51 +0200 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 |
On 28.05.2015 17:04, Max Reitz wrote:
On 28.05.2015 17:02, Alberto Garcia wrote:On Thu 28 May 2015 04:56:34 PM CEST, Max Reitz wrote:'compat': 'str', '*lazy-refcounts': 'bool', '*corrupt': 'bool', - 'refcount-bits': 'int' + 'refcount-bits': 'int', + 'cache-clean-interval': 'int' } }I'm not too happy about making this part of ImageInfoSpecificQCow2. Two reasons for this: First, it's eventually part of ImageInfo, which is defined as "Information about a QEMU image file", but this option cannot be set in the image file itself but is only a run-time option.That's a valid point. Now that I think of it, do we actually have a way to retrieve the sizes of the L2 and refcount caches? I think cache-size, l2-cache-size, and refcount-cache-size are already write-only values.No, in fact we don't. Well, except for if you manage to retrieve the JSON filename for the qcow2 BDS, it should be part of that. :-P
And I just noticed, passing that option will result in qemu returning the JSON filename when queried:
$ qemu-img info "json:{'l2-cache-size':65536,'file.filename':'test.qcow2'}"image: json:{"driver": "qcow2", "l2-cache-size": 65536, "file": {"driver": "file", "filename": "test.qcow2"}}
[…] Max
[Prev in Thread] | Current Thread | [Next in Thread] |