From b094b186180e480557d5f6b07b168ccd5e8d97f2 Mon Sep 17 00:00:00 2001 From: Zach Brown Date: Fri, 16 Oct 2020 15:20:49 -0700 Subject: [PATCH] scoutfs: compact fewer srch files each time With the introduction of incremental srch file compaction we added some fields to the srch_compact struct to record the position of compaction in each file. This increased the size of the struct past the limit the btree places on the size of item values. We decrease the number of files per compaction from 8 to 4 to cut the size of the srch_compcat struct in half. This compacts twice as often, but still relatively infrequently, and it uses half the space for srch files waiting to hit the compaction threshold. Signed-off-by: Zach Brown --- kmod/src/format.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kmod/src/format.h b/kmod/src/format.h index 6dafb382..09092b2a 100644 --- a/kmod/src/format.h +++ b/kmod/src/format.h @@ -371,7 +371,7 @@ struct scoutfs_srch_block { SCOUTFS_SRCH_ENTRY_MAX_BYTES) #define SCOUTFS_SRCH_LOG_BLOCK_LIMIT (1024 * 1024 / SCOUTFS_BLOCK_LG_SIZE) -#define SCOUTFS_SRCH_COMPACT_ORDER 3 +#define SCOUTFS_SRCH_COMPACT_ORDER 2 #define SCOUTFS_SRCH_COMPACT_NR (1 << SCOUTFS_SRCH_COMPACT_ORDER) /*