From 96fb35624060565e02e946a970b3e777071bde9c Mon Sep 17 00:00:00 2001 From: Raghavendra G Date: Thu, 24 Nov 2016 14:58:20 +0530 Subject: performance/readdir-ahead: limit cache size This patch introduces a new option called "rda-cache-limit", which is the maximum value the entire readdir-ahead cache can grow into. Since, readdir-ahead holds a reference to inode through dentries, this patch also accounts memory stored by various xlators in inode contexts. Change-Id: I84cc0ca812f35e0f9041f8cc71effae53a9e7f99 BUG: 1356960 Signed-off-by: Raghavendra G Reviewed-on: http://review.gluster.org/16137 NetBSD-regression: NetBSD Build System Reviewed-by: Poornima G Smoke: Gluster Build System CentOS-regression: Gluster Build System --- xlators/mgmt/glusterd/src/glusterd-volume-set.c | 27 ++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) (limited to 'xlators/mgmt/glusterd/src/glusterd-volume-set.c') diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-set.c b/xlators/mgmt/glusterd/src/glusterd-volume-set.c index 68c57fc10cb..d9d6bc2bf7c 100644 --- a/xlators/mgmt/glusterd/src/glusterd-volume-set.c +++ b/xlators/mgmt/glusterd/src/glusterd-volume-set.c @@ -2625,7 +2625,6 @@ struct volopt_map_entry glusterd_volopt_map[] = { "option. Unmount and delete the shared storage volume " " on disabling this option." }, - #if USE_GFDB /* no GFDB means tiering is disabled */ /* tier translator - global tunables */ { .key = "cluster.write-freq-threshold", @@ -3089,6 +3088,32 @@ struct volopt_map_entry glusterd_volopt_map[] = { .op_version = GD_OP_VERSION_3_8_4, .flags = OPT_FLAG_CLIENT_OPT }, + { .key = "performance.rda-request-size", + .voltype = "performance/readdir-ahead", + .option = "rda-request-size", + .flags = OPT_FLAG_CLIENT_OPT, + .type = DOC, + .op_version = GD_OP_VERSION_3_9_1, + }, + { .key = "performance.rda-low-wmark", + .voltype = "performance/readdir-ahead", + .option = "rda-low-wmark", + .type = DOC, + .flags = OPT_FLAG_CLIENT_OPT, + .op_version = GD_OP_VERSION_3_9_1, + }, + { .key = "performance.rda-high-wmark", + .voltype = "performance/readdir-ahead", + .type = DOC, + .flags = OPT_FLAG_CLIENT_OPT, + .op_version = GD_OP_VERSION_3_9_1, + }, + { .key = "performance.rda-cache-limit", + .voltype = "performance/readdir-ahead", + .type = DOC, + .flags = OPT_FLAG_CLIENT_OPT, + .op_version = GD_OP_VERSION_3_9_1, + }, { .key = NULL } }; -- cgit