On Tue, May 10, 2022 at 10:43:04AM +0100, Richard W.M. Jones wrote:
When running virt-p2v which uses this plugin, the log file is
consumed
by messages about state machine transitions and so on. In a log file
that was shared with me, out of the 135,023 lines in total,
94,653 (70%) were:
nbdkit: debug: polling, dir=1
and 18,676 (14%) were:
nbdkit: debug: cookie X completed state machine, status 0
This commit changes the logging so these state machine transitions are
only printed when you use the debug flag “-D nbd.verbose=1”. I didn't
document this flag because it's likely only of use to developers who
are reading the code already.
There are some debug messages along error paths which are
(a) generally useful and (b) did not appear in the log file, so I left
those alone.
Fixes:
https://bugzilla.redhat.com/show_bug.cgi?id=2083498
Reported-by: Ming Xie
---
plugins/nbd/nbd.c | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)
Reviewed-by: Eric Blake <eblake(a)redhat.com>
--
Eric Blake, Principal Software Engineer
Red Hat, Inc. +1-919-301-3266
Virtualization:
qemu.org |
libvirt.org