Overview
The schema_history_expire_time parameter can be used to specify the range of complete metadata history data to retain and the retention period for tenants subject to delayed deletion.
Privilege requirements
Query parameters
The
systenant and all user tenants can use theSHOW PARAMETERSstatement or theGV$OB_PARAMETERSview to query this parameter.Modify parameters
Only the
systenant can modify this parameter. User tenants cannot modify it.
Attributes
Attribute |
Description |
|---|---|
| Parameter type | Time |
| Default Value | 7d, where d indicates days. |
| Value range | [1m, 30d] |
| Modifiable | Yes, you can use theALTER SYSTEM SETStatement modification. |
| Whether to restart the OBServer node for the change to take effect | No, the setting takes effect immediately. |
Configuration example
Set the retention period for complete metadata history data to 7 days.
obclient> ALTER SYSTEM SET schema_history_expire_time = '7d';
When the value of this parameter is set to 7d, it indicates that the complete metadata history data generated within the last 7 days needs to be retained, while earlier metadata history data can be recycled by the Metadata History Data Recycling Service. For more information about the Metadata History Data Recycling Service, see schema_history_recycle_interval.