From: Sridhar Seshasayee Date: Wed, 15 May 2019 09:56:52 +0000 (+0530) Subject: mon/OSDMonitor: Use generic priority cache tuner for mon caches X-Git-Tag: v15.1.0~1912^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=3b96417e189111d70bc3849361a80a674daec5ec;p=ceph.git mon/OSDMonitor: Use generic priority cache tuner for mon caches Use priority cache manager to tune inc, full and rocksdb caches. Signed-off-by: Sridhar Seshasayee --- diff --git a/doc/rados/configuration/mon-config-ref.rst b/doc/rados/configuration/mon-config-ref.rst index fd10763f30fe..7a0c1c34d6c5 100644 --- a/doc/rados/configuration/mon-config-ref.rst +++ b/doc/rados/configuration/mon-config-ref.rst @@ -1196,6 +1196,26 @@ Miscellaneous :Type: Integer :Default: 300 +``mon osd cache size min`` + +:Description: The minimum amount of bytes to be kept mapped in memory for osd + monitor caches. +:Type: 64-bit Integer +:Default: 134217728 + +``mon memory target`` + +:Description: The amount of bytes pertaining to osd monitor caches and kv cache + to be kept mapped in memory with cache auto-tuning enabled. +:Type: 64-bit Integer +:Default: 2147483648 + +``mon memory autotune`` + +:Description: Autotune the cache memory being used for osd monitors and kv + database. +:Type: Boolean +:Default: True .. _Paxos: https://en.wikipedia.org/wiki/Paxos_(computer_science) diff --git a/src/common/legacy_config_opts.h b/src/common/legacy_config_opts.h index df13b12c80f5..55ebc175f293 100644 --- a/src/common/legacy_config_opts.h +++ b/src/common/legacy_config_opts.h @@ -190,6 +190,9 @@ OPTION(mon_compact_on_bootstrap, OPT_BOOL) // trigger leveldb compaction on boo OPTION(mon_compact_on_trim, OPT_BOOL) // compact (a prefix) when we trim old states OPTION(mon_osd_cache_size, OPT_INT) // the size of osdmaps cache, not to rely on underlying store's cache +OPTION(mon_osd_cache_size_min, OPT_U64) // minimum amount of memory to cache osdmaps +OPTION(mon_memory_target, OPT_U64) // amount of mapped memory for osdmaps +OPTION(mon_memory_autotune, OPT_BOOL) // autotune cache memory for osdmap OPTION(mon_cpu_threads, OPT_INT) OPTION(mon_osd_mapping_pgs_per_chunk, OPT_INT) OPTION(mon_clean_pg_upmaps_per_chunk, OPT_U64) diff --git a/src/common/options.cc b/src/common/options.cc index 989a2cea6873..3fd650183bd5 100644 --- a/src/common/options.cc +++ b/src/common/options.cc @@ -1330,6 +1330,23 @@ std::vector