diff --git a/ansible/roles/influxdb/defaults/main.yml b/ansible/roles/influxdb/defaults/main.yml index f6e8596bbc0fa82f922e0d8b03306850f8ec43bd..9d5d914f4a9ea35c14a62701793276aa0deee312 100644 --- a/ansible/roles/influxdb/defaults/main.yml +++ b/ansible/roles/influxdb/defaults/main.yml @@ -25,6 +25,14 @@ influxdb_services: external: false port: "{{ influxdb_http_port }}" +#################### +# InfluxDB +#################### + +# Enable the disk based time series index (recommended for all users). For +# more information see here: +# https://docs.influxdata.com/influxdb/v1.7/concepts/time-series-index/ +influxdb_enable_tsi: True #################### # Docker diff --git a/ansible/roles/influxdb/templates/influxdb.conf.j2 b/ansible/roles/influxdb/templates/influxdb.conf.j2 index e3723732677a7b4b1c73f2c4c4137021261d475a..93f5e8249452cb3cdbdc947048c802c5f50bfc9d 100644 --- a/ansible/roles/influxdb/templates/influxdb.conf.j2 +++ b/ansible/roles/influxdb/templates/influxdb.conf.j2 @@ -11,6 +11,11 @@ reporting-disabled = true wal-dir = "/var/lib/influxdb/wal" wal-logging-enabled = true data-logging-enabled = true +{% if influxdb_enable_tsi | bool %} + index-version = "tsi1" +{% else %} + index-version = "inmem" +{% endif %} [coordinator] write-timeout = "10s" max-concurrent-queries = 0 diff --git a/releasenotes/notes/enable-influxdb-tsi-858cc95e99605107.yaml b/releasenotes/notes/enable-influxdb-tsi-858cc95e99605107.yaml new file mode 100644 index 0000000000000000000000000000000000000000..5ae348c550c1a09b57cfee6444ce9537127cbdd9 --- /dev/null +++ b/releasenotes/notes/enable-influxdb-tsi-858cc95e99605107.yaml @@ -0,0 +1,10 @@ +--- +upgrade: + - InfluxDB TSI has been enabled by default. It is recommended for all + customers by InfluxData. If you do not want to enable it you can set + the variable 'influxdb_enable_tsi' to 'False' in 'globals.yml'. + Instructions to migrate existing data to the new, disk based format + can be found at + https://docs.influxdata.com/influxdb/v1.7/administration/upgrading/ + If you do not follow the migration proceedure, InfluxDB should continue + to work, but this is not recommended.