disable_auto_compactions不生效

  • nebula 版本:2.5.1

  • 部署方式:分布式

  • 安装方式:源码编译

  • 是否为线上版本:Y

  • 硬件信息

    • SSD
    • 10graphd,3metad,10storaged
  • 问题的具体描述
    已设置disable_auto_compactions=true(见日志1,日志2)
    但是当使用sst导入后(ingest命令后)仍然会执行compact操作 (见日志3)

日志1:storage-config(meta缓存,通过show configs查得)

| "STORAGE" | "rocksdb_column_family_options"     | "map" | "MUTABLE" | {bottommost_compression: "kZSTD", compaction_options_universal: "{stop_style=kCompactionStopStyleTotalSize;compression_size_percent=-1;allow_trivial_move=true;max_merge_width=4294967295;max_size_amplification_percent=50;min_merge_width=2;size_ratio=1;}", compaction_style: "kCompactionStyleUniversal", compression: "kSnappyCompression", compression_per_level: "kNoCompression:kNoCompression:kSnappyCompression:kSnappyCompression:kSnappyCompression:kSnappyCompression:kZSTD", disable_auto_compactions: "true", hard_pending_compaction_bytes_limit: "16T", level0_file_num_compaction_trigger: "4", level0_slowdown_writes_trigger: "1K", level0_stop_writes_trigger: "4K", level_compaction_dynamic_level_bytes: "true", max_bytes_for_level_base: "256M", max_write_buffer_number: "4", max_write_buffer_number_to_maintain: "1", memtable_factory: "SkipListFactory", memtable_insert_with_hint_prefix_extractor: "rocksdb.FixedPrefix.16", memtable_whole_key_filtering: "false", min_write_buffer_number_to_merge: "1", num_levels: "7", optimize_filters_for_hits: "false", periodic_compaction_seconds: "604800", prefix_extractor: "rocksdb.FixedPrefix.16", report_bg_io_stats: "true", soft_pending_compaction_bytes_limit: "4T", table_factory: "BlockBasedTable", write_buffer_size: "67108864"} |

日志2:storage-config(直接请求http://{{storage_add}}/flags)

local_config=0
rocksdb_column_family_options="{"bottommost_compression":""kZSTD"","compaction_options_universal":""{stop_style=kCompactionStopStyleTotalSize;compression_size_percent=-1;allow_trivial_move=true;max_merge_width=4294967295;max_size_amplification_percent=50;min_merge_width=2;size_ratio=1;}"","compression":""kSnappyCompression"","compaction_style":""kCompactionStyleUniversal"","min_write_buffer_number_to_merge":""1"","compression_per_level":""kNoCompression:kNoCompression:kSnappyCompression:kSnappyCompression:kSnappyCompression:kSnappyCompression:kZSTD"","memtable_factory":""SkipListFactory"","memtable_insert_with_hint_prefix_extractor":""rocksdb.FixedPrefix.16"","num_levels":""7"","disable_auto_compactions":""true"","level_compaction_dynamic_level_bytes":""true"","hard_pending_compaction_bytes_limit":""16T"","level0_slowdown_writes_trigger":""1K"","level0_stop_writes_trigger":""4K"","optimize_filters_for_hits":""false"","level0_file_num_compaction_trigger":""4"","report_bg_io_stats":""true"","max_bytes_for_level_base":""256M"","max_write_buffer_number":""4"","write_buffer_size":""67108864"","max_write_buffer_number_to_maintain":""1"","memtable_whole_key_filtering":""false"","periodic_compaction_seconds":""604800"","prefix_extractor":""rocksdb.FixedPrefix.16"","soft_pending_compaction_bytes_limit":""4T"","table_factory":""BlockBasedTable""}"

日志3:storage节点info日志,日志显示在ingest后自动触发了compact
(备注:SSTFile ingest successfully是我这里添加用于调试的日志)

E0429 15:49:36.708761 2750430 StorageHttpIngestHandler.cpp:78] SSTFile ingest successfully
I0429 15:49:41.487911 2749956 EventListener.h:30] Rocksdb compaction completed column family: default because of UniversalSizeRatio, status: OK, compacted 102 files into 5, base level is 0, output level is 2
I0429 15:49:41.497674 2749953 EventListener.h:18] Rocksdb start compaction column family: default because of UniversalSizeRatio, status: OK, compacted 102 files into 0, base level is 0, output level is 2
I0429 15:49:41.497999 2749953 CompactionFilter.h:66] Do default minor compaction!
I0429 15:49:41.498024 3638330 CompactionFilter.h:66] Do default minor compaction!
I0429 15:49:44.003566 2749954 EventListener.h:30] Rocksdb compaction completed column family: default because of UniversalSizeRatio, status: OK, compacted 101 files into 6, base level is 0, output level is 2
I0429 15:49:44.022289 2749955 EventListener.h:18] Rocksdb start compaction column family: default because of UniversalSizeRatio, status: OK, compacted 102 files into 0, base level is 0, output level is 2
I0429 15:49:44.022593 2749955 CompactionFilter.h:66] Do default minor compaction!
I0429 15:49:44.022627 3638334 CompactionFilter.h:66] Do default minor compaction!

仅使用sst导入后才出现是吗

观察了几天,确定是只有在sst导入后出现,停止sst导入后,放置2天都没有出现自动compact

参数修改后是否重启了服务,这个参数是要重启生效的

1 个赞

此话题已在最后回复的 30 天后被自动关闭。不再允许新回复。