可以通过重启或以下命令生效
使支持热加载的配置项改动立即生效。 对于已经写在配置文件中修改过的配置项,从配置文件中删除或注释后再进行 load configuration 将恢复默认值。
load configuration
设置配置项
set configuration 'key1' = 'value1' 'key2' = 'value2'... (on nodeId)
set configuration 'enable_cross_space_compaction' = 'false'
对集群所有节点永久生效,设置 enable_cross_space_compaction 为 false,并写入到 iotdb-system.properties 中。
set configuration 'enable_cross_space_compaction' ='false' 'enable_seq_space_compaction' = 'false' on 1
对 nodeId 为 1 的节点永久生效,设置 enable_cross_space_compaction 为 false,设置 enable_seq_space_compaction 为 false,并写入到 iotdb-system.properties 中。
set configuration 'enable_cross_space_compaction' = 'false' 'timestamp_precision' = 'ns'
对集群所有节点永久生效,设置 enable_cross_space_compaction 为 false,timestamp_precision 为 ns,并写入到 iotdb-system.properties 中。但是,timestamp_precision 是第一次启动后就无法修改的配置项,因此会忽略这个配置项的更新,返回如下。
Msg: org.apache.iotdb.jdbc.IoTDBSQLException: 301: ignored config items: [timestamp_precision]
支持热加载立即生效的配置项在 iotdb-system.properties.template 文件中标记 effectiveMode 为 hot_reload 示例
# Used for indicate cluster name and distinguish different cluster. # If you need to modify the cluster name, it's recommended to use [set configuration 'cluster_name'='xxx'] sql. # Manually modifying configuration file is not recommended, which may cause node restart fail. # effectiveMode: hot_reload # Datatype: string cluster_name=defaultCluster