Re: [kvm-unit-tests PATCH 2/3] migration: Fix test harness hang if source does not reach migration point

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Quoting Nicholas Piggin (2023-07-25 05:39:36)
> After starting the test, the harness waits polling for "migrate" in the
> output. If the test does not print for some reason, the harness hangs.
> 
> Test that the pid is still alive while polling to fix this hang.
> 
> While here, wait for the full string "Now migrate the VM", which I think
> makes it more obvious to read and could avoid an unfortunate collision
> with some debugging output in a test case.
> 
> Signed-off-by: Nicholas Piggin <npiggin@xxxxxxxxx>

Thanks for attempting to fix this!

> ---
>  scripts/arch-run.bash | 10 +++++++++-
>  1 file changed, 9 insertions(+), 1 deletion(-)
> 
> diff --git a/scripts/arch-run.bash b/scripts/arch-run.bash
> index 518607f4..30e535c7 100644
> --- a/scripts/arch-run.bash
> +++ b/scripts/arch-run.bash
> @@ -142,6 +142,7 @@ run_migration ()
>  
>         eval "$@" -chardev socket,id=mon1,path=${qmp1},server=on,wait=off \
>                 -mon chardev=mon1,mode=control | tee ${migout1} &
> +       live_pid=`jobs -l %+ | grep "eval" | awk '{print$2}'`

Pardon my ignorance, but why would $! not work here?




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux