Portworx 용 Autopilot 설치
자동 조종 기능을 사용하면 클러스터에서 모니터링 조건을 정의하고 해당 조건이 발생하면 자동으로 변경 사항을 적용할 수 있습니다. 자동 조종 장치에 대한 자세한 내용은 Portworx 문서를 참조하세요.
전제조건
-
자동 파일럿에는 클러스터에서 실행 중인 Prometheus 인스턴스가 필요합니다. Prometheus를 설정하려면 Portworx 클러스터 모니터를 참조하십시오.
-
Prometheus 이 활성화되어 있는지 확인합니다. 활성화되어 있지 않은 경우
storageCluster리소스를 편집하고 Prometheus 구성에서enabled: true을 설정하세요.Prometheus 서비스가 존재하는지 확인합니다:
oc get service -n kube-system prometheus예시 Prometheus 구성:
monitoring: prometheus: alertManager: enabled: true enabled: true exportMetrics: true resources: {} telemetry: {} -
Prometheus 인스턴스가 작성되었는지 확인하십시오.
oc get service -n kube-system prometheusNAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE px-prometheus ClusterIP 172.21.157.200 <none> 9090/TCP 19h참고:
http://prometheus:9090는 Autopilot이 활성화된 경우의 기본 Prometheus 엔드포인트입니다.
자동 구성 설치
-
Autopilot resources 를 다운로드하여
autopilot.yaml파일에 저장하십시오. -
선택사항:
PX-Security를 사용하여 Autopilot을 설치하는 경우,storageCluster를 수정하여PX_SHARED_SECRET환경 변수를 autopilot 섹션에 추가해야 합니다.env: - name: PX_SHARED_SECRET valueFrom: secretKeyRef: key: apps-secret name: px-system-secrets -
클러스터에 자동 조종 장치를 배포합니다.
oc apply -f autopilot.yaml
규칙 작성
이제 클러스터에 자동 조종 장치를 설치했으므로 Portworx 설명서를 참조하여 자동 조종 장치 구성에 대한 사용자 지정 규칙 및 작업을 만드세요.