如何判断系统参数的生效范围

OB中可以通过show parameters命令查看系统参数列表,那么怎么确定参数的生效范围呢?

黑屏查询对应参数列表后,可以查看scope字段,判断参数的生效范围,是cluster还是tenant。

MySQL [oceanbase]> show parameters like ‘memstore_limit_percentage’;
±------±---------±--------------±---------±--------------------------±----------±------±------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------±--------±--------±--------±------------------+
| zone | svr_type | svr_ip | svr_port | name | data_type | value | info | section | scope | source | edit_level |
±------±---------±--------------±---------±--------------------------±----------±------±------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------±--------±--------±--------±------------------+
| zone2 | observer | 11.166.86.112 | 2882 | memstore_limit_percentage | NULL | 60 | used in calculating the value of MEMSTORE_LIMIT parameter: memstore_limit_percentage = memstore_limit / min_memory,min_memory, where MIN_MEMORY is determined when the tenant is created. Range: (0, 100) | TENANT | CLUSTER | DEFAULT | DYNAMIC_EFFECTIVE |
| zone3 | observer | 11.166.85.177 | 2882 | memstore_limit_percentage | NULL | 60 | used in calculating the value of MEMSTORE_LIMIT parameter: memstore_limit_percentage = memstore_limit / min_memory,min_memory, where MIN_MEMORY is determined when the tenant is created. Range: (0, 100) | TENANT | CLUSTER | DEFAULT | DYNAMIC_EFFECTIVE |
| zone1 | observer | 11.166.86.111 | 2882 | memstore_limit_percentage | NULL | 60 | used in calculating the value of MEMSTORE_LIMIT parameter: memstore_limit_percentage = memstore_limit / min_memory,min_memory, where MIN_MEMORY is determined when the tenant is created. Range: (0, 100) | TENANT | CLUSTER | DEFAULT | DYNAMIC_EFFECTIVE |
±------±---------±--------------±---------±--------------------------±----------±------±------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------±--------±--------±--------±------------------+