pinpoint server 2.5.4 k8s deploy

2024. 10. 18. 08:09·CloudNative/Observability & Analysis

사전준비

reviously, pinpoint k8s 배포를 위해 Docker이미지와 YAML 작성을 해보았다.
https://fullmooney.tistory.com/56

pinpoint server 2.5.4 base image build for k8s

pinpoint 는 docker-compose로 배포되고 있어서, kubernetes 환경에 설치방법에 대한 가이드가 없는 것으로 보였다. docker-compose로 구성은 아주 간단히 잘 되었지만, 주로 PaaS를 사용하고 있기 때문에 설치

fullmooney.tistory.com

 
https://fullmooney.tistory.com/57

pinpoint server 2.5.4 YAML for k8s

previously, docker image 빌드를 해보았다.https://fullmooney.tistory.com/56 pinpoint server 2.5.4 base image build for k8spinpoint 는 docker-compose로 배포되고 있어서, kubernetes 환경에 설치방법에 대한 가이드가 없는 것으

fullmooney.tistory.com

 배포순서

각 YAML 을 순서에 따라 배포해야 하는데, 가장 먼저 zoo1, zoo2, zoo3을 배포한다.

% kubectl create -f zoo1.yaml -f zoo2.yaml -f zoo3.yaml 
deployment.apps/zoo1 created
service/zoo1 created
deployment.apps/zoo2 created
service/zoo2 created
deployment.apps/zoo3 created
service/zoo3 created

zookeeper가 배포되는 동안 pvc, cm을 먼저 배포해놓고 mysql 과 redis를 배포해보자.

% kubectl create -f mysql-data.yaml 
persistentvolumeclaim/mysql-data created
% kubectl create -f hbase-data.yaml 
persistentvolumeclaim/hbase-data created
% kubectl create -f mysql.yaml                         
deployment.apps/pinpoint-mysql created
service/pinpoint-mysql created

redis는 이전 게시물에 빠뜨려서 YAML을 신규로 만들면서 해보자

% kubectl create deploy pinpoint-redis --image redis:7.0.14 --port 6379 --replicas 1 --dry-run=client -o yaml > pinpoint-redis.yaml
% cat pinpoint-redis.yaml 
apiVersion: apps/v1
kind: Deployment
metadata:
  creationTimestamp: null
  labels:
    app: pinpoint-redis
  name: pinpoint-redis
spec:
  replicas: 1
  selector:
    matchLabels:
      app: pinpoint-redis
  strategy: {}
  template:
    metadata:
      creationTimestamp: null
      labels:
        app: pinpoint-redis
    spec:
      containers:
      - image: redis:7.0.14
        name: redis
        ports:
        - containerPort: 6379
        resources: {}
status: {}
% kubectl apply -f pinpoint-redis.yaml
deployment.apps/pinpoint-redis created
% kubectl expose deploy pinpoint-redis --port 6379 --target-port 6379 --dry-run=client -o yaml > pinpoint-redis-svc.yaml
% cat pinpoint-redis-svc.yaml 
apiVersion: v1
kind: Service
metadata:
  creationTimestamp: null
  labels:
    app: pinpoint-redis
  name: pinpoint-redis
spec:
  ports:
  - port: 6379
    protocol: TCP
    targetPort: 6379
  selector:
    app: pinpoint-redis
status:
  loadBalancer: {}
% kubectl apply -f pinpoint-redis-svc.yaml 
service/pinpoint-redis created

zookeeper가 배포되었다면 hbase를 배포한다.

% kubectl create -f pinpoint-hbase.yaml 
statefulset.apps/pinpoint-hbase created
service/pinpoint-hbase-0 created

 
hbase가 배포된 이후 jobmanager, taskmanager, collector를 배포해야하는 것에 유의하자.
docker compose에서는 jobmanager, taskmanager가 구동되는데 hbase만 depends_on에 명시되어 있지만, 구동 이후 collector를 찾기 때문에 collector 를 먼저 시작해준 뒤 jobmanager, taskmanager를 실행해주자
 

% kubectl create -f pinpoint-collector.yaml 
deployment.apps/pinpoint-collector created
service/pinpoint-collector created
% kubectl create -f pinpoint-flink.yaml 
statefulset.apps/pinpoint-flink created
service/pinpoint-flink-0 created

 
이제 마지막으로 pinpoint-web을 실행한다.

% kubectl create -f pinpoint-web.yaml 
statefulset.apps/pinpoint-web created
service/pinpoint-web created

 
여기까지 차례차례 올라오는 것을 보면서 진행했다면 별 문제 없이 서비스들이 모두 구동되었을 것이다.
너무 급하게 처리하다 보니 순서가 꼬인 경우에는 다시 모든 오브젝트를 제거한 후 다시 배포해보고 그래도 되지 않는다면, PVC에 데이터문제일 수 있으므로  
(보통 이런 에러)

Caused by: org.apache.hadoop.hbase.TableNotFoundException

 
PV를 날리고 PVC부터 다시 생성하고 배포를 처음부터 다시 해야한다.
 
이제 pinpoint-web을 istio ingressgateway나 nginx ingress 를  통해 접근하거나 nodeport로 노출시킨 뒤 localhost로 접근해보자.
 

 

Next

다음으로 pinpoint agent를 springboot application에 jib build 시 javaagent로 등록하고 pinpoint server에서 동작을 확인해 보자.
 
https://fullmooney.tistory.com/59

jib maven 으로 pinpoint agent 배포

pinpoint server를 k8s에 배포하였으니https://fullmooney.tistory.com/58 pinpoint server 2.5.4 k8s deploypreviously, pinpoint k8s 배포를 위해 Docker이미지와 YAML 작성을 해보았다.https://fullmooney.tistory.com/56 pinpoint server 2.5.4

fullmooney.tistory.com

 

728x90

'CloudNative > Observability & Analysis' 카테고리의 다른 글

springboot log pipeline: EFK setup (opensearch)  (1) 2024.10.28
jib maven 으로 pinpoint agent 배포  (0) 2024.10.18
pinpoint server 2.5.4 YAML for k8s  (0) 2024.10.17
pinpoint server 2.5.4 base image build for k8s  (1) 2024.10.17
pinpoint APM docker-compose  (2) 2024.08.07
'CloudNative/Observability & Analysis' 카테고리의 다른 글
  • springboot log pipeline: EFK setup (opensearch)
  • jib maven 으로 pinpoint agent 배포
  • pinpoint server 2.5.4 YAML for k8s
  • pinpoint server 2.5.4 base image build for k8s
yunapapa
yunapapa
working on the cloud
    250x250
  • yunapapa
    supermoon
    yunapapa
  • 전체
    오늘
    어제
    • 분류 전체보기 (94)
      • 개발 (20)
        • java (17)
        • web (2)
        • MSX (1)
        • Go (0)
      • CloudNative (50)
        • App Definition & Developeme.. (17)
        • Orchestration & Management (4)
        • Runtime (3)
        • Provisioning (7)
        • Observability & Analysis (14)
        • event review (5)
      • AWS (7)
      • 환경관련 (17)
      • 취미생활 (0)
        • 맛집 (0)
        • 게임 (0)
  • 블로그 메뉴

    • 홈
    • 태그
    • 방명록
  • 링크

    • CNCF Past Events
    • Kubernetes Korea Group
  • 공지사항

  • 인기 글

  • 태그

    티스토리챌린지
    springboot
    dop-c02
    오블완
    helm
    kubernetes
    gitlab
    Pinpoint
    k8s
    devops
    APM
    OpenShift
    AWS
    istio
    Java
  • 최근 댓글

  • 최근 글

  • hELLO· Designed By정상우.v4.10.3
yunapapa
pinpoint server 2.5.4 k8s deploy
상단으로

티스토리툴바