Auto extend the timeout for RAX hosts

Rax hosts uses qemu software emulated VMs without leveraging the
magic with-in the processors to help ensure speedy execution.

As such, they can be substantially slower in some operations, such
decompressing ramdisks. This adds an unpredictable element into our
CI and causes job failures when they should ahve succeeded, which
causes more rechecks, which consumes more resources... and the cycle
continues.

So instead, we'll extend the timeout a little, to hopefully give the
job time to complete without causing failures.

Change-Id: I0cd08e527763f0626fd1e43cc3b87163a4b0d018
This commit is contained in:
Julia Kreger 2020-07-17 16:16:59 -07:00
parent c871622ff5
commit 3750ba62df
1 changed files with 11 additions and 0 deletions

View File

@ -164,6 +164,17 @@ if [[ -n "$BUILD_TIMEOUT" ]]; then
echo "WARNING: BUILD_TIMEOUT variable is renamed to IRONIC_TEMPEST_BUILD_TIMEOUT and will be deprecated in Pike."
fi
hostdomain=$(hostname)
if [[ "$hostdomain" =~ "rax" ]]; then
echo "WARNING: Auto-increasing the requested build timeout by 1.5 as the detected hostname suggests a cloud host where VMs are software emulated."
# NOTE(TheJulia): Rax hosts are entirely qemu emulated, not CPU enabled
# virtualization. As such, the ramdisk decompression is known to take an
# eceptional amount of time and we need to afford a little more time to
# these hosts for jobs to complete without issues.
new_timeout=$(echo "$IRONIC_TEMPEST_BUILD_TIMEOUT * 1.5 / 1" | bc)
IRONIC_TEMPEST_BUILD_TIMEOUT=$new_timeout
fi
IRONIC_DEFAULT_API_VERSION=${IRONIC_DEFAULT_API_VERSION:-}
IRONIC_CMD="openstack baremetal"
if [[ -n "$IRONIC_DEFAULT_API_VERSION" ]]; then