[libvirt] [PATCH RFC 00/39] qemu: Add support for -blockdev
Peter Krempa
pkrempa at redhat.com
Fri Jul 27 08:01:05 UTC 2018
On Thu, Jul 26, 2018 at 17:04:19 +0800, Fam Zheng wrote:
> On Thu, 07/26 10:44, Kevin Wolf wrote:
> > Am 25.07.2018 um 17:57 hat Peter Krempa geschrieben:
> > > This series adds support for starting and hotplug of disks with
> > > -blockdev/blockdev-add.
> > >
> > > Blockjobs are not supported and thus the last patch should not be
> > > applied yet as some refactoring of the jobs is required.
> > >
> > > At the beginning of the series there are a few cleanup patches which may
> > > be pushed even at this point.
> > >
> > > The main reason this is in RFC state is that block stats reporting does
> > > not work.
> > >
> > > The following command:
> > >
> > > {"execute":"query-blockstats","arguments":{"query-nodes":true}}
> >
> > query-nodes was added in commit f71eaa74c0b by Fam and Max, CCed. I'm
> > not sure what it was needed for at all and the commit message doesn't
> > help with that, but I suppose the addition was related to
> > wr_highest_offset (see below).
>
> Yes, this was part of RHBZ 1158094. Sorry about the poor commit message.
Well the problem is that when using -blockdev with 'query-nodes' false/not present you get a
even more useless output:
virsh qemu-monitor-command --pretty upstream '{"execute":"query-blockstats","arguments":{"query-nodes":false}}'
{
"return": [
],
"id": "libvirt-20"
}
'query-named-block-nodes' don't provide the 'stats' section either:
(other drives snipped)
{
"iops_rd": 0,
"detect_zeroes": "off",
"image": {
"virtual-size": 520032256,
"filename": "/var/lib/libvirt/images/systemrescuecd-x86-4.9.5.iso",
"format": "raw",
"actual-size": 520036352,
"dirty-flag": false
},
"iops_wr": 0,
"ro": true,
"node-name": "libvirt-7-format",
"backing_file_depth": 0,
"drv": "raw",
"iops": 0,
"bps_wr": 0,
"write_threshold": 0,
"encrypted": false,
"bps": 0,
"bps_rd": 0,
"cache": {
"no-flush": false,
"direct": false,
"writeback": true
},
"file": "/var/lib/libvirt/images/systemrescuecd-x86-4.9.5.iso",
"encryption_key_missing": false
},
{
"iops_rd": 0,
"detect_zeroes": "off",
"image": {
"virtual-size": 520032256,
"filename": "/var/lib/libvirt/images/systemrescuecd-x86-4.9.5.iso",
"format": "file",
"actual-size": 520036352,
"dirty-flag": false
},
"iops_wr": 0,
"ro": true,
"node-name": "libvirt-7-storage",
"backing_file_depth": 0,
"drv": "file",
"iops": 0,
"bps_wr": 0,
"write_threshold": 0,
"encrypted": false,
"bps": 0,
"bps_rd": 0,
"cache": {
"no-flush": false,
"direct": false,
"writeback": true
},
"file": "/var/lib/libvirt/images/systemrescuecd-x86-4.9.5.iso",
"encryption_key_missing": false
}
],
"id": "libvirt-19"
}
Thus libvirt can't provide the stats it used to with -drive. Since we
need to special-case the code for gathering stats for -blockdev it
should not be a problem if e.g. query-named-block-nodes reported the
stats section along. (perhaps with a boolean flag to do so which also
could disable the nesting)
In either case we need the stats in the same extent as we had before
with -drive and query-blockstats.
-------------- 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/20180727/a6abd728/attachment-0001.sig>
More information about the libvir-list
mailing list