]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: reformat osd map dump
authorSage Weil <sage@newdream.net>
Thu, 23 Apr 2009 22:53:50 +0000 (15:53 -0700)
committerSage Weil <sage@newdream.net>
Thu, 23 Apr 2009 22:53:50 +0000 (15:53 -0700)
src/osd/OSDMap.cc

index 7f3ee8a9d37d2ad6910c70bda54208591c223ad8..79b231586b80c9fada29d286f86877338e1445c2 100644 (file)
@@ -35,17 +35,17 @@ void OSDMap::print(ostream& out)
   for (int i=0; i<get_max_osd(); i++) {
     if (exists(i)) {
       out << "osd" << i;
-      out << (is_up(i) ? " up":" down");
-      if (is_up(i))
-       out << " " << get_addr(i);
+      out << (is_in(i) ? " in":" out");
+      if (is_in(i))
+       out << " weight " << get_weightf(i);
+      out << (is_up(i) ? " up  ":" down");
       osd_info_t& info = get_info(i);
       out << " (up_from " << info.up_from
          << " up_thru " << info.up_thru
          << " down_at " << info.down_at
          << " last_clean " << info.last_clean_first << "-" << info.last_clean_last << ")";
-      out << (is_in(i) ? " in":" out");
-      if (is_in(i))
-       out << " weight " << get_weightf(i);
+      if (is_up(i))
+       out << " " << get_addr(i);
       out << "\n";
     }
   }