Influxdb: import old data

I have been running Influxdb for about a year and a half now. 3 months ago an issue with the Influxdb database occurred (suddenly disksize spiked from 1gb to about 28gb). I back then decided to do a clean install of everything and I have thus lost all historic data. Of course I have a backup of the files and have managed to remove the spikes from it (it was 1 data folder that grew too much and I have simply deleted it).

I now regret having discarded that historic data and would like to see if I can merge it back into the current database. Sensor names etc. are still the same.

Would it work if I simply import the old database, hoping that influxdb is smart enough to understand it is older data for the same set of sensors?

I am not sure what you mean by an import, but I followed their procedure to restore backed up data once and it replaced all the existing data with the contents of the backup.

Ok, let me explain:

I have a backup of data of sensor “Garden lighting” with measurements from 1-1-2017 to 1-10-2017. I also have a running database with data of sensor “garden lighting” with measurements from 2-10-2017 until now.

My question is: if I import the old data into the current database will the data of 2-10-2017 until now remain in there or will it be overwritten?

Again, I am not sure what you mean by an ‘import’. But the restore procedure documented here - Back up and restore data in InfluxDB v1.8 | InfluxDB OSS v1 Documentation results in the entire db being overwritten - it doesn’t do a merge.

There may, of course, be another procedure I’m not aware of that takes the backup file and does an import

Thanks for the tip! I am indeed looking for a solution to merge the two databases. Will continue searching for it…