expect_false "ceph osd blacklist $bl/foo"
ceph osd crush tunables legacy
+ceph osd crush show-tunables | grep argonaut
ceph osd crush tunables bobtail
+ceph osd crush show-tunables | grep bobtail
# how do I tell when these are done?
ceph osd scrub 0
COMMAND("osd crush tunables " \
"name=profile,type=CephChoices,strings=legacy|argonaut|bobtail|optimal|default", \
"set crush tunables values to <profile>", "osd", "rw", "cli,rest")
+COMMAND("osd crush show-tunables", \
+ "show current crush tunables", "osd", "r", "cli,rest")
COMMAND("osd crush rule create-simple " \
"name=name,type=CephString,goodchars=[A-Za-z0-9-_.] " \
"name=root,type=CephString,goodchars=[A-Za-z0-9-_.] " \
f->flush(rs);
rs << "\n";
rdata.append(rs.str());
+ } else if (prefix == "osd crush show-tunables") {
+ string format;
+ cmd_getval(g_ceph_context, cmdmap, "format", format, string("json-pretty"));
+ Formatter *fp = new_formatter(format);
+ if (!fp)
+ fp = new_formatter("json-pretty");
+ boost::scoped_ptr<Formatter> f(fp);
+ f->open_object_section("crush_map_tunables");
+ osdmap.crush->dump_tunables(f.get());
+ f->close_section();
+ ostringstream rs;
+ f->flush(rs);
+ rs << "\n";
+ rdata.append(rs.str());
} else {
// try prepare update
return false;