系统文件目录 data/system

  • data/system/schema/mlog.bin (元数据日志)

    SchemaFile设计
  • data/system/schema/system.properties (系统不可变参数)

partition_interval=9223372036854775807
timestamp_precision=ms
tsfile_storage_fs=LOCAL
enable_partition=false
max_degree_of_index_node=256
tag_attribute_total_size=700
iotdb_version=UNKNOWN

  • data/system/schema/tlog.txt (标签、属性文件)

    Schema Manager#TLog
  • data/system/storage_groups/{sg_name}/{vsg_id}/{partition}/Version-xxx (每个分区的版本控制文件,无内容)

  • data/system/storage_groups/upgrade/Version-xxx (升级过程的版本控制文件)

  • data/system/upgrade/upgrade.txt (升级日志文件)

格式为:

oldTsFilePath,UpgradeCheckStatus

其中 UpgradeCheckStatus 表示文件的升级状态

    • BEGIN_UPGRADE_FILE(1): 待升级的文件
    • AFTER_UPGRADE_FILE(2): 升级后的文件已经封口
    • UPGRADE_SUCCESS(3): 完成了旧文件删除,移动新文件

示例:

xxx/root.group_11/upgrade/1587634378188-101-0.tsfile,1
xxx/root.group_11/upgrade/1587634378188-101-0.tsfile,2
xxx/root.group_11/upgrade/1587634378188-101-0.tsfile,3
...
  • data/system/users/{user_name}.profile (用户信息)
username (UTF-8)
password (UTF-8)
privilegeNumber n (int)
n privileges (Privelege)
rolNumber k (int)
k role names (UTF-8)
UseWaterMarkFlag (Boolean)
  • data/system/roles/{UserID}.profile (角色信息)
roleName (UTF-8)
privilegeNumber n (int)
n privileges (Privilege)

其中 Privilege 格式为:

bindingPath (UTF-8)
privilegeNumber n (int)
n privilegeOrdinals (int)
  • data/system/compression_ration/Ratio-{origin_data_size}-{compressed_data_size} (用于计算压缩率,无内容)

           示例:

           xxx/Ratio-405756.605275-32020

           用原数据大小除以压缩后的数据大小就能得出压缩率。

  • data/system/udf/ulog.txt (UDF 注册信息)
0,DISTINCT,org.apache.iotdb.quality.dprofile.UDTFDistinct (UTF8, 注册 UDF DISTINCT,全类名 org.apache.iotdb.quality.dprofile.UDTFDistinct)
0,HISTOGRAM,org.apache.iotdb.quality.dprofile.UDTFHistogram
0,INTEGRAL,org.apache.iotdb.quality.dprofile.UDAFIntegral
1,DISTINCT (UTF8, 反注册 UDF DISTINCT)
  • data/system/udf/tmp (嵌套表达式框架的临时文件夹,用于存储框架在计算时进行内存控制产生的二进制文件,仅在查询执行时有意义)
    序列化、反序列化方法可能随版本变动,见 org.apache.iotdb.db.query.udf.datastructure.SerializableList
  • data/system/trigger/tlog.bin (触发器注册信息,二进制,格式类 mlog)

数据文件目录 data/data

  • data/data/sequence/{storage_group}/{virtual_storage_group_id}/{partition}/{timestamp}-{version}-{inner_compaction_times}-{outter_compaction_times}.tsfile (数据文件)

TsFile 文件格式#2TsFile%E7%9A%84%E6%80%BB%E8%A7%88%E5%9B%BE

  • data/data/sequence/{storage_group}/{virtual_storage_group_id}/{partition}/{tsfile}.resource (对应TsFile的设备时间索引)
deviceId(String),start_time(long)
deviceId(String),start_time(long)
deviceId(String),end_time(long)
deviceId(String),end_time(long)
  • data/data/sequence/{storage_group}/{virtual_storage_group_id}/{partition}/{tsfile}.mods (数据修改操作标记)

Query Fundamentals#QuerywithModifications

源文件
文件path
目标文件
文件path
device,offset (已经合并的设备和目标文件完整的ChunkGroup的offset)

写前日志目录 data/wal

  • data/wal/{storage_group}-{tsfile_name}/wal{x} (对应某个 TsFile 的写前日志文件)

文件格式为写入执行计划的序列化内容: InsertRowPlan、InsertTabletPlan、DeletePlan

性能追踪目录 data/tracing

  • data/tracing/tracing.txt

性能追踪选项默认关闭,用户可以使用 TRACING ON/OFF 命令开启/关闭该功能。开启后,追踪日志记录在上述目录下,其格式为:

QueryId - Start time
QueryId - Query statement
QueryId - Number of series paths
QueryId - Number of tsfiles
QueryId - Number of sequence files
QueryId - Number of unsequence files
QueryId - Number of chunks
QueryId - Average size of chunks
QueryId - End time




  • No labels