From 34c1624213eacff704fe8145a8d68d904a534529 Mon Sep 17 00:00:00 2001 From: Simon Deziel Date: Sun, 21 Apr 2024 16:03:29 -0400 Subject: [PATCH] test/includes/microcloud: tweak lxd_wait_vm() Signed-off-by: Simon Deziel --- microcloud/test/includes/microcloud.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/microcloud/test/includes/microcloud.sh b/microcloud/test/includes/microcloud.sh index dc1b84455..e06d2c940 100644 --- a/microcloud/test/includes/microcloud.sh +++ b/microcloud/test/includes/microcloud.sh @@ -1073,7 +1073,7 @@ lxd_wait_vm() { name="${1}" echo "==> ${name} Awaiting VM..." - for round in $(seq 160); do + for round in $(seq 0 5 150); do if [ "$(lxc list -f csv -c s "${name}")" = "READY" ] ; then wait_snapd "${name}" echo " ${name} VM is ready" @@ -1081,12 +1081,12 @@ lxd_wait_vm() { fi # Sometimes the VM just won't start, so retry after 3 minutes. - if [ "$((round % 45))" = 0 ]; then + if [ "$((round % 60))" = 0 ]; then echo "==> ${name} Timeout (${round}s): Re-initializing VM" lxc restart "${name}" --force fi - sleep 4 + sleep 5 done echo " ${name} VM failed to start"