On 03/13/2017 06:29 AM, Michal Privoznik wrote:
I am not able to test this properly (my host has "just"
32GiB of RAM), but I've
patched qemu to insert some delay into its init process and it worked just
fine.
Damn, I should have scanned the list today before also working on this problem.
Attached is a patch I used to test the concept. It's a hack, but in the end
calculates the same timeout as your series. It worked well in my testing.
Michal Privoznik (2):
virTimeBackOffWait: Avoid long periods of sleep
qemu: Adaptive timeout for connecting to monitor
Yep, I like these changes over the hack :-).
Regards,
Jim
src/qemu/qemu_capabilities.c | 2 +-
src/qemu/qemu_monitor.c | 36 +++++++++++++++++++++++++++++++-----
src/qemu/qemu_monitor.h | 1 +
src/qemu/qemu_process.c | 8 ++++++++
src/util/virtime.c | 14 ++++++++++++--
tests/qemumonitortestutils.c | 1 +
6 files changed, 54 insertions(+), 8 deletions(-)