From a0b316c7ac27d6533259c9462f209bd010a08163 Mon Sep 17 00:00:00 2001 From: Yuiko Takada Mori Date: Thu, 27 Oct 2016 15:15:02 +0900 Subject: [PATCH] Correct log the node UUID on failure Correct log the node UUID in the DevStack when it fails to add/update the network_interface. Prior to this patch some gibberish was being logged due to a broken grep. Change-Id: I25206b9a34091bfb18528e39a4885fbfc10a7bd3 --- devstack/lib/ironic | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devstack/lib/ironic b/devstack/lib/ironic index dad2d7ce27..38bb9b51bf 100644 --- a/devstack/lib/ironic +++ b/devstack/lib/ironic @@ -1181,7 +1181,7 @@ function enroll_nodes { if [[ -n "${IRONIC_NETWORK_INTERFACE}" ]]; then local n_id ironic node-set-maintenance $node_id true - n_id=$(ironic $ironic_api_version node-update $node_id add network_interface=$IRONIC_NETWORK_INTERFACE) + n_id=$(ironic $ironic_api_version node-update $node_id add network_interface=$IRONIC_NETWORK_INTERFACE | grep " uuid " | awk '{ print $4; }') die_if_not_set $LINENO n_id "Failed to update network interface for node" ironic node-set-maintenance $node_id false fi