Skip to content

Commit 73300df

Browse files
committed
Wait for DPU reboot status only if reboot gnoi command is successful
1 parent 389ae8a commit 73300df

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

scripts/reboot_smartswitch_helper

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,9 +151,10 @@ function gnmi_reboot_dpu()
151151
if [ $? -ne 0 ]; then
152152
log_message "ERROR: Failed to send gnoi command to halt services on ${DPU_NAME}"
153153
log_message "ERROR: proceeding without halting the services"
154+
else
155+
# Wait for DPU to halt services, if reboot command is successful
156+
wait_for_dpu_reboot_status "${dpu_ip}" "${port}" "${DPU_NAME}"
154157
fi
155-
156-
wait_for_dpu_reboot_status "${dpu_ip}" "${port}" "${DPU_NAME}"
157158
}
158159

159160
function reboot_dpu()

0 commit comments

Comments
 (0)