Note
Due to the architecture changes in V4.x, this parameter is no longer applicable and was removed starting from V4.0.0.
Description
ilog_index_expire_time specifies the maximum time for which Ilog files can be read by an OBServer node.
Attributes
| Attribute | Description |
|---|---|
| Type | Time type |
| Default value | 60d, which indicates 60 days |
| Value range | [0s,120d) |
| Effective upon OBServer node restart | No |
Considerations
In OceanBase Database, the file_id_cache caches the metadata information of all Ilog files and records the starting log ID and timestamp of each partition in these Ilog files. By default, file_id_cache is cleared only when an Ilog file is deleted. Therefore, on machines with large disk space, file_id_cache may occupy a significant amount of memory. This issue is further exacerbated when partitions are frequently created and deleted.
You can adjust the value of the ilog_index_expire_time parameter to reduce the memory usage of file_id_cache. ilog_index_expire_time specifies the maximum time for which Ilog files can be read by an OBServer node. Ilog files that exceed this time limit are not cached in file_id_cache, thereby reducing memory usage.
When you set the value of this parameter:
If you shorten the time limit specified by this parameter, the system will quickly clear the memory usage of
file_id_cache. After the setting takes effect, you can query the memory usage ofob_csr_file_id_cacheto observe the changes.If you extend the time limit specified by this parameter, the system will cache Ilog files with a larger time span after the machine restarts.
Examples
obclient> ALTER SYSTEM SET ilog_index_expire_time = '7d';