10 Commits

Author SHA1 Message Date
Michael Trapp
cfd4e6f198 Add virtio functions
At the vhostmd side virtio channels are Unix domain sockets from QEMU
which are created during a VM start and removed when the VM is stopped.

Basically this implementation
- monitors a directory for new virtio channels
- for valid IDs, also known by libvirtd, it connects to the UDS
- buffers VM/HOST metrics and handles request/response on the sockets

It provides the functions
virtio_init()
    init function of virtio layer
virtio_run()
    the start_routine for the virtio-thread to handle the virtio based
    communication
virtio_metrics_update()
    called for each VM/HOST metrics update to update the virtio internal
    metrics buffer.
virtio_stop()
    stop the virtio-thread
2018-11-30 11:49:34 -07:00
Michael Trapp
c1d67a50fa Extend vu_buffer struct
With the virtio implementation vu_buffer is used for socket IO
and therefore information about the current position after a
write is required.
2018-11-29 11:02:58 -07:00
Jim Fehlig
1586cf7722 Remove support for libxenstat
Old, crufty code that no longer compiles and should be
removed from the sources. libvirt or custom "actions"
should be used to gather metrics.

Signed-off-by: Jim Fehlig <jfehlig@suse.com>
2018-06-07 11:15:47 -06:00
Jim Fehlig
3dd984f729 Remove xenctrl support
The xenctrl interface has changed over the years, causing
the associated code in vhostmd to no longer compile. Instead
of trying to get this low-level xen interface working again,
simply remove it from vhostmd. libvirt or custom "actions"
should be used to gather metrics.

Signed-off-by: Jim Fehlig <jfehlig@suse.com>
2018-06-07 11:15:47 -06:00
Richard W.M. Jones
667952366e Mark unused parameters with ATTRIBUTE_UNUSED.
This macro is defined for gcc so that unused parameters don't
provoke warnings.
2012-01-16 12:09:21 +00:00
Alex Zeffertt
44191e60d3 Fix build when './configure --enable-xenctrl' is used
Hi all,

The attached patch against v0.4 fixes the build when --enable-xenctrl is used.

If this configure option is used vhostmd does not link against libvirt or
virt-util.o, but a few bits of code were assuming that these were always linked in.

Please could you consider this patch for inclusion in the vhostmd project.

Regards,

Alex Zeffertt

Fix build when "./configure --enable-xenctrl" is used.

This option disables the use of libvirt.  Instead libxc gets used to
find out stuff about VMs.

If this option is used then virt-util.c does not get built.  This
patch removes the linker dependencies on virt-util.o when
--enable-xenctrl is used.

Signed-off-by: <alex.zeffertt@eu.citrix.com>
2010-01-07 12:22:41 -07:00
Richard Jones
7abb231d93 Add '-c uri' command line option to specify libvirt connection URI. 2009-10-15 16:49:37 +01:00
Richard Jones
ff676595c8 Allow gcc to check calls to vu_log* printf-like functions. 2009-10-15 13:13:44 +01:00
Richard Jones
326f001217 Allow xenstore dependency to be removed using ./configure --without-xenstore.
If ./configure --without-xenstore, then the dependency on
xenstore is removed.  Attempts to use xenstore will result
in a runtime error.

The default is still that xenstore is enabled.
2009-10-12 17:27:01 +01:00
Jim Fehlig
d0414b380f Initial import of vhostmd project 2009-08-13 10:58:45 -06:00