This topic describes how to modify minor compaction parameters.
Minor compaction parameters
| Parameter | Description | Default value | Value range |
|---|---|---|---|
| minor_compact_trigger | The threshold for triggering a minor compaction (Minor Compaction) in the form of the number of SSTables. This is a tenant-level parameter. | 2 | [0, 16] |
| freeze_trigger_percentage | The threshold for triggering a freeze in the form of the percentage of memory occupied by MemStores. This is a tenant-level parameter. | 20 | [1, 99] |
| memstore_limit_percentage | The maximum percentage of total memory allowed to MemStores. This is a cluster-level parameter. | 50 | [1, 99] |
Modify minor compaction parameters by using an SQL statement
Log in to the database as the tenant administrator.
Execute the following statements to modify the minor compaction parameters.
Here is an example:
obclient> ALTER SYSTEM SET minor_compact_trigger=2; obclient> ALTER SYSTEM SET freeze_trigger_percentage=20; obclient> ALTER SYSTEM SET memstore_limit_percentage=50;Notice
Cluster-level parameters must be set in the
systenant.After the parameters are modified, you can execute the
SHOW PARAMETERSstatement to verify whether the modification is successful.Here is an example:
obclient> SHOW PARAMETERS LIKE 'minor_compact_trigger'; obclient> SHOW PARAMETERS LIKE 'freeze_trigger_percentage'; obclient> SHOW PARAMETERS LIKE 'memstore_limit_percentage';