首批通过分布式安全可靠测评,为关键业务系统打造
storage_meta_cache_priority
更新时间:2026-04-10 11:58:02
storage_meta_cache_priority 用于控制 kvcache 中存储 Meta Cache 的优先级。
说明
该配置项从 V4.2.0 版本开始引入。
| 属性 | 描述 |
|---|---|
| 参数类型 | INT |
| 默认值 | 10 |
| 取值范围 | [1,+∞) |
| 是否重启 OBServer 节点生效 | 否 |
OceanBase 数据库将 Table Store、SSTable 等元数据统一抽象为存储 Meta,并将其放入 kvcache 内存中统一管理。当出现 Meta Cache 使用不高或频繁未命中的时候,用户可以根据负载的特征,改变其优先级,使得有限 kvcache 内存资源的使用效率更高,更灵活。
在 kvcache 中,Cache 的优先级数值越大,优先级越高,占用的内存越不容易被淘汰。已有的几种 Cache 类型的优先级配置项如下:
tablet_ls_cache_priority,其默认值为 1000,取值范围为 [1,+∞)。
opt_tab_stat_cache_priority,其默认值为 1,取值范围为 [1,+∞)。
index_block_cache_priority,其默认值为 10,取值范围为 [1,+∞)。
user_block_cache_priority,其默认值为 1,取值范围为 [1,+∞)。
user_row_cache_priority,其默认值为 1,取值范围为 [1,+∞)。
bf_cache_priority,其默认值为 1,取值范围为 [1,+∞)。
fuse_row_cache_priority,其默认值为 1,取值范围为 [1,+∞)。
需要注意的是,存储 Meta 优先级的缺省值与 index_block_cache_priority 一致,仅次于 tablet_ls_cache_priority。
示例
ALTER SYSTEM SET set storage_meta_cache_priority='10';