summaryrefslogtreecommitdiffstats
path: root/src/common/ceph_strings.cc
diff options
context:
space:
mode:
authorIlya Dryomov <ilya.dryomov@inktank.com>2014-02-21 15:34:13 +0100
committerIlya Dryomov <ilya.dryomov@inktank.com>2014-03-03 19:33:44 +0100
commit6456802394afd2c1da19516f71f6e06e34b5a540 (patch)
tree26c9a7f5b2155429e6db2aaf9a8ffa32f0bed961 /src/common/ceph_strings.cc
parentrgw: off-by-one in rgw_trim_whitespace() (diff)
downloadceph-6456802394afd2c1da19516f71f6e06e34b5a540.tar.xz
ceph-6456802394afd2c1da19516f71f6e06e34b5a540.zip
osd: add SETALLOCHINT operation
This is primarily for librbd/krbd's benefit and is supposed to combat fragmentation: "... knowing that rbd images have a 4m size, librbd can pass a hint that will let the osd do the xfs allocation size ioctl on new files so that they are allocated in 1m or 4m chunks. We've seen cases where users with rbd workloads have very high levels of fragmentation in xfs and this would mitigate that and probably have a pretty nice performance benefit." SETALLOCHINT is considered advisory, so our backwards compatibility mechanism here is to set FAILOK flag for all SETALLOCHINT ops. xfs is hooked up in the subsequent commits. Signed-off-by: Ilya Dryomov <ilya.dryomov@inktank.com>
Diffstat (limited to 'src/common/ceph_strings.cc')
-rw-r--r--src/common/ceph_strings.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/common/ceph_strings.cc b/src/common/ceph_strings.cc
index 686f504ce3a..ebf2f0069e7 100644
--- a/src/common/ceph_strings.cc
+++ b/src/common/ceph_strings.cc
@@ -101,7 +101,10 @@ const char *ceph_osd_op_name(int op)
case CEPH_OSD_OP_OMAPSETHEADER: return "omap-set-header";
case CEPH_OSD_OP_OMAPCLEAR: return "omap-clear";
case CEPH_OSD_OP_OMAPRMKEYS: return "omap-rm-keys";
+
+ case CEPH_OSD_OP_SETALLOCHINT: return "set-alloc-hint";
}
+
return "???";
}