# to track the number of instances running and the versions, which
# is very helpful for us.
# Change this option to true to disable reporting.
-reporting-disabled = false
+reporting-disabled = {{ server.reporting_disabled | lower }}
# we'll try to get the hostname automatically, but if it the os returns something
# that isn't resolvable by other servers in the cluster, use this option to
### about the InfluxDB cluster.
###
+{%- if server.meta.enabled %}
[meta]
# Where the metadata/raft database is stored
- dir = "/var/lib/influxdb/meta"
+ dir = "{{ server.meta.dir }}"
retention-autocreate = true
# The default duration for leases.
lease-duration = "1m0s"
+{%- else %}
+[meta]
+ enabled = false
+{%- endif %}
+ {%- if server.get('meta', {}).bind is defined %}
+ bind-address = "{{ server.meta.bind.address }}:{{ server.admin.bind.port }}"
+ http-bind-address = "{{ server.meta.bind.http_address }}:{{ server.admin.bind.http_port }}"
+ {%- endif %}
###
### [data]
### defaults should work for most systems.
###
+{%- if server.data.enabled %}
[data]
# Controls if this node holds time series data shards in the cluster
enabled = true
-
- dir = "/var/lib/influxdb/data"
-
- # These are the WAL settings for the storage engine >= 0.9.3
- wal-dir = "/var/lib/influxdb/wal"
- wal-logging-enabled = true
- data-logging-enabled = true
-
- # Whether queries should be logged before execution. Very useful for troubleshooting, but will
- # log any sensitive data contained within a query.
- # query-log-enabled = true
-
- # Settings for the TSM engine
-
- # CacheMaxMemorySize is the maximum size a shard's cache can
- # reach before it starts rejecting writes.
- # cache-max-memory-size = 524288000
-
- # CacheSnapshotMemorySize is the size at which the engine will
- # snapshot the cache and write it to a TSM file, freeing up memory
- # cache-snapshot-memory-size = 26214400
-
- # CacheSnapshotWriteColdDuration is the length of time at
- # which the engine will snapshot the cache and write it to
- # a new TSM file if the shard hasn't received writes or deletes
- # cache-snapshot-write-cold-duration = "1h"
-
- # MinCompactionFileCount is the minimum number of TSM files
- # that need to exist before a compaction cycle will run
- # compact-min-file-count = 3
-
- # CompactFullWriteColdDuration is the duration at which the engine
- # will compact all TSM files in a shard if it hasn't received a
- # write or delete
- # compact-full-write-cold-duration = "24h"
-
- # MaxPointsPerBlock is the maximum number of points in an encoded
- # block in a TSM file. Larger numbers may yield better compression
- # but could incur a performance penalty when querying
- # max-points-per-block = 1000
+ dir = "{{ server.data.dir }}"
+ wal-dir = "{{ server.data.wal_dir }}"
+ trace-logging-enabled = {{ server.data.trace_logging_enabled|default('false')|lower }}
+ query-log-enabled = {{ server.data.query_log_enabled | lower }}
+ max-series-per-database = {{ server.data.max_series_per_database }}
+ cache-max-memory-size = {{ server.data.cache_max_memory_size|default(1048576000) }}
+ cache-snapshot-memory-size = {{ server.data.cache_snapshot_memory_size|default(26214400) }}
+ cache-snapshot-write-cold-duration = "{{ server.data.cache_snapshot_write_cold_duration|default('10m') }}"
+ compact-full-write-cold-duration = "{{ server.data.compact_full_write_cold_duration|default('4h') }}"
+ max-values-per-tag = {{ server.data.max_values_per_tag|default(100000) }}
+{%- else %}
+[data]
+ enabled = false
+{%- endif %}
###
-### [cluster]
+### [coordinator]
###
-### Controls non-Raft cluster behavior, which generally includes how data is
-### shared across shards.
+### Controls the clustering service configuration.
###
-[cluster]
- shard-writer-timeout = "5s" # The time within which a remote shard must respond to a write request.
- write-timeout = "10s" # The time within which a write request must complete on the cluster.
- max-concurrent-queries = 0 # The maximum number of concurrent queries that can run. 0 to disable.
- query-timeout = "0s" # The time within a query must complete before being killed automatically. 0s to disable.
- max-select-point = 0 # The maximum number of points to scan in a query. 0 to disable.
- max-select-series = 0 # The maximum number of series to select in a query. 0 to disable.
- max-select-buckets = 0 # The maximum number of buckets to select in an aggregate query. 0 to disable.
+[coordinator]
+ write-timeout = "10s"
+ max-concurrent-queries = 0
+ query-timeout = "0"
+ log-queries-after = "0"
+ max-select-point = 0
+ max-select-series = 0
+ max-select-buckets = 0
###
### [retention]
[retention]
enabled = true
- check-interval = "30m"
+ check-interval = "{{ server.get('retention', {}).check_interval|default('30m') }}"
###
### [shard-precreation]
[shard-precreation]
enabled = true
- check-interval = "10m"
- advance-period = "30m"
+ check-interval = "{{ server.get('shard_precreation', {}).check_interval|default('10m') }}"
+ advance-period = "{{ server.get('shard_precreation', {}).advance_period|default('30m') }}"
###
### Controls the system self-monitoring, statistics and diagnostics.
[http]
enabled = true
bind-address = "{{ server.http.bind.address }}:{{ server.http.bind.port }}"
+ {%- if server.admin.get('user', {}).get('enabled', False) %}
+ auth-enabled = true
+ {%- else %}
auth-enabled = false
- log-enabled = true
+ {%- endif %}
+ log-enabled = {{ server.http.log_enabled | lower }}
write-tracing = false
pprof-enabled = false
{%- if server.http.get('ssl', {}).get('enabled', False) %}
enabled = false
{%- endif %}
+###
+### [subscriber]
+###
+### Controls the subscriptions, which can be used to fork a copy of all data
+### received by the InfluxDB host.
+###
+
+[subscriber]
+ enabled = false
+ # http-timeout = "30s"
+ # write-concurrency = 40
+ # write-buffer-size = 1000
+
###
### [[graphite]]
###
###
{%- if server.udp.enabled %}
-[udp]
+[[udp]]
enabled = true
bind-address = "{{ server.udp.bind.address }}:{{ server.udp.bind.port }}"
# database = "udp"
]
{%- endif %}
{%- else %}
-[udp]
+[[udp]]
enabled = false
{%- endif %}