diff --git a/roles/loki/files/loki.yaml b/roles/loki/files/loki.yaml index 48f409dc0d2d6ec09295c19297216f267f7729b2..022ec96e4456d36e1ee35548f0b93fc5b45c0823 100644 --- a/roles/loki/files/loki.yaml +++ b/roles/loki/files/loki.yaml @@ -1,5 +1,3 @@ -# Enables authentication through the X-Scope-OrgID header, which must be present -# if true. If false, the OrgID will always be set to "fake". auth_enabled: false server: @@ -8,24 +6,22 @@ server: grpc_listen_address: 127.0.0.1 grpc_listen_port: 9095 +common: + path_prefix: /var/lib/loki + storage: + filesystem: + chunks_directory: /var/lib/loki/chunks + rules_directory: /var/lib/loki/rules + replication_factor: 1 + ring: + instance_addr: 127.0.0.1 + kvstore: + store: inmemory + ingester: wal: - enabled: true - dir: /var/lib/loki/wal replay_memory_ceiling: 200MB - lifecycler: - address: 127.0.0.1 - ring: - kvstore: - store: inmemory - replication_factor: 1 - final_sleep: 0s - chunk_idle_period: 1h # Any chunk not receiving new logs in this time will be flushed - max_chunk_age: 1h # All chunks will be flushed when they hit this age, default is 1h - chunk_target_size: 1536000 # Loki will attempt to build chunks up to 1.5MB, flushing first if chunk_idle_period or max_chunk_age is reached first chunk_encoding: zstd - chunk_retain_period: 30s # Must be greater than index read cache TTL if using an index cache (Default index read cache TTL is 5m) - max_transfer_retries: 0 # Chunk transfers disabled schema_config: configs: @@ -37,27 +33,10 @@ schema_config: prefix: index_ period: 24h -storage_config: - boltdb_shipper: - active_index_directory: /var/lib/loki/boltdb-shipper-active - cache_location: /var/lib/loki/boltdb-shipper-cache - cache_ttl: 24h # Can be increased for faster performance over longer query periods, uses more disk space - shared_store: filesystem - filesystem: - directory: /var/lib/loki/chunks - compactor: - working_directory: /var/lib/loki/boltdb-shipper-compactor - shared_store: filesystem + retention_enabled: true limits_config: - reject_old_samples: true - reject_old_samples_max_age: 168h max_query_series: 10000 - -chunk_store_config: - max_look_back_period: 2184h - -table_manager: - retention_deletes_enabled: true - retention_period: 2184h # 91 days + retention_period: 91d + max_query_lookback: 91d