Skip to main content

Getting Started with NexClipper Cloud

Overview

NexClipper ๊ตฌ์„ฑ์š”์†Œ๋Š” ํฌ๊ฒŒ 3๊ฐ€์ง€๋กœ ๊ตฌ์„ฑ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค. NexClipper๋Š” Kubernetes cluster ๋‚ด์—์„œ ๋ฐ๋ชฌ์…‹(DaemonSet)๊ณผ ํŒŒ๋“œ(Pod), ๋””ํ”Œ๋กœ์ด๋จผํŠธ(Deployment)ํ˜•ํƒœ๋กœ ์‹คํ–‰๋ฉ๋‹ˆ๋‹ค.
๋ชจ๋“  ๋ฆฌ์†Œ์Šค๋Š” ๊ธฐ๋ณธ์ ์œผ๋กœ nex-system, nexclipper ๋„ค์ž„์ŠคํŽ˜์ด์Šค์—์„œ ๊ตฌ๋™๋˜๋ฉฐ, ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ๊ด€๋ จ๋œ ์—์ฝ”์‹œ์Šคํ…œ๋“ค์ด ํฌํ•จ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค.

๊ตฌ์„ฑ์š”์†Œ๋ฆฌ์†Œ์Šค ํƒ€์ž…์—ญํ• 
Klevr AgentDaemonSetNexClipper Manager์™€ ํ†ต์‹ 
ProvbeeDeploymentProvisioning ๋ฐ Task ์ฒ˜๋ฆฌ
PrometheusDeployment๋ฉ”ํŠธ๋ฆญ ๊ธฐ๋ฐ˜ ๋ชจ๋‹ˆํ„ฐ๋ง ๋„๊ตฌ
node-exporterDaemonSet๋จธ์‹  ๋ฉ”ํŠธ๋ฆญ ์ˆ˜์ง‘ Exporter
GrafanaDeployment์‹œ๊ฐํ™” ๋Œ€์‹œ๋ณด๋“œ ๋„๊ตฌ
Kube-state-metricsDeploymentํด๋Ÿฌ์Šคํ„ฐ ๋ฉ”ํŠธ๋ฆญ ์ˆ˜์ง‘ ๋„๊ตฌ
AlertmanagerDeployment์•Œ๋žŒ ๊ด€๋ฆฌ ๋„๊ตฌ
pushgatewayDeployment์†Œ๊ทœ๋ชจ ๋ฐฐ์น˜ ๋ฉ”ํŠธ๋ฆญ ์ˆ˜์ง‘ ๋„๊ตฌ
PromlensDeploymentPromQL ๊ธฐ๋ฐ˜ ์ฟผ๋ฆฌ ๋นŒ๋”
PromscaleDeploymentPrometheus ๋ฉ”ํŠธ๋ฆญ ๋ถ„์„ ๋„๊ตฌ
TimescaleDBStatefulSet์‹œ๊ณ„์—ด ๊ธฐ๋ฐ˜ SQL DB
ExporterHub(์ค€๋น„์ค‘)DeploymentExporter ํ๋ ˆ์ด์…˜ ํŽ˜์ด์ง€
MetricOperator(์ค€๋น„์ค‘)Deployment๋ฉ”ํŠธ๋ฆญ ์ˆ˜์ง‘, ์ฒ˜๋ฆฌ, ์ „์†ก
note

NexClipper Agent๋Š” Kubernetes ๊ธฐ์ค€ 1.15.12 ์ด์ƒ์—์„œ ํ…Œ์ŠคํŠธ ๋˜์—ˆ์Šต๋‹ˆ๋‹ค. ์ดํ•˜ ๋ฒ„์ „์—์„œ๋Š” ๋ฌธ์ œ๊ฐ€ ๋ฐœ์ƒํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.


Minimum Requirements

NexClipper๋Š” ๊ธฐ๋ณธ์ ์œผ๋กœ Linux ํ™˜๊ฒฝ์—์„œ ๋™์ž‘ํ•˜๋„๋ก ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค.

  • Operating Systems : Linux(WSLํฌํ•จ), MacOS 10.14+, WSL
  • Software
    • bash or zsh
    • curl
    • ssh-keygen
  • Target Kubernetes Cluster : 1.15.12 ์ด์ƒ
  • Firewall : Outbound (Destination : console.nexclipper.io, Port: 80,443,8080,8090)

Installation

์„ค์น˜ ๋ฐฉ๋ฒ•์€ 2๊ฐ€์ง€ ์˜ต์…˜์ด ์žˆ์Šต๋‹ˆ๋‹ค.

  1. Remote Kubernetes
    • ์›๊ฒฉ์œผ๋กœ kube-apiserver๋กœ ํ†ต์‹ ์ด ๊ฐ€๋Šฅํ•œ ํ™˜๊ฒฝ (kubeconfig ํ™˜๊ฒฝ)
  2. Local Kubernetes
    • Docker Desktop, Minikube, K3s, MicroK8s ๋“ฑ ๋กœ์ปฌ์—์„œ ์‹คํ–‰ํ•˜๋Š” ๊ฒฝ์šฐ

bash ๋˜๋Š” zsh์„ ์‹คํ–‰ํ•  ์ˆ˜ ์žˆ๋Š” ํ™˜๊ฒฝ์—์„œ ํ˜„์žฌ ์—ฐ๊ฒฐ๋œ ํด๋Ÿฌ์ŠคํŠธ๋ฅผ ํ™•์ธํ•˜๋Š” ๋‹ค์Œ ๋ช…๋ น์„ ์‹คํ–‰ํ•ฉ๋‹ˆ๋‹ค. docker-descktop์œผ๋กœ kubernetes ํ™˜๊ฒฝ์„ ๊ตฌ์„ฑํ–ˆ๋‹ค๋ฉด ๋‹ค์Œ๊ณผ ์œ ์‚ฌํ•œ ๊ฒฐ๊ณผ๋ฅผ ์–ป์„ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

$ kubectl cluster-info
Kubernetes master is running at https://kubernetes.docker.internal:6443
KubeDNS is running at https://kubernetes.docker.internal:6443/api/v1/namespaces/kube-system/services/kube-dns:dns/proxy
caution

๊ธฐ์กด ์šด์˜์ค‘์ธ ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ์˜คํผ๋ ˆ์ดํ„ฐ(Operator)์™€ ์ค‘๋ณต ์„ค์น˜๋  ๊ฒฝ์šฐ์— ๋ฌธ์ œ๊ฐ€ ๋ฐœ์ƒํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. NexClipper๋Š” Helm๊ธฐ๋ฐ˜์œผ๋กœ ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ๊ด€๋ จ ์—์ฝ”์‹œ์Šคํ…œ๋“ค์„ ๋ฐฐํฌ, ๊ด€๋ฆฌํ•ฉ๋‹ˆ๋‹ค.


Kubernetes

https://nexclipper.github.io/ ๋กœ ์ ‘์†ํ•˜์—ฌ Login ๋ฉ”๋‰ด๋ฅผ ํด๋ฆญํ•ฉ๋‹ˆ๋‹ค.

img

https://console.nexclipper.io/login ๋กœ๊ทธ์ธ ํŽ˜์ด์ง€๋กœ ์ด๋™ํ•ฉ๋‹ˆ๋‹ค.

img

info

ํ˜„์žฌ๋Š” ๊ตฌ๊ธ€ ์ธ์ฆ๋งŒ ์ง€์›ํ•˜๊ณ  ์žˆ์Šต๋‹ˆ๋‹ค. GSuite ๊ณ„์ • ํฌํ•จ Gmail ์•„์ด๋””๋กœ๋งŒ ์‚ฌ์šฉ ๊ฐ€๋Šฅํ•ฉ๋‹ˆ๋‹ค.

Google๊ณ„์ •์œผ๋กœ ๋กœ๊ทธ์ธ ํ•ฉ๋‹ˆ๋‹ค.

img

์ตœ์ดˆ ์‚ฌ์šฉ์ž์˜ ๊ฒฝ์šฐ ์•„๋ž˜์™€ ๊ฐ™์ด Welcome ํ™”๋ฉด์„ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

img

NexClipper๋Š” ์ฟ ๋ฒ„๋„คํ‹ฐ์Šค ํด๋Ÿฌ์Šคํ„ฐ์™€ ์œ ์‚ฌํ•˜์ง€๋งŒ ๋‹ค๋ฅธ ๊ฐœ๋…์œผ๋กœ ๋ณ„๋„์˜ NexClipper ์ œํ’ˆ๊ตฐ์ด ์„ค์น˜๋˜๋Š” Cluster๋ผ๋Š” ๊ฐ€์ƒ์˜ ๋…ผ๋ฆฌ์  ๊ทธ๋ฃน ๊ธฐ๋ฐ˜์œผ๋กœ ๋™์ž‘ํ•ฉ๋‹ˆ๋‹ค. Account์— ๋งตํ•‘๋œ API KEY ๋ฐœ๊ธ‰์„ ์œ„ํ•ด ๋‹ค์Œ ๋‹จ๊ณ„๋ฅผ ์ˆ˜ํ–‰ํ•ฉ๋‹ˆ๋‹ค.

Zone Name์„ ์ž…๋ ฅํ•ฉ๋‹ˆ๋‹ค. Zone Name์€ ๋ฆฌ์ŠคํŠธ์— ๋ณด์—ฌ์ง€๋Š” ๊ฐ’์œผ๋กœ ์‚ฌ์šฉ์ž๊ฐ€ Zone ๋˜๋Š” Cluster๋ฅผ ๊ตฌ๋ถ„ํ•˜๊ธฐ ์œ„ํ•œ ์ž…๋ ฅ๊ฐ’์ž…๋‹ˆ๋‹ค.

img

ํ”„๋กœ๋น„์ €๋‹ํ•  ๋Œ€์ƒ ํด๋Ÿฌ์Šคํ„ฐ ๋˜๋Š” ์ธํ”„๋ผ๋ฅผ ์„ ํƒํ•ฉ๋‹ˆ๋‹ค.

info

ํ˜„์žฌ๋Š” ์ฟ ๋ฒ„๋„คํ‹ฐ์Šค ํด๋Ÿฌ์Šคํ„ฐ๋งŒ ์ง€์›ํ•ฉ๋‹ˆ๋‹ค. ์ดํ›„ Baremetal, Instance ๋˜๋Š” Laptop ํ™˜๊ฒฝ ๋ฐ Public Cloud ํ™˜๊ฒฝ๋„ ์ œ๊ณตํ•  ์˜ˆ์ •์ž…๋‹ˆ๋‹ค.

img

์„ ํƒํ•œ ํด๋Ÿฌ์Šคํ„ฐ์— ์„ค์น˜ํ•  Bootstrap ์Šคํฌ๋ฆฝํŠธ๊ฐ€ ์ƒ์„ฑ๋ฉ๋‹ˆ๋‹ค.

img

์ƒ์„ฑ๋œ ์Šคํฌ๋ฆฝํŠธ๋ฅผ zsh, bash ๊ตฌ๋™์ด ๊ฐ€๋Šฅํ•œ Bastion ๋˜๋Š” Local์—์„œ ์‹คํ–‰ํ•ฉ๋‹ˆ๋‹ค.

curl -sL gg.gg/provbee | TAGKLEVR=0.2.0-SNAPSHOT K3S_SET=N K_API_KEY="977b9d295d0f4273be3575cdaeae22b3" K_PLATFORM="kubernetes" K_MANAGER_URL="http://dev.nexclipper.io:8090" K_ZONE_ID="62" bash

Continue๋ฅผ ๋ˆŒ๋Ÿฌ ๋‹ค์Œ ๋‹จ๊ณ„๋กœ ์ด๋™ํ•ฉ๋‹ˆ๋‹ค.

Klevr์™€ Provbee ์„ค์น˜๊ฐ€ ์™„๋ฃŒ๋˜๊ธฐ ์ „์—๋Š” NexClipper Cloud ์„œ๋ฒ„์™€ ํ†ต์‹ ์ด ๋˜์ง€ ์•Š๊ธฐ ๋•Œ๋ฌธ์— ์•„๋ž˜์™€ ๊ฐ™์€ ํ™”๋ฉด์„ ๋ณผ ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ๋งŒ์•ฝ ์„ค์น˜ ์Šคํฌ๋ฆฝํŠธ๋ฅผ ์‹คํ–‰ํ•˜์ง€ ์•Š์€ ์ƒํƒœ์—์„œ๋Š” ๋‹ค์Œ ํ™”๋ฉด์—์„œ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

img

์—์ด์ „ํŠธ ์„ค์น˜ ์ƒํƒœ๋Š” kubectl์„ ํ†ตํ•ด์„œ๋„ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

nex-system ๋„ค์ž„์ŠคํŽ˜์ด์Šค์—๋Š” klevr ์—์ด์ „ํŠธ ๋ฐ๋ชฌ์…‹์™€ provbee ํŒŒ๋“œ๊ฐ€ ์ƒ์„ฑ๋ฉ๋‹ˆ๋‹ค.

> kubectl get pod -n nex-system

NAME                READY   STATUS    RESTARTS   AGE
klevr-agent-9r5z9   1/1     Running   0          59m
klevr-agent-lcp2j   1/1     Running   0          59m
provbee             1/1     Running   0          59m

์„ค์น˜๊ฐ€ ์™„๋ฃŒ๋˜๋ฉด ์•„๋ž˜์™€ ๊ฐ™์ด Agent ์ƒํƒœ๊ฐ€ Running ์ค‘์œผ๋กœ ๋ณ€๊ฒฝ๋ฉ๋‹ˆ๋‹ค. ๊ทธ๋ฆฌ๊ณ , ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ์Šคํƒ์„ ์„ค์น˜ํ•  ์ˆ˜ ์žˆ๋„๋ก ๊ธฐ๋Šฅ์ด ํ™œ์„ฑํ™” ๋ฉ๋‹ˆ๋‹ค.

img

๊ธฐ๋ณธ์ ์œผ๋กœ ์ œ๊ณต๋˜๋Š” ์„ค์น˜ ์˜ต์…˜์€ ์•„๋ž˜์™€ ๊ฐ™์Šต๋‹ˆ๋‹ค.

img

  • Namespace : ์Šคํƒ์ด ์„ค์น˜๋  ์ฟ ๋ฒ„๋„คํ‹ฐ์Šค ๋„ค์ž„์ŠคํŽ˜์ด์Šค(๊ธฐ๋ณธ๊ฐ’: nexclipper)
  • Volume Size(GB): TimescaleDB Volume Size(๊ธฐ๋ณธ๊ฐ’: 10Gi)
  • Replicas: TimescaleDB Cluster Replicas (๊ธฐ๋ณธ๊ฐ’: 1)
  • Storage Class Name: ๋ณ„๋„์˜ PV์‚ฌ์šฉ์‹œ ์‚ฌ์šฉํ•  ์Šคํ† ๋ฆฌ์ง€ ํด๋ž˜์Šค (๊ธฐ๋ณธ๊ฐ’: LocalVolume)
  • Size of Wal(GB): Prometheus WAL Volume Size(๊ธฐ๋ณธ๊ฐ’: 2Gi)
  • Grafana Admin Password : ๊ทธ๋ผํŒŒ๋‚˜ ์ดˆ๊ธฐ ํŒจ์Šค์›Œ๋“œ(๊ธฐ๋ณธ๊ฐ’: admin)

๊ธฐ๋ณธ์ ์œผ๋กœ nexclipper ๋„ค์ž„์ŠคํŽ˜์ด์Šค์—๋Š” ๋‹ค์Œ ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ์—์ฝ”์‹œ์Šคํ…œ๋“ค์ด ์„ค์น˜๋ฉ๋‹ˆ๋‹ค.

  • prometheus
  • node-exporter
  • kube-state-metrics
  • alertmanager
  • grafana
  • promscale
  • promlens
  • timescaledb
> kubectl get deploy,statefulset -n nexclipper
NAME                                         READY   UP-TO-DATE   AVAILABLE   AGE
deployment.apps/nc-grafana                   1/1     1            1           106s
deployment.apps/nc-kube-state-metrics        1/1     1            1           106s
deployment.apps/nc-prometheus-alertmanager   1/1     1            1           106s
deployment.apps/nc-prometheus-pushgateway    1/1     1            1           106s
deployment.apps/nc-prometheus-server         1/1     1            1           106s
deployment.apps/nc-promlens                  1/1     1            1           106s
deployment.apps/nc-promscale                 1/1     1            1           106s

NAME                              READY   AGE
statefulset.apps/nc-timescaledb   1/1     106s

๋‹ค์‹œ ์ฝ˜์†”๋กœ ๋Œ์•„์™€ ํ”„๋กœ๋น„์ €๋‹๋œ Cluster ๋ชฉ๋ก์„ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

img

ํ•ด๋‹น ํด๋Ÿฌ์Šคํ„ฐ์˜ ์ƒ์„ธ ๋‚ด์—ญ์„ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

  • Platform
    • ํ˜„์žฌ ํ”Œ๋žซํผ์˜ ์ข…๋ฅ˜์™€ ์—์ด์ „ํŠธ, ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ์ƒํƒœ๋ฅผ ๋ณด์—ฌ์ค๋‹ˆ๋‹ค.
  • Install Config
    • ์ดˆ๊ธฐ ์„ค์น˜ ์Šคํฌ๋ฆฝํŠธ๋ฅผ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.
  • Tasks
    • NexClipper์—์„œ ์ˆ˜ํ–‰๋˜๋Š” ๋ชจ๋“  Job๊ณผ Task ์ƒํƒœ๋ฅผ ๋ณด์—ฌ์ค๋‹ˆ๋‹ค.
  • Cluster Detail
    • Cluster ์ƒํƒœ ์ •๋ณด๋กœ ํ˜„์žฌ๋Š” Agent๊ฐ€ ๋ฐฐํฌ๋œ Node ๋Œ€์ˆ˜์™€ ๋ฒ„์ „์ •๋ณด ์„ค์น˜๋œ ์ฟ ๋ฒ„๋„คํ‹ฐ์Šค ์–ด์นด์šดํŠธ ์ •๋ณด๋ฅผ ๋ณด์—ฌ์ค๋‹ˆ๋‹ค.
  • Prometheus
    • ํ˜„์žฌ ์„ค์น˜๋œ ์Šคํƒ๊ณผ ๋ฒ„์ „ ์ •๋ณด๋ฅผ ๋ณด์—ฌ์ค๋‹ˆ๋‹ค.

ํ™œ์„ฑํ™”๋œ ์ขŒ์ธก์˜ ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ์•„์ด์ฝ˜์„ ํด๋ฆญํ•˜๋ฉด ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ๋Œ€์‹œ๋ณด๋“œ๋กœ ์ด๋™ํ•ฉ๋‹ˆ๋‹ค.

img

๊ธฐ๋ณธ์ ์œผ๋กœ ๋‹ค์Œ๊ณผ ๊ฐ™์ด ํด๋Ÿฌ์Šคํ„ฐ์˜ ์ •๋ณด๋ฅผ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

  • Age(Cluster Age): ํด๋Ÿฌ์Šคํ„ฐ ์ƒ์„ฑํ›„ ๊ฒฝ๊ณผ๋œ ์‹œ๊ฐ„
  • Cluster Status: ํด๋Ÿฌ์Šคํ„ฐ ์ƒํƒœ
    • ๋ชจ๋“  ๋…ธ๋“œ ์ •์ƒ - All Ready, ์ผ๋ถ€ ์ •์ƒ - Partially Ready, ๋ชจ๋“  ๋…ธ๋“œ ๋น„์ •์ƒ - Not Ready
  • Nodes: ๋…ธ๋“œ ๊ฐœ์ˆ˜
  • Unavaliable Node: ๋น„์ •์ƒ ๋…ธ๋“œ ๊ฐœ์ˆ˜
  • Namespaces: ๋„ค์ž„์ŠคํŽ˜์ด์Šค ๊ฐœ์ˆ˜
  • Cluster Pod Usage: ํด๋Ÿฌ์Šคํ„ฐ ํŒŒ๋“œ ์‚ฌ์šฉ๋Ÿ‰
  • Cluster CPU Usage: ํด๋Ÿฌ์Šคํ„ฐ CPU ์‚ฌ์šฉ๋Ÿ‰
  • Cluster Memory Usage: ํด๋Ÿฌ์Šคํ„ฐ ๋ฉ”๋ชจ๋ฆฌ ์‚ฌ์šฉ๋Ÿ‰
  • Cluster Disk Usage: ํด๋Ÿฌ์Šคํ„ฐ ๋””์Šคํฌ ์‚ฌ์šฉ๋Ÿ‰
  • Pods: ํ™œ์„ฑํ™”๋œ ํŒŒ๋“œ ๊ฐœ์ˆ˜
  • Restarted Pods(30m): 30๋ถ„๊ฐ„ ์žฌ์‹œ์ž‘๋œ ํŒŒ๋“œ ๊ฐœ์ˆ˜
  • Failed Pods: ํ˜„์žฌ Failed ์ƒํƒœ์˜ ํŒŒ๋“œ ๊ฐœ์ˆ˜
  • Pending Pods: ํ˜„์žฌ Pending ์ƒํƒœ์˜ ํŒŒ๋“œ ๊ฐœ์ˆ˜
  • PVCs: PersistentVolumeClaim ๊ฐœ์ˆ˜
  • Prometheus Status: ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ํ˜„์žฌ ์ƒํƒœ
  • Alertmanager Status: Alertmanager ํ˜„์žฌ ์ƒํƒœ
  • API Server Status: ํด๋Ÿฌ์Šคํ„ฐ API ์„œ๋ฒ„ ์ƒํƒœ
  • API server total requests code: ํด๋Ÿฌ์Šคํ„ฐ API responce ์ฝ”๋“œ๋ณ„ 5๋ถ„ ํ‰๊ท 

๋” ์ƒ์„ธํ•œ ๋ฉ”ํŠธ๋ฆญ ์ •๋ณด๋ฅผ ํ™•์ธํ•˜๊ธฐ ์œ„ํ•ด ๊ทธ๋ผํŒŒ๋‚˜ ์•„์ด์ฝ˜์„ ํด๋ฆญํ•˜๊ฒŒ ๋˜๋ฉด NodePort๋กœ expose๋œ ๋Œ€์‹œ๋ณด๋“œ๋ฅผ ํ™•์ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

๊ธฐ๋ณธ ๊ณ„์ • ์ •๋ณด๋Š” ์ž…๋ ฅ๊ฐ’์ด ์—†์—ˆ๋‹ค๋ฉด ์•„์ด๋””, ํŒจ์Šค์›Œ๋“œ ๋™์ผํ•˜๊ฒŒ admin:admin์œผ๋กœ ์„ค์ •๋ฉ๋‹ˆ๋‹ค.

img

ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค Configuration ๋ฉ”๋‰ด๋ฅผ ํด๋ฆญํ•˜๋ฉด ํ˜„์žฌ ํ”„๋กœ๋น„์ €๋‹๋œ ์ƒํƒœ์˜ ์„ค์ •์„ ์ˆ˜์ •ํ•  ์ˆ˜ ์žˆ๋Š” ํ™”๋ฉด์ž…๋‹ˆ๋‹ค. ๊ธฐ๋ณธ์ ์ธ yaml์˜ ๋ฌธ๋ฒ• ์ฒดํฌ๋Š” ์—๋””ํ„ฐ ํ™”๋ฉด์—์„œ ๊ฐ€๋Šฅํ•˜๋ฉฐ, promtool ํ…Œ์ŠคํŠธ ๊ธฐ๋Šฅ์„ ํ™”๋ฉด์— ์ ์šฉํ•˜์—ฌ ๊ธฐ๋ณธ์ ์ธ ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ์„ค์ •์— ๋ฌธ์ œ์—ฌ๋ถ€๋ฅผ ํŒŒ์•…ํ•˜๊ณ  ์ด์ƒ์ด ์—†์œผ๋ฉด ์ €์žฅ ๋ฐ ์ ์šฉ์ด ๊ฐ€๋Šฅํ•ฉ๋‹ˆ๋‹ค.

img

ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ์ปจํ”ผ๊ทธ๋ฅผ ์—๋””ํŠธ ํ•˜๊ณ  ํ…Œ์ŠคํŠธ ํ•˜๋Š” ๊ธฐ๋Šฅ์€ Edit, Save & Test๋ฅผ ํ†ตํ•ด ๋™์ž‘ํ•ฉ๋‹ˆ๋‹ค. ํ•ด๋‹น ๋‹จ๊ณ„์—์„œ๋Š” ์ปจํ”ผ๊ทธ์˜ YAML ๋ฌธ๋ฒ• ์˜ค๋ฅ˜์™€ ์ปจํ”ผ๊ทธ์˜ ๊ธฐ๋ณธ์ ์ธ ์˜ค๋ฅ˜๊ฐ€ ์žˆ๋Š”์ง€๋ฅผ ์ฒดํฌํ•ฉ๋‹ˆ๋‹ค.

์ •์ƒ์ ์œผ๋กœ ํ…Œ์ŠคํŠธ๊ฐ€ ์ข…๋ฃŒ๋œ ์ปจํ”ผ๊ทธ๋Š” ์•„๋ž˜์™€ ๊ฐ™์ด ํ…Œ์ŠคํŠธ๊ฐ€ ํ†ต๊ณผ๋˜๋ฉด ์ž„์‹œ๋กœ ์ €์žฅ๋˜๊ฒŒ ๋˜๊ณ , ์‹ค์ œ๋กœ ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ํด๋Ÿฌ์Šคํ„ฐ์— ์ ์šฉ์ด ๋˜์ง€ ์•Š์€ ์ƒํƒœ์ž…๋‹ˆ๋‹ค.

img

ํ…Œ์ŠคํŠธ๋ฅผ ์‹คํŒจํ•˜๋Š” ๊ฒฝ์šฐ๋ฅผ ์‚ดํŽด๋ณด๊ฒ ์Šต๋‹ˆ๋‹ค. ์˜ˆ๋ฅผ ๋“ค์–ด global.scrape_timeout์˜ ๊ฒฝ์šฐ Second ๋‹จ์œ„(s)๋กœ ์ž…๋ ฅํ•  ๊ฒฝ์šฐ 60์ดˆ๋ฅผ ์ดˆ๊ณผํ•˜๋Š” ๊ฐ’์„ ์ž…๋ ฅํ•˜๊ฒŒ ๋˜๋ฉด ๋น„์ •์ƒ์œผ๋กœ ๊ฐ„์ฃผ๋˜์–ด ํ…Œ์ŠคํŠธ๊ฐ€ ์‹คํŒจํ•˜๊ฒŒ ๋ฉ๋‹ˆ๋‹ค. ์‹คํŒจ์˜ ๊ฒฝ์šฐ์—๋Š” ๊ด€๋ จ ๋กœ๊ทธ๋ฅผ ํ™”๋ฉด์— ์ถœ๋ ฅํ•ด์„œ ๋ณด์—ฌ์ฃผ๊ฒŒ ๋ฉ๋‹ˆ๋‹ค.

img

์ปจํ”ผ๊ทธ์— ๋ฌธ์ œ๊ฐ€ ์—†์œผ๋ฉด Apply & Reload๋ฅผ ํ†ตํ•ด ์ ์šฉ์„ ํ•˜๊ณ  ํ”„๋กœ๋ฉ”ํ…Œ์šฐ์Šค ์„œ๋น„์Šค๋ฅผ ์žฌ๊ธฐ๋™ํ•ฉ๋‹ˆ๋‹ค.

img

Alert Configuration๋„ ์œ„์™€ ๋™์ผํ•œ ๋ฐฉ๋ฒ•์œผ๋กœ ์„ค์ • ์ˆ˜์ •, ํ…Œ์ŠคํŠธ ๋ฐ ์ ์šฉ์„ ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.

img