From f53c7b66cd5d26ffc91ffec926b47a5b10bc4670 Mon Sep 17 00:00:00 2001 From: mssonicbld <79238446+mssonicbld@users.noreply.github.com> Date: Sun, 23 Apr 2023 21:07:26 +0800 Subject: [PATCH] [Fast-boot] Clear teamd-timer when finalizing fast-reboot (#14583) (#14774) --- .../warmboot-finalizer/finalize-warmboot.sh | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/files/image_config/warmboot-finalizer/finalize-warmboot.sh b/files/image_config/warmboot-finalizer/finalize-warmboot.sh index 597a9cceac..29b1a934c5 100755 --- a/files/image_config/warmboot-finalizer/finalize-warmboot.sh +++ b/files/image_config/warmboot-finalizer/finalize-warmboot.sh @@ -112,6 +112,7 @@ function finalize_fast_reboot() { debug "Finalizing fast-reboot..." sonic-db-cli STATE_DB hset "FAST_RESTART_ENABLE_TABLE|system" "enable" "false" &>/dev/null + sonic-db-cli CONFIG_DB DEL "WARM_RESTART|teamd" &>/dev/null } function stop_control_plane_assistant() @@ -169,10 +170,6 @@ if [[ (x"${WARM_BOOT}" == x"true") && (x"${FAST_REBOOT}" != x"true") ]]; then stop_control_plane_assistant fi -# Save DB after stopped control plane assistant to avoid extra entries -debug "Save in-memory database after warm/fast reboot ..." -config save -y - if [[ -n "${list}" ]]; then debug "Some components didn't finish reconcile: ${list} ..." fi @@ -183,4 +180,8 @@ fi if [ x"${WARM_BOOT}" == x"true" ]; then finalize_warm_boot -fi \ No newline at end of file +fi + +# Save DB after stopped control plane assistant to avoid extra entries +debug "Save in-memory database after warm/fast reboot ..." +config save -y