From de85baaa9593b6c24ed8a7254d9caf70b950eadd Mon Sep 17 00:00:00 2001 From: Dmitry Tantsur Date: Wed, 25 Sep 2019 16:49:22 +0200 Subject: [PATCH] Run DIB with tracing enabled and increase the DHCP timeout We seem to be hitting occasional failures to DHCP in time, although DHCP itself seems working. Try increasing timeout from 30 to 60. Also enable tracing when building the image, so that this sort of issues is a bit easier to debug without unpacking the image. Change-Id: If3f00ba39daf72739802c46c5c6c64cfbb6ab0ae --- devstack/lib/ironic | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/devstack/lib/ironic b/devstack/lib/ironic index c50a67fb26..981d04cfb8 100644 --- a/devstack/lib/ironic +++ b/devstack/lib/ironic @@ -283,6 +283,8 @@ fi # to build the dib based ironic-python-agent ramdisk. # "centos7 dhcp-all-interfaces" is set since the default value "ubuntu" has some network issue. IRONIC_DIB_RAMDISK_OPTIONS=${IRONIC_DIB_RAMDISK_OPTIONS:-'centos7 dhcp-all-interfaces'} +# DHCP timeout for the dhcp-all-interfaces element. +IRONIC_DIB_DHCP_TIMEOUT=${IRONIC_DIB_DHCP_TIMEOUT:-60} # Some drivers in Ironic require deploy ramdisk in bootable ISO format. # Set this variable to "true" to build an ISO for deploy ramdisk and @@ -2520,9 +2522,10 @@ function build_ipa_dib_ramdisk { fi git_clone $IRONIC_PYTHON_AGENT_BUILDER_REPO $IRONIC_PYTHON_AGENT_BUILDER_DIR ELEMENTS_PATH="$IRONIC_PYTHON_AGENT_BUILDER_DIR/dib" \ - disk-image-create "$IRONIC_DIB_RAMDISK_OPTIONS" \ - -o "$tempdir/ironic-agent" \ - ironic-python-agent-ramdisk + DIB_DHCP_TIMEOUT=$IRONIC_DIB_DHCP_TIMEOUT \ + disk-image-create "$IRONIC_DIB_RAMDISK_OPTIONS" \ + -x -o "$tempdir/ironic-agent" \ + ironic-python-agent-ramdisk chmod -R +r $tempdir mv "$tempdir/ironic-agent.kernel" "$kernel_path" mv "$tempdir/ironic-agent.initramfs" "$ramdisk_path"