On 11/27/18 7:06 AM, Michael Trapp wrote:
Add virtio serial channels as transport method for VM and host metrics. A serial port at the VM side provides access to host metrics and metrics of the reading VM, access to metrics of other VMs is not supported. Virtio transport can be activated in the vhostmd transport configuration. The required QEMU setup and the virtio configuration options are documented in the vhostmd README. virtio.c, which is the main part of this change, contains the virtio channel related implementation of the transport. Connection handling and I/O is executed in an additional thread and separates collecting metrics from serving requests. Basic concept of vhostmd/virtio interaction is documented in the patch. Notes on V4 - moved virtio channel to standard libvirt path and naming scheme /var/lib/libvirt/qemu/channel/target/domain-<ID>-<NAME>/org.github.vhostmd.1 - switched from uuid to id - reviewed internal data structures, merged mbuffer and channel structs, replaced btree with preallocated structs and index Michael Trapp (6): Initialize allocated buffer Fix update_interval behaviour Extend vu_buffer struct Add virtio functions Activate virtio support in vhostmd Add virtio support to vm-dump-metrics README | 78 +++- include/util.h | 1 + include/virtio.h | 48 +++ libmetrics/Makefile.am | 17 +- libmetrics/libmetrics.h | 6 + libmetrics/libserialclient.c | 172 ++++++++ libmetrics/libserialclient.h | 30 ++ vhostmd.changes | 5 + vhostmd.dtd | 6 +- vhostmd.xml | 6 + vhostmd/Makefile.am | 4 +- vhostmd/util.c | 2 + vhostmd/vhostmd.c | 65 ++- vhostmd/virtio.c | 759 +++++++++++++++++++++++++++++++++++ vm-dump-metrics/main.c | 29 +- 15 files changed, 1207 insertions(+), 21 deletions(-) create mode 100644 include/virtio.h create mode 100644 libmetrics/libserialclient.c create mode 100644 libmetrics/libserialclient.h create mode 100644 vhostmd/virtio.c
I changed the few occurrences of C++ style comments to C style and pushed the series. Thanks for adding the new feature!
I suppose this calls for a release! I'm going to push a few trivial patches (remove commented code, change last two occurrences of C++ comment style) and work on a release.
Regards, Jim _______________________________________________ virt-tools-list mailing list virt-tools-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/virt-tools-list