Skip to main content

Thanos


Architecture

Thanos with Sidecar
https://github.com/thanos-io/thanos

설치

helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo update bitnami \
&& helm search repo bitnami/thanos -l | head -n 10
helm pull bitnami/thanos \
--version 12.10.1
helm show values thanos-12.10.1.tgz \
> thanos-values.yaml
thanos-values.yaml
commonLabels: {}

objstoreConfig: |
type: S3
prefix: thanos
config:
endpoint: s3.ap-northeast-2.amazonaws.com
region: ap-northeast-2
bucket: <bucketName>

query:
enabled: true
stores:
- prometheus-operated.monitoring.svc:10901

queryFrontend:
enabled: true

bucketweb:
enabled: false

compactor:
enabled: true

storegateway:
enabled: true

ruler:
enabled: false

receive:
enabled: false

receiveDistributor:
enabled: false

metrics:
enabled: false
helm template thanos thanos-12.10.1.tgz \
-n monitoring \
-f thanos-values.yaml \
> thanos.yaml
helm upgrade thanos thanos-12.10.1.tgz \
--install \
--history-max 5 \
-n monitoring \
-f thanos-values.yaml
  • Prometheus에 Thanos Sidecar를 추가하여 배포합니다.
  • 배포된 Prometheus 서비스를 query.stores에 추가합니다.
  • Grafana에 http://thanos-query.monitoring.svc:9090을 데이터 소스로 추가합니다.