Introduce influxdb_datadir_volume

This allows you to tune the performance of InfluxDB by locating the
volume on a drive that is separate to the default docker storage.

Change-Id: Iea555a2702b225b30f5d7035b8a703d4f3376ee7
This commit is contained in:
Will Szumski
2020-02-14 15:24:06 +00:00
parent 35c3f333e9
commit 4cf7ff9fa2
7 changed files with 43 additions and 1 deletions

View File

@@ -1041,6 +1041,7 @@ enable_vitrage_prometheus_datasource: "{{ enable_prometheus | bool }}"
# InfluxDB options
####################
influxdb_address: "{{ kolla_internal_fqdn }}"
influxdb_datadir_volume: "influxdb"
#########################
# Internal Image options

View File

@@ -9,6 +9,7 @@
glance_file_datadir_volume: "{{ glance_file_datadir_volume }}"
nova_instance_datadir_volume: "{{ nova_instance_datadir_volume }}"
gnocchi_metric_datadir_volume: "{{ gnocchi_metric_datadir_volume }}"
influxdb_datadir_volume: "{{ influxdb_datadir_volume }}"
kolla_internal_vip_address: "{{ kolla_internal_vip_address }}"
kolla_external_vip_address: "{{ kolla_external_vip_address }}"
kolla_dev_repos_directory: "{{ kolla_dev_repos_directory }}"

View File

@@ -37,6 +37,6 @@ influxdb_dimensions: "{{ default_container_dimensions }}"
influxdb_default_volumes:
- "{{ node_config_directory }}/influxdb/:{{ container_config_directory }}/:ro"
- "/etc/localtime:/etc/localtime:ro"
- "influxdb:/var/lib/influxdb"
- "{{ influxdb_datadir_volume }}:/var/lib/influxdb"
- "kolla_logs:/var/log/kolla/"
influxdb_extra_volumes: "{{ default_extra_volumes }}"

View File

@@ -9,6 +9,7 @@ logging and monitoring services available in kolla.
:maxdepth: 1
central-logging-guide
influxdb-guide
monasca-guide
osprofiler-guide
prometheus-guide

View File

@@ -0,0 +1,28 @@
.. _influxdb-guide:
===============================
InfluxDB - Time Series Database
===============================
Overview
~~~~~~~~
InfluxDB is a time series database developed by InfluxData. It is
possible to deploy a single instance without charge. To use the
clustering features you will require a commercial license.
InfluxDB
~~~~~~~~
The `recommendation <https://docs.influxdata.com/influxdb/v1.7/guides/hardware_sizing/#what-kind-of-storage-do-i-need>`_
is to use flash storage for InfluxDB. If docker is configured to use
spinning disks by default, or you have some higher performance drives
available, it may be desirable to control where the docker volume is
located. This can be achieved by setting a path for
``influxdb_datadir_volume`` in ``/etc/kolla/globals.yml``:
.. code-block:: yaml
influxdb_datadir_volume: /mnt/ssd/influxdb/
The default is to use a named volume, ``influxdb``.

View File

@@ -0,0 +1,6 @@
---
features:
- |
Adds a new variable, ``influxdb_datadir_volume``. This allows you control
where the docker volume for InfluxDB is created. A performance tuning is
to set this to a path on a high performance flash drive.

View File

@@ -63,6 +63,11 @@ if [[ "$gnocchi_metric_datadir_volume" != "gnocchi" && -d "$gnocchi_metric_datad
rm -rfv $gnocchi_metric_datadir_volume
fi
if [[ "$influxdb_datadir_volume" != "influxdb" && -d "$influxdb_datadir_volume" ]]; then
echo "Removing influxdb volume if it is customzied"
rm -rfv $influxdb_datadir_volume
fi
FOLDER_PATH="/etc/kolla/"
if [[ -e "$FOLDER_PATH/ovsdpdk-db/ovs-dpdkctl.sh" ]]; then