Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rbd: pool_percent_used should not divided by 100 #20795

Merged
merged 1 commit into from
Mar 8, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/tools/rbd/action/Trash.cc
Original file line number Diff line number Diff line change
Expand Up @@ -421,7 +421,7 @@ int execute_purge (const po::variables_map &vm,
for(uint8_t i = 0; i < arr.size(); ++i) {
if(arr[i].get_obj()["name"] == pool_name) {
json_spirit::mObject stats = arr[i].get_obj()["stats"].get_obj();
pool_percent_used = stats["percent_used"].get_real() / 100;
pool_percent_used = stats["percent_used"].get_real();
if(pool_percent_used <= threshold) {
std::cout << "rbd: pool usage is lower than or equal to "
<< (threshold*100)
Expand Down