Configuring Loki

Loki is configured in a YAML file (usually referred to as loki.yaml)which contains information on the Loki server and its individual components,depending on which mode Loki is launched in.

Configuration examples can be found in the Configuration Examples document.

Configuration File Reference

To specify which configuration file to load, pass the -config.file flag at thecommand line. The file is written in YAML format,defined by the scheme below. Brackets indicate that a parameter is optional. Fornon-list parameters the value is set to the specified default.

Generic placeholders are defined as follows:

  • <boolean>: a boolean that can take the values true or false
  • <int>: any integer matching the regular expression [1-9]+[0-9]*
  • <duration>: a duration matching the regular expression [0-9]+(ms|[smhdwy])
  • <labelname>: a string matching the regular expression [a-zA-Z_][a-zA-Z0-9_]*
  • <labelvalue>: a string of unicode characters
  • <filename>: a valid path relative to current working directory or an absolute path.
  • <host>: a valid string consisting of a hostname or IP followed by an optional port number
  • <string>: a regular string
  • <secret>: a regular string that is a secret, such as a password

Supported contents and default values of loki.yaml:

  1. # The module to run Loki with. Supported values
  2. # all, querier, table-manager, ingester, distributor
  3. [target: <string> | default = "all"]
  4. # Enables authentication through the X-Scope-OrgID header, which must be present
  5. # if true. If false, the OrgID will always be set to "fake".
  6. [auth_enabled: <boolean> | default = true]
  7. # Configures the server of the launched module(s).
  8. [server: <server_config>]
  9. # Configures the querier. Only appropriate when running all modules or
  10. # just the querier.
  11. [querier: <querier_config>]
  12. # Configures how the distributor will connect to ingesters. Only appropriate
  13. # when running all modules, the distributor, or the querier.
  14. [ingester_client: <ingester_client_config>]
  15. # Configures the ingester and how the ingester will register itself to a
  16. # key value store.
  17. [ingester: <ingester_config>]
  18. # Configures where Loki will store data.
  19. [storage_config: <storage_config>]
  20. # Configures how Loki will store data in the specific store.
  21. [chunk_store_config: <chunk_store_config>]
  22. # Configures the chunk index schema and where it is stored.
  23. [schema_config: <schema_config>]
  24. # Configures limits per-tenant or globally
  25. [limits_config: <limits_config>]
  26. # Configures the table manager for retention
  27. [table_manager: <table_manager_config>]

server_config

The server_config block configures Promtail’s behavior as an HTTP server:

  1. # HTTP server listen host
  2. [http_listen_host: <string>]
  3. # HTTP server listen port
  4. [http_listen_port: <int> | default = 80]
  5. # gRPC server listen host
  6. [grpc_listen_host: <string>]
  7. # gRPC server listen port
  8. [grpc_listen_port: <int> | default = 9095]
  9. # Register instrumentation handlers (/metrics, etc.)
  10. [register_instrumentation: <boolean> | default = true]
  11. # Timeout for graceful shutdowns
  12. [graceful_shutdown_timeout: <duration> | default = 30s]
  13. # Read timeout for HTTP server
  14. [http_server_read_timeout: <duration> | default = 30s]
  15. # Write timeout for HTTP server
  16. [http_server_write_timeout: <duration> | default = 30s]
  17. # Idle timeout for HTTP server
  18. [http_server_idle_timeout: <duration> | default = 120s]
  19. # Max gRPC message size that can be received
  20. [grpc_server_max_recv_msg_size: <int> | default = 4194304]
  21. # Max gRPC message size that can be sent
  22. [grpc_server_max_send_msg_size: <int> | default = 4194304]
  23. # Limit on the number of concurrent streams for gRPC calls (0 = unlimited)
  24. [grpc_server_max_concurrent_streams: <int> | default = 100]
  25. # Log only messages with the given severity or above. Supported values [debug,
  26. # info, warn, error]
  27. [log_level: <string> | default = "info"]
  28. # Base path to server all API routes from (e.g., /v1/).
  29. [http_path_prefix: <string>]

querier_config

The querier_config block configures the Loki Querier.

  1. # Timeout when querying ingesters or storage during the execution of a
  2. # query request.
  3. [query_timeout: <duration> | default = 1m]
  4. # Limit of the duration for which live tailing requests should be
  5. # served.
  6. [tail_max_duration: <duration> | default = 1h]
  7. # Configuration options for the LogQL engine.
  8. engine:
  9. # Timeout for query execution
  10. [timeout: <duration> | default = 3m]
  11. # The maximum amount of time to look back for log lines. Only
  12. # applicable for instant log queries.
  13. [max_look_back_period: <duration> | default = 30s]

ingester_client_config

The ingester_client_config block configures how connections to ingestersoperate.

  1. # Configures how connections are pooled
  2. pool_config:
  3. # Whether or not to do health checks.
  4. [health_check_ingesters: <boolean> | default = false]
  5. # How frequently to clean up clients for servers that have gone away after
  6. # a health check.
  7. [client_cleanup_period: <duration> | default = 15s]
  8. # How quickly a dead client will be removed after it has been detected
  9. # to disappear. Set this to a value to allow time for a secondary
  10. # health check to recover the missing client.
  11. [remotetimeout: <duration>]
  12. # The remote request timeout on the client side.
  13. [remote_timeout: <duration> | default = 5s]
  14. # Configures how the gRPC connection to ingesters work as a
  15. # client.
  16. [grpc_client_config: <grpc_client_config>]

grpc_client_config

The grpc_client_config block configures a client connection to a gRPC service.

  1. # The maximum size in bytes the client can recieve
  2. [max_recv_msg_size: <int> | default = 104857600]
  3. # The maximum size in bytes the client can send
  4. [max_send_msg_size: <int> | default = 16777216]
  5. # Whether or not messages should be compressed
  6. [use_gzip_compression: <bool> | default = false]
  7. # Rate limit for gRPC client. 0 is disabled
  8. [rate_limit: <float> | default = 0]
  9. # Rate limit burst for gRPC client.
  10. [rate_limit_burst: <int> | default = 0]
  11. # Enable backoff and retry when a rate limit is hit.
  12. [backoff_on_ratelimits: <bool> | default = false]
  13. # Configures backoff when enbaled.
  14. backoff_config:
  15. # Minimum delay when backing off.
  16. [minbackoff: <duration> | default = 100ms]
  17. # The maximum delay when backing off.
  18. [maxbackoff: <duration> | default = 10s]
  19. # Number of times to backoff and retry before failing.
  20. [maxretries: <int> | default = 10]

ingester_config

The ingester_config block configures Ingesters.

  1. # Configures how the lifecycle of the ingester will operate
  2. # and where it will register for discovery.
  3. [lifecycler: <lifecycler_config>]
  4. # Number of times to try and transfer chunks when leaving before
  5. # falling back to flushing to the store.
  6. [max_transfer_retries: <int> | default = 10]
  7. # How many flushes can happen concurrently from each stream.
  8. [concurrent_flushes: <int> | default = 16]
  9. # How often should the ingester see if there are any blocks
  10. # to flush
  11. [flush_check_period: <duration> | default = 30s]
  12. # The timeout before a flush is cancelled
  13. [flush_op_timeout: <duration> | default = 10s]
  14. # How long chunks should be retained in-memory after they've
  15. # been flushed.
  16. [chunk_retain_period: <duration> | default = 15m]
  17. # How long chunks should sit in-memory with no updates before
  18. # being flushed if they don't hit the max block size. This means
  19. # that half-empty chunks will still be flushed after a certain
  20. # period as long as they receieve no further activity.
  21. [chunk_idle_period: <duration> | default = 30m]
  22. # The maximum size in bytes a chunk can be before it should be flushed.
  23. [chunk_block_size: <int> | default = 262144]

lifecycler_config

The lifecycler_config is used by the Ingester to control how that ingesterregisters itself into the ring and manages its lifecycle during its stay in thering.

  1. # Configures the ring the lifecycler connects to
  2. [ring: <ring_config>]
  3. # The number of tokens the lifecycler will generate and put into the ring if
  4. # it joined without transfering tokens from another lifecycler.
  5. [num_tokens: <int> | default = 128]
  6. # Period at which to heartbeat to the underlying ring.
  7. [heartbeat_period: <duration> | default = 5s]
  8. # How long to wait to claim tokens and chunks from another member when
  9. # that member is leaving. Will join automatically after the duration expires.
  10. [join_after: <duration> | default = 0s]
  11. # Minimum duration to wait before becoming ready. This is to work around race
  12. # conditions with ingesters exiting and updating the ring.
  13. [min_ready_duration: <duration> | default = 1m]
  14. # Store tokens in a normalised fashion to reduce the number of allocations.
  15. [normalise_tokens: <boolean> | default = false]
  16. # Name of network interfaces to read addresses from.
  17. interface_names:
  18. - [<string> ... | default = ["eth0", "en0"]]
  19. # Duration to sleep before exiting to ensure metrics are scraped.
  20. [final_sleep: <duration> | default = 30s]

ring_config

The ring_config is used to discover and connect to Ingesters.

  1. kvstore:
  2. # The backend storage to use for the ring. Supported values are
  3. # consul, etcd, inmemory
  4. store: <string>
  5. # The prefix for the keys in the store. Should end with a /.
  6. [prefix: <string> | default = "collectors/"]
  7. # Configuration for a Consul client. Only applies if store
  8. # is "consul"
  9. consul:
  10. # The hostname and port of Consul.
  11. [host: <string> | duration = "localhost:8500"]
  12. # The ACL Token used to interact with Consul.
  13. [acltoken: <string>]
  14. # The HTTP timeout when communicating with Consul
  15. [httpclienttimeout: <duration> | default = 20s]
  16. # Whether or not consistent reads to Consul are enabled.
  17. [consistentreads: <boolean> | default = true]
  18. # Configuration for an ETCD v3 client. Only applies if
  19. # store is "etcd"
  20. etcd:
  21. # The ETCD endpoints to connect to.
  22. endpoints:
  23. - <string>
  24. # The Dial timeout for the ETCD connection.
  25. [dial_tmeout: <duration> | default = 10s]
  26. # The maximum number of retries to do for failed ops to ETCD.
  27. [max_retries: <int> | default = 10]
  28. # The heartbeart timeout after which ingesters are skipped for
  29. # reading and writing.
  30. [heartbeart_timeout: <duration> | default = 1m]
  31. # The number of ingesters to write to and read from. Must be at least
  32. # 1.
  33. [replication_factor: <int> | default = 3]

storage_config

The storage_config block configures one of many possible stores for both theindex and chunks. Which configuration is read from depends on the schema_configblock and what is set for the store value.

  1. # Configures storing chunks in AWS. Required options only required when aws is
  2. # present.
  3. aws:
  4. # S3 or S3-compatible URL to connect to. If only region is specified as a
  5. # host, the proper endpoint will be deduced. Use inmemory:///<bucket-name> to
  6. # use a mock in-memory implementation.
  7. s3: <string>
  8. # Set to true to force the request to use path-style addressing
  9. [s3forcepathstyle: <boolean> | default = false]
  10. # Configure the DynamoDB conection
  11. dynamodbconfig:
  12. # URL for DynamoDB with escaped Key and Secret encoded. If only region is specified as a
  13. # host, the proper endpoint will be deduced. Use inmemory:///<bucket-name> to
  14. # use a mock in-memory implementation.
  15. dynamodb: <string>
  16. # DynamoDB table management requests per-second limit.
  17. [apilimit: <float> | default = 2.0]
  18. # DynamoDB rate cap to back off when throttled.
  19. [throttlelimit: <float> | default = 10.0]
  20. # Application Autoscaling endpoint URL with escaped Key and Secret
  21. # encoded.
  22. [applicationautoscaling: <string>]
  23. # Metics-based autoscaling configuration.
  24. metrics:
  25. # Use metrics-based autoscaling via this Prometheus query URL.
  26. [url: <string>]
  27. # Queue length above which we will scale up capacity.
  28. [targetqueuelen: <int> | default = 100000]
  29. # Scale up capacity by this multiple
  30. [scaleupfactor: <float64> | default = 1.3]
  31. # Ignore throttling below this level (rate per second)
  32. [minthrottling: <float64> | default = 1]
  33. # Query to fetch ingester queue length
  34. [queuelengthquery: <string> | default = "sum(avg_over_time(cortex_ingester_flush_queue_length{job="cortex/ingester"}[2m]))"]
  35. # Query to fetch throttle rates per table
  36. [throttlequery: <string> | default = "sum(rate(cortex_dynamo_throttled_total{operation="DynamoDB.BatchWriteItem"}[1m])) by (table) > 0"]
  37. # Quer to fetch write capacity usage per table
  38. [usagequery: <string> | default = "sum(rate(cortex_dynamo_consumed_capacity_total{operation="DynamoDB.BatchWriteItem"}[15m])) by (table) > 0"]
  39. # Query to fetch read capacity usage per table
  40. [readusagequery: <string> | default = "sum(rate(cortex_dynamo_consumed_capacity_total{operation="DynamoDB.QueryPages"}[1h])) by (table) > 0"]
  41. # Query to fetch read errors per table
  42. [readerrorquery: <string> | default = "sum(increase(cortex_dynamo_failures_total{operation="DynamoDB.QueryPages",error="ProvisionedThroughputExceededException"}[1m])) by (table) > 0"]
  43. # Number of chunks to group together to parallelise fetches (0 to disable)
  44. [chunkgangsize: <int> | default = 10]
  45. # Max number of chunk get operations to start in parallel.
  46. [chunkgetmaxparallelism: <int> | default = 32]
  47. # Configures storing chunks in Bigtable. Required fields only required
  48. # when bigtable is defined in config.
  49. bigtable:
  50. # BigTable project ID
  51. project: <string>
  52. # BigTable instance ID
  53. instance: <string>
  54. # Configures the gRPC client used to connect to Bigtable.
  55. [grpc_client_config: <grpc_client_config>]
  56. # Configures storing index in GCS. Required fields only required
  57. # when gcs is defined in config.
  58. gcs:
  59. # Name of GCS bucket to put chunks in.
  60. bucket_name: <string>
  61. # The size of the buffer that the GCS client uses for each PUT request. 0
  62. # to disable buffering.
  63. [chunk_buffer_size: <int> | default = 0]
  64. # The duration after which the requests to GCS should be timed out.
  65. [request_timeout: <duration> | default = 0s]
  66. # Configures storing chunks in Cassandra
  67. cassandra:
  68. # Comma-separated hostnames or IPs of Cassandra instances
  69. addresses: <string>
  70. # Port that cassandra is running on
  71. [port: <int> | default = 9042]
  72. # Keyspace to use in Cassandra
  73. keyspace: <string>
  74. # Consistency level for Cassandra
  75. [consistency: <string> | default = "QUORUM"]
  76. # Replication factor to use in Cassandra.
  77. [replication_factor: <int> | default = 1]
  78. # Instruct the Cassandra driver to not attempt to get host
  79. # info from the system.peers table.
  80. [disable_initial_host_lookup: <bool> | default = false]
  81. # Use SSL when connecting to Cassandra instances.
  82. [SSL: <boolean> | default = false]
  83. # Require SSL certificate validation when SSL is enabled.
  84. [host_verification: <bool> | default = true]
  85. # Path to certificate file to verify the peer when SSL is
  86. # enabled.
  87. [CA_path: <string>]
  88. # Enable password authentication when connecting to Cassandra.
  89. [auth: <bool> | default = false]
  90. # Username for password authentication when auth is true.
  91. [username: <string>]
  92. # Password for password authentication when auth is true.
  93. [password: <string>]
  94. # Timeout when connecting to Cassandra.
  95. [timeout: <duration> | default = 600ms]
  96. # Initial connection timeout during initial dial to server.
  97. [connect_timeout: <duration> | default = 600ms]
  98. # Configures storing index in BoltDB. Required fields only
  99. # required when boltdb is present in config.
  100. boltdb:
  101. # Location of BoltDB index files.
  102. directory: <string>
  103. # Configures storing the chunks on the local filesystem. Required
  104. # fields only required when filesystem is present in config.
  105. filesystem:
  106. # Directory to store chunks in.
  107. directory: <string>
  108. # Cache validity for active index entries. Should be no higher than
  109. # the chunk_idle_period in the ingester settings.
  110. [indexcachevalidity: <duration> | default = 5m]
  111. # The maximum number of chunks to fetch per batch.
  112. [max_chunk_batch_size: <int> | default = 50]
  113. # Config for how the cache for index queries should
  114. # be built.
  115. index_queries_cache_config: <cache_config>

cache_config

The cache_config block configures how Loki will cache requests, chunks, andthe index to a backing cache store.

  1. # Enable in-memory cache.
  2. [enable_fifocache: <boolean>]
  3. # The default validity of entries for caches unless overriden.
  4. # "defaul" is correct.
  5. [defaul_validity: <duration>]
  6. # Configures the background cache when memcached is used.
  7. background:
  8. # How many goroutines to use to write back to memcached.
  9. [writeback_goroutines: <int> | default = 10]
  10. # How many chunks to buffer for background write back to memcached.
  11. [writeback_buffer: <int> = 10000]
  12. # Configures memcached settings.
  13. memcached:
  14. # Configures how long keys stay in memcached.
  15. expiration: <duration>
  16. # Configures how many keys to fetch in each batch request.
  17. batch_size: <int>
  18. # Maximum active requests to memcached.
  19. [parallelism: <int> | default = 100]
  20. # Configures how to connect to one or more memcached servers.
  21. memcached_client:
  22. # The hostname to use for memcached services when caching chunks. If
  23. # empty, no memcached will be used. A SRV lookup will be used.
  24. [host: <string>]
  25. # SRV service used to discover memcached servers.
  26. [service: <string> | default = "memcached"]
  27. # Maximum time to wait before giving up on memcached requests.
  28. [timeout: <duration> | default = 100ms]
  29. # The maximum number of idle connections in the memcached client
  30. # pool.
  31. [max_idle_conns: <int> | default = 100]
  32. # The period with which to poll the DNS for memcached servers.
  33. [update_interval: <duration> | default = 1m]
  34. # Whether or not to use a consistent hash to discover multiple memcached
  35. # servers.
  36. [consistent_hash: <bool>]
  37. fifocache:
  38. # Number of entries to cache in-memory.
  39. [size: <int> | default = 0]
  40. # The expiry duration for the in-memory cache.
  41. [validity: <duration> | default = 0s]

chunk_store_config

The chunk_store_config block configures how chunks will be cached and how longto wait before saving them to the backing store.

  1. # The cache configuration for storing chunks
  2. [chunk_cache_config: <cache_config>]
  3. # The cache configuration for deduplicating writes
  4. [write_dedupe_cache_config: <cache_config>]
  5. # The minimum time between a chunk update and being saved
  6. # to the store.
  7. [min_chunk_age: <duration>]
  8. # Cache index entries older than this period. Default is
  9. # disabled.
  10. [cache_lookups_older_than: <duration>]
  11. # Limit how long back data can be queries. Default is disabled.
  12. [max_look_back_period: <duration>]

schema_config

The schema_config block configures schemas from given dates.

  1. # The configuration for chunk index schemas.
  2. configs:
  3. - [<period_config>]

period_config

The period_config block configures what index schemas should be usedfor from specific time periods.

  1. # The date of the first day that index buckets should be created. Use
  2. # a date in the past if this is your only period_config, otherwise
  3. # use a date when you want the schema to switch over.
  4. [from: <daytime>]
  5. # store and object_store below affect which <storage_config> key is
  6. # used.
  7. # Which store to use for the index. Either cassandra, bigtable, dynamodb, or
  8. # boltdb
  9. store: <string>
  10. # Which store to use for the chunks. Either gcs, s3, inmemory, filesystem,
  11. # cassandra. If omitted, defaults to same value as store.
  12. [object_store: <string>]
  13. # The schema to use. Set to v9 or v10.
  14. schema: <string>
  15. # Configures how the index is updated and stored.
  16. index:
  17. # Table prefix for all period tables.
  18. prefix: <string>
  19. # Table period.
  20. [period: <duration> | default = 168h]
  21. # A map to be added to all managed tables.
  22. tags:
  23. [<string>: <string> ...]
  24. # Configured how the chunks are updated and stored.
  25. chunks:
  26. # Table prefix for all period tables.
  27. prefix: <string>
  28. # Table period.
  29. [period: <duration> | default = 168h]
  30. # A map to be added to all managed tables.
  31. tags:
  32. [<string>: <string> ...]
  33. # How many shards will be created. Only used if schema is v10.
  34. [row_shards: <int> | default = 16]

Where daytime is a value in the format of yyyy-mm-dd like 2006-01-02.

limits_config

The limits_config block configures global and per-tenant limits for ingestinglogs in Loki.

  1. # Per-user ingestion rate limit in samples per second.
  2. [ingestion_rate: <float> | default = 25000]
  3. # Per-user allowed ingestion burst size (in number of samples).
  4. [ingestion_burst_size: <int> | default = 50000]
  5. # Whether or not, for all users, samples with external labels
  6. # identifying replicas in an HA Prometheus setup will be handled.
  7. [accept_ha_samples: <boolean> | default = false]
  8. # Prometheus label to look for in samples to identify a
  9. # Prometheus HA cluster.
  10. [ha_cluster_label: <string> | default = "cluster"]
  11. # Prometheus label to look for in samples to identify a Prometheus HA
  12. # replica.
  13. [ha_replica_label: <string> | default = "__replica__"]
  14. # Maximum length of a label name.
  15. [max_label_name_length: <int> | default = 1024]
  16. # Maximum length of a label value.
  17. [max_label_value_length: <int> | default = 2048]
  18. # Maximum number of label names per series.
  19. [max_label_names_per_series: <int> | default = 30]
  20. # Whether or not old samples will be rejected.
  21. [reject_old_samples: <bool> | default = false]
  22. # Maximum accepted sample age before rejecting.
  23. [reject_old_samples_max_age: <duration> | default = 336h]
  24. # Duration for a table to be created/deleted before/after it's
  25. # needed. Samples won't be accepted before this time.
  26. [creation_grace_period: <duration> | default = 10m]
  27. # Enforce every sample has a metric name.
  28. [enforce_metric_name: <boolean> | default = true]
  29. # Maximum number of samples that a query can return.
  30. [max_samples_per_query: <int> | default = 1000000]
  31. # Maximum number of active series per user.
  32. [max_series_per_user: <int> | default = 5000000]
  33. # Maximum number of active series per metric name.
  34. [max_series_per_metric: <int> | default = 50000]
  35. # Maximum number of chunks that can be fetched by a single query.
  36. [max_chunks_per_query: <int> | default = 2000000]
  37. # The limit to length of chunk store queries. 0 to disable.
  38. [max_query_length: <duration> | default = 0]
  39. # Maximum number of queries that will be scheduled in parallel by the
  40. # frontend.
  41. [max_query_parallelism: <int> | default = 14]
  42. # Cardinality limit for index queries
  43. [cardinality_limit: <int> | default = 100000]
  44. # Filename of per-user overrides file
  45. [per_tenant_override_config: <string>]
  46. # Period with which to reload the overrides file if configured.
  47. [per_tenant_override_period: <duration> | default = 10s]

table_manager_config

The table_manager_config block configures how the table manager operatesand how to provision tables when DynamoDB is used as the backing store.

  1. # Master 'off-switch' for table capacity updates, e.g. when troubleshooting
  2. [throughput_updates_disabled: <boolean> | default = false]
  3. # Master 'on-switch' for table retention deletions
  4. [retention_deletes_enabled: <boolean> | default = false]
  5. # How far back tables will be kept before they are deleted. 0s disables
  6. # deletion. The retention period must be a multiple of the index / chunks
  7. # table "period" (see period_config).
  8. [retention_period: <duration> | default = 0s]
  9. # Period with which the table manager will poll for tables.
  10. [dynamodb_poll_interval: <duration> | default = 2m]
  11. # duration a table will be created before it is needed.
  12. [creation_grace_period: <duration> | default = 10m]
  13. # Configures management of the index tables for DynamoDB.
  14. index_tables_provisioning: <provision_config>
  15. # Configures management of the chunk tables for DynamoDB.
  16. chunk_tables_provisioning: <provision_config>

provision_config

The provision_config block configures provisioning capacity for DynamoDB.

  1. # Enables on-demand throughput provisioning for the storage
  2. # provider, if supported. Applies only to tables which are not autoscaled.
  3. [provisioned_throughput_on_demand_mode: <boolean> | default = false]
  4. # DynamoDB table default write throughput.
  5. [provisioned_write_throughput: <int> | default = 3000]
  6. # DynamoDB table default read throughput.
  7. [provisioned_read_throughput: <int> | default = 300]
  8. # Enables on-demand throughput provisioning for the storage provide,
  9. # if supported. Applies only to tables which are not autoscaled.
  10. [inactive_throughput_on_demand_mode: <boolean> | default = false]
  11. # DynamoDB table write throughput for inactive tables.
  12. [inactive_write_throughput: <int> | default = 1]
  13. # DynamoDB table read throughput for inactive tables.
  14. [inactive_read_throughput: <int> | Default = 300]
  15. # Active table write autoscale config.
  16. [write_scale: <auto_scaling_config>]
  17. # Inactive table write autoscale config.
  18. [inactive_write_scale: <auto_scaling_config>]
  19. # Number of last inactive tables to enable write autoscale.
  20. [inactive_write_scale_lastn: <int>]
  21. # Active table read autoscale config.
  22. [read_scale: <auto_scaling_config>]
  23. # Inactive table read autoscale config.
  24. [inactive_read_scale: <auto_scaling_config>]
  25. # Number of last inactive tables to enable read autoscale.
  26. [inactive_read_scale_lastn: <int>]

auto_scaling_config

The auto_scaling_config block configures autoscaling for DynamoDB.

  1. # Whether or not autoscaling should be enabled.
  2. [enabled: <boolean>: default = false]
  3. # AWS AutoScaling role ARN
  4. [role_arn: <string>]
  5. # DynamoDB minimum provision capacity.
  6. [min_capacity: <int> | default = 3000]
  7. # DynamoDB maximum provision capacity.
  8. [max_capacity: <int> | default = 6000]
  9. # DynamoDB minimum seconds between each autoscale up.
  10. [out_cooldown: <int> | default = 1800]
  11. # DynamoDB minimum seconds between each autoscale down.
  12. [in_cooldown: <int> | default = 1800]
  13. # DynamoDB target ratio of consumed capacity to provisioned capacity.
  14. [target: <float> | default = 80]