Loki is an amazing log aggregation tool, and we’ve fully migrated our services here at Vokke. We’re all in. That said, we run Loki and the corresponding Grafana stack on our own infrastructure, and the setup was a little painful, primarily because of a lack of consistent documentation for the most recent version.
So here’s the config that worked for us, using a local MinIO object store. If you need a hand, feel free to email me at [email protected] and I’ve see if I can help!
auth_enabled: false
server:
http_listen_port: 3100
# We needed to increase this to send/receive large messages
grpc_server_max_recv_msg_size: 20971520
grpc_server_max_send_msg_size: 20971520
distributor:
ring:
kvstore:
store: memberlist
ingester:
wal:
enabled: false
lifecycler:
ring:
kvstore:
store: memberlist
replication_factor: 1
final_sleep: 0s
chunk_idle_period: 5m
chunk_retain_period: 30s
memberlist:
abort_if_cluster_join_fails: false
# Expose this port on all distributor, ingester
# and querier replicas.
bind_port: 7946
# You can use a headless k8s service for all distributor,
# ingester and querier components.
join_members:
- loki:7946
max_join_backoff: 1m
max_join_retries: 10
min_join_backoff: 1s
schema_config:
configs:
- from: 2020-05-15
store: boltdb-shipper
object_store: s3
schema: v11
index:
prefix: index_
period: 24h
storage_config:
boltdb_shipper:
active_index_directory: /loki/index
cache_location: /loki/index_cache
resync_interval: 5s
shared_store: s3
aws:
s3: s3://PASSWORD_HERE:USERNAME_HERE@HOST_HERE/loki-logs
s3forcepathstyle: true
limits_config:
enforce_metric_name: false
reject_old_samples: true
reject_old_samples_max_age: 168h