This patch series adds support of auto-dump on watchdog event in
libvirtd. If a qemu guest is configured with a watchdog device and
libvirtd receives a watchdog event from the guest, it can do
something on the guest, currently `dump' action is defined.
This patch series adds a new watchdog action `managed', it has a
subaction wich indicates the action libvirtd will take on a watchdog
event.
The meaning of subaction_arg depends on subaction. If subaction is
`dump', then subaction_arg defines a folder path into which libvirtd
saves dumpfile.
An example:
<watchdog model='i6300esb' action='managed' subaction='dump'
subaction_arg='/mnt/data/dumps'>
In order to make the function work, there must be a watchdog device
added to guest, and guest must have a watchdog daemon running, for
example, /etc/init.d/watchdog start or auto-started on boot.
Suggestions are welcome!
Hu Tao (2):
Add a thread pool implementation
Add a watchdog action `managed'.
src/Makefile.am | 3 +-
src/conf/domain_conf.c | 27 ++++++++-
src/conf/domain_conf.h | 11 ++++-
src/qemu/qemu_conf.c | 2 +-
src/qemu/qemu_conf.h | 6 ++
src/qemu/qemu_driver.c | 138 ++++++++++++++++++++++++++++++++++++++++++-----
src/util/threadpool.c | 119 +++++++++++++++++++++++++++++++++++++++++
src/util/threadpool.h | 34 ++++++++++++
8 files changed, 319 insertions(+), 21 deletions(-)
create mode 100644 src/util/threadpool.c
create mode 100644 src/util/threadpool.h
--
1.7.3
--
Thanks,
Hu Tao