How to send raw csv files to influxdb via python?


#1

I am able to send row wise data via influxdb package in python. But It takes so much of time to
send row by row data through python code on daily basis. I am using ubuntu 16.04 with influxdb 0.10 version.

Is there a way I can send the raw csv files through code in python ?


#2

python may not be the fastest way… take a look at the stresstest application influx-stress

You should be able to modify for your needs


#3

You are running a very old version of InfluxDB. The latest version is 1.5.4. I strongly recommend you upgrade. You can find instructions on how to install InfluxDB for Ubuntu here.

The InfluxDB Python client includes functionality for writing batches of points using the write_points() function. It also includes the SeriesHelper class, which “eases writing data points in bulk”.

There is no way to send CSV files to InfluxDB. The data will need to be parsed; InfluxDB can only accept line protocol, which is what the client library uses to write points.