优化磁盘速度检查

This commit is contained in:
GoEdgeLab
2023-08-02 11:34:14 +08:00
parent be80256aab
commit 74e64e8717
4 changed files with 60 additions and 14 deletions

View File

@@ -485,7 +485,7 @@ func (this *MemoryStorage) startFlush() {
statCount = 0
// delay some time to reduce load if needed
if !fsutils.DiskIsFast {
if !fsutils.DiskIsFast() {
loadStat, err := load.Avg()
if err == nil && loadStat != nil {
if loadStat.Load1 > 10 {