-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Dev] prometheus target 정상화 (feat. dashboard 확인) #33
Comments
etcd관련하여 prometheus scape관련 다른부분도 함께 보기시작했고 몇몇 수집하지 못하는 컴포넌트들 확인
이에 수동으로 node간 security group에 모든 TCP 포트개방 후
느낌같은 느낌으로는.... listening port의 bind가 잘못 지정된듯함 |
kubeproxy는 pod로 kube-system에 띄워져있고 수집관련 내역은 정상적으로 잘 연동된 상황 (아래는 수집방법) pod의 상태는
설정은 kube-system에 configmap의 kube-proxy에 "metricsBindAddress: ''" 로 설정되어 있어 "metricsBindAddress: 0.0.0.0"로 바꿔주고 해소됨
관련 명세 (https://kubernetes.io/ko/docs/reference/command-line-tools-reference/kube-proxy/)
해당pod의 실행문은
|
security group으로 한정해도 모든 포트를 열면 자꾸 삭제하는 뭔가가 있음... -> cluster api가 자신이 만든것 외에는 모두 원복시키는 듯 본 작업의 세부내역은 다음 두가지가 진행되어야 함
|
워커노드간 통신가능토록 하는 방법security group을 만들고 AWSMachine과 AWSMachineTemplate의 spec에 그 id를 등록하면 가능
https://blog.scottlowe.org/2020/04/22/using-existing-aws-security-groups-with-cluster-api/ |
티켓명과 내용을 확장하여 다음 스프린트에 이어서 작업하겠습니다. [Dev] ETCD 관련 대시보드 정상화 => prometheus target 정상화 (feat. dashboard 확인) |
corssplane을 사용한 security group 생성 |
앞에서 찾은 방법에 따르면 additionalSecurityGroups: 위치를 채워줘야 하는데 추후 수정은 불가 (Immutable)
따라서 클러스터를 만들기전에 넣어줘야하는데 우리는 VPC를 따로 만들지 않기 때문에 이것도 사실상 불가 남은 방법은
또 다른 뭔가가 있을까? |
추가로 awscluster의 cr의 network부분에 ingress 설정을 할 수 있는데 여기 설정시 권한 문제로 동작불가.
해당입력부분
|
작성중.. 메뉴얼 TACO LMA 구축 후 수행해줘야 하는 일들TACO LMA를 구축하고 나면 기본적인 모니터링 파이프라인이 완성적으로 설치된다. 다만 aws에서 네트워크간 통신이 안되는 문제가 있으므로 모든 데이터 수집을 위해서는 다음과 같은 작업이 필요하다. 노드간 통신 설정하기TACO의 모니터링기능에서 노드간 통신을 통해 데이터를 수집하는 영역이 다음과 같다.
위 범위로 지정된 노도들끼리 해당 포트들에 접근 가능하도록 설정한다. security group을 만들고 모두 넣어줄 수 있다. (개발 옵션1 - security group 생성)이를 위해 해당 vpc내에 taco-internal이라는 보안그룹이 설정되어 있는데 이를 각 인스턴스에 등록해 준다. (개발없이)각 포트가 통신할수 있도록 알아서 해라. |
위에 구축후 security group생성을 crossplane으로 수행할 수 없나요? |
|
찾아보니 custom security group을 넣는게 쉬운 이슈가 아니군요. kubernetes-sigs/cluster-api-provider-aws#392 security group을 만들어 놓고, aws api로 기존 인스턴스에 붙이는 건 가능할 것은 같으나.. 뭔가 땜빵같고. 아니면, https://github.com/kubernetes-sigs/cluster-api-provider-aws/tree/main/pkg/cloud/services/securitygroup 를 우리가 고쳐서 직집 빌드해서 쓰는 방법은 너무 나가는걸까요? 그냥 생각 나는데로 적어 보았습니다. |
"우리가 코드를 고쳐 업스트림" 관련 awscluster 지정관련 에러내역을 분석해 보면
너무 광범위함, 문구를 통해 다음 부근에서 발생하는 것으로 추정되나 내장함수도 많고.. |
exporter 를 NodePort 대역으로 사용하는 방법이 있을런지요. nodeexporter 의 경우 host network 을 사용하는데 띄울 때 아예 포트를 32001 번 식으로 지정가능 하면요. 물론 이 방법은 나중에 다른 Service 가 NodePort 를 사용할 때 중복될 확률이 존재할 수 있다는 문제가 있지만요. |
중복문제는 먼저 선점하면 되니 상관없어 보이지만 노드포트 뒷단에 연결되는 것이 서비스 개체이라서 효용성이 없어 보입니다. |
node exporter는 chart에 hostnetwork disable 가능하던데, 그러면 어떻게 되는걸까요? |
clusternetwork에 띄우겠지요. 그러면 개별 클러스터ip를 찾아서 접근해야 할텐데.. 어떻게 하는지는 모르겠네요 |
exporter 의 svc 에 Port 가 현재 9100 번인데, Port 와 NodePort 전부 바꾸는 방법이요. |
process exporter (9256)
node exporter (9100)
etcd (2379)proxy (10249)
|
(etcd) kubeadm을 통한 포트변경은 불가
kubeadm 을 통한 etcd 수정관련 extraArgs관련 수정참조 https://kubernetes.io/docs/setup/production-environment/tools/kubeadm/setup-ha-etcd-with-kubeadm/#setting-up-the-cluster ------------------ 아래는 읽지 않아도 무방, 필요하면 하단에 댓글로 정리애서 달것-------------------- 현상을 정리하면
따라서 만들어진 VM을 조사해봄
syslog 패턴
위 내역으로 판단해본결과, 그리고 다양한 시도를 해본 결과 kubeadm을 통해서 port를 변경하여 띄우는 것은 불가!! root@ip-10-0-76-149:~# crictl logs 07b0332bbc905
{"level":"info","ts":"2022-03-19T05:31:34.285Z","caller":"etcdmain/etcd.go:72","msg":"Running: ","args":["etcd","--advertise-client-urls=https://$HOSTNAME:32379","--cert-file=/etc/kubernetes/pki/etcd/server.crt","--client-cert-auth=true","--data-dir=/var/lib/etcd","--initial-advertise-peer-urls=https://10.0.76.149:2380","--initial-cluster=ip-10-0-76-149.ap-northeast-2.compute.internal=https://10.0.76.149:2380","--key-file=/etc/kubernetes/pki/etcd/server.key","--listen-client-urls=https://$HOSTNAME:32379","--listen-metrics-urls=http://127.0.0.1:2381","--listen-peer-urls=https://10.0.76.149:2380","--name=ip-10-0-76-149.ap-northeast-2.compute.internal","--peer-cert-file=/etc/kubernetes/pki/etcd/peer.crt","--peer-client-cert-auth=true","--peer-key-file=/etc/kubernetes/pki/etcd/peer.key","--peer-trusted-ca-file=/etc/kubernetes/pki/etcd/ca.crt","--snapshot-count=10000","--trusted-ca-file=/etc/kubernetes/pki/etcd/ca.crt"]}
{"level":"warn","ts":"2022-03-19T05:31:34.285Z","caller":"etcdmain/etcd.go:74","msg":"failed to verify flags","error":"expected IP in URL for binding (https://$HOSTNAME:32379)"}
|
Describe the Story
범위 외
아래 티켓을 진행하면서 내용을 부분(etcd) 에서 모니터링 전체로 확장하여 진행하는 것임
예전 내역
ETCD 관련 대시보드 정상화
etcd 대시보드 안나오는 현상이 발생하고 있음
etcd export -> prometheus -> grafana의 흐름에 따른 문제 파악 및 해결
구체적으로 다음 내역을 포함: 수집기 설정 및 동작확인, 매트릭 수집확인, grafana의 dashboard의 동작확인 (2개의 대시보드가 포함되어 있음, 종합/etcd 전용)
Acceptance criteria (Validation Scenario)
- [ ] This is something that can be verified to show that this story is satisfied.
- [ ] This should have information for QA to validate this story.
Additional information (Optional)
The text was updated successfully, but these errors were encountered: