Search code examples
databasetime-seriesapache-iotdb

Why did Apache IoTDB reported error when reading tsfile before certain time interval after importing data?


In Apache IoTDB 1.1.0, I used a java program to import the data of a device from mysql to IoTDB using sessionPool.insertTablets(tablets, true) interface. Also, I had a template mounted to the upper layer of the device level. However, after the import process, the query task showed an error. After I added the time condition, I found that if the start time is less than 2023-06-07 16:55:40, this error will be reported. The error messages are: [Query-Worker-Thread-5$20230920_013953_00494_1.2.0.0] ERROR o.a.i.t.r.r.LocalTsFileInput:101 - Error happened while reading /usr/local/sailfish/apache-iotdb-1.1.0-all-bin/sbin/./../data/datanode/data/sequence/root.sailfish/0/2787/1688632177700-1-1-1.tsfile from position 135595 and Something wrong happened in reading measurementId: gpsAtMillis, datatype: INT64, version: 1, Statistics: startTime: 1685589617000 endTime: 1686128140000 count: 39131. What may be the reason for this error and how to fix it?


Solution

  • This is a known bug and you can check all the data you need by upgrading the Apache IoTDB version to 1.2.1 or above. The upgrade process is: 1. Stop all the ongoing processes of all datanodes and all confignodes. 2. Delete the version 1.1.1 lib package of all nodes, and then import the new 1.2.1 version lib package; 3. Start all configodes first, then start all datanodes