diff --git a/files/scripts/swss.sh b/files/scripts/swss.sh index cb0bf202b919..bd8ada30d9d5 100755 --- a/files/scripts/swss.sh +++ b/files/scripts/swss.sh @@ -7,6 +7,7 @@ LOCKFILE="/tmp/swss-syncd-lock" function debug() { + /usr/bin/logger $1 /bin/echo `date` "- $1" >> ${DEBUGLOG} } @@ -90,6 +91,7 @@ start() { # Don't flush DB during warm boot if [[ x"$WARM_BOOT" != x"true" ]]; then + debug "Flushing databases ..." /usr/bin/docker exec database redis-cli -n 0 FLUSHDB /usr/bin/docker exec database redis-cli -n 2 FLUSHDB /usr/bin/docker exec database redis-cli -n 5 FLUSHDB diff --git a/files/scripts/syncd.sh b/files/scripts/syncd.sh index bef8ff11558c..93c01f109314 100755 --- a/files/scripts/syncd.sh +++ b/files/scripts/syncd.sh @@ -7,6 +7,7 @@ LOCKFILE="/tmp/swss-syncd-lock" function debug() { + /usr/bin/logger $1 /bin/echo `date` "- $1" >> ${DEBUGLOG} } @@ -88,7 +89,8 @@ start() { else rm -f /host/warmboot/warm-starting - # Flush DB during non-warm start + # Flush ASIC DB during non-warm start + debug "Flushing ASIC database ..." /usr/bin/docker exec database redis-cli -n 1 FLUSHDB fi