GKE 로그 감시가 편리해졌습니다!
6039 단어 GCPGKEloggingmonitoringtech
10초 개요

전제 조건
GCP에서 모니터링 솔루션의 상세한 발췌문
운영 키트(Stackdriver)하면 됩니다.
또 APM(Application Performance Management)으로서 존재
Cloud Trace
,Cloud Debugger
,Cloud Profiler
합니다.주안점
Cloud Operations for GKE라는 이름으로 GKE
Cloud Logging
와 Cloud Monitoring
의 로컬 합병을 진행한다.Cloud Login 구성
Login의 ON/OFF 설정
$ gcloud container clusters create/update NAME
는 실행 중인 --logging 플래그에 의해 지원됩니다.--logging NONE
--logging SYSTEM
--logging WORKLOAD
로그 리소스 매니저 업데이트
로그 기반 경보 기능 등 새로운 기능을 사용하기 위해 로그 자원 관리자를 업데이트합니다.

Pod 로그 조회 찾기


질의 예제)
resource.type="k8s_container"
resource.labels.project_id="PROJECT_ID"
resource.labels.location="asia-northeast1"
resource.labels.cluster_name="CLUSTER_NAME"
resource.labels.namespace_name="default"
resource.labels.pod_name="POD_NAME"
resource.labels.container_name="CONTAINER_NAME"
로그 경고 생성
操作
에서 ログアラートの作成
를 선택합니다.
Alert 설정을 위해 다음을 입력합니다.
通知チャンネルを管理

SAVE



Cloud Monitoring 설정
Monitoring의 ON/OFF
$ gcloud container clusters create/update NAME
는 실행할 때의 모니터 로고가 지원합니다.--monitorign NONE
--monitorign SYSTEM
모니터링 경고 화면 활용 방법
Cloud Logging을 통해 알림 설정을 하고, 메일 알림 등에 포함된
VIEW INCIDENT
을 누르면 모니터의 경고 페이지로 이동한다.이 화면에서는 다음을 수행할 수 있습니다.

들여쓰기가 꺼져 있는 경우 모니터의 경고 화면에서 축소 진행을 제거합니다.
SHOW CLOSED INCIDENTS
를 누르면 닫힌 들여쓰기의 일람을 확인할 수 있습니다.
대상 로그 필터링 예
Cloud Login에서 객체 클러스터를 모니터링하는 콘솔 로그는 json 형식으로 표시됩니다.실제 로그는
textPayLoad
필드에 저장되어 있기 때문에 알림 대상의 로그를 줄이려면 조회에 다음과 같은 정보를 기록해야 한다.textPayLoad="SEVERE hogehoge"
끝맺다
Reference
이 문제에 관하여(GKE 로그 감시가 편리해졌습니다!), 우리는 이곳에서 더 많은 자료를 발견하고 링크를 클릭하여 보았다 https://zenn.dev/khale/articles/gcp-gke-loggin텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
우수한 개발자 콘텐츠 발견에 전념
(Collection and Share based on the CC Protocol.)