diff --git a/internal/stats/stats.go b/internal/stats/stats.go index e483dbba41f..2504bb336e5 100644 --- a/internal/stats/stats.go +++ b/internal/stats/stats.go @@ -403,10 +403,12 @@ func (s *StatsCtx) flush() (cont bool, sleepFor time.Duration) { derr := tx.DeleteBucket(idToUnitName(id - limit)) if derr != nil { - log.Error("stats: deleting unit: %s", derr) + logFunc := log.Error if !errors.Is(derr, bbolt.ErrBucketNotFound) { isCommitable = false + logFunc = log.Debug } + logFunc("stats: deleting unit: %s", derr) } err = finishTxn(tx, isCommitable)