diff --git a/src/mon/OSDMonitor.cc b/src/mon/OSDMonitor.cc index ba74a1b118e..c62c596f74b 100644 --- a/src/mon/OSDMonitor.cc +++ b/src/mon/OSDMonitor.cc @@ -525,11 +525,11 @@ int OSDMonitor::reweight_by_utilization(int oload, std::string& out_str, ostringstream oss; char buf[128]; - snprintf(buf, sizeof(buf), "average_util: %04f, overload_util: %04f. ", + snprintf(buf, sizeof(buf), "average %04f, overload %04f. ", average_util, overload_util); oss << buf; std::string sep; - oss << "overloaded osds: "; + oss << "reweighted: "; bool changed = false; for (ceph::unordered_map::const_iterator p = pgm.osd_stat.begin(); @@ -550,7 +550,7 @@ int OSDMonitor::reweight_by_utilization(int oload, std::string& out_str, unsigned new_weight = (unsigned)((average_util / util) * (float)weight); pending_inc.new_weight[p->first] = new_weight; char buf[128]; - snprintf(buf, sizeof(buf), "%d [%04f -> %04f]", p->first, + snprintf(buf, sizeof(buf), "osd.%d [%04f -> %04f]", p->first, (float)weight / (float)0x10000, (float)new_weight / (float)0x10000); oss << buf << sep; @@ -566,7 +566,7 @@ int OSDMonitor::reweight_by_utilization(int oload, std::string& out_str, sep = ", "; pending_inc.new_weight[p->first] = new_weight; char buf[128]; - snprintf(buf, sizeof(buf), "%d [%04f -> %04f]", p->first, + snprintf(buf, sizeof(buf), "osd.%d [%04f -> %04f]", p->first, (float)weight / (float)0x10000, (float)new_weight / (float)0x10000); oss << buf << sep;