Skip to content

Commit

Permalink
add warning log in AutoCompactRange(), when there is not enough disk …
Browse files Browse the repository at this point in the history
…space left to exec compact task (#722)
  • Loading branch information
Axlgrep authored Aug 13, 2019
1 parent 754d15d commit c845cf2
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/pika_server.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1361,6 +1361,9 @@ void PikaServer::AutoCompactRange() {
LOG(INFO) << "[Interval]schedule compactRange Failed, freesize: " << free_size/1048576 << "MB, disksize: " << total_size/1048576
<< "MB, error: " << s.ToString();
}
} else {
LOG(WARNING) << "compact-interval failed, because there is not enough disk space left, freesize"
<< free_size/1048576 << "MB, disksize: " << total_size/1048576 << "MB";
}
}
return;
Expand Down Expand Up @@ -1393,6 +1396,9 @@ void PikaServer::AutoCompactRange() {
<< "MB, error: " << s.ToString();
}
have_scheduled_crontask_ = true;
} else {
LOG(WARNING) << "compact-cron failed, because there is not enough disk space left, freesize"
<< free_size/1048576 << "MB, disksize: " << total_size/1048576 << "MB";
}
}
}
Expand Down

0 comments on commit c845cf2

Please sign in to comment.