3.10.5. 네임스페이스별 Pod 필터링


네임스페이스에 따라 Pod가 제거로 간주되는지 여부를 구성할 수 있습니다. 다음 Descheduler 전략만 네임스페이스 필터링을 지원합니다.

  • PodLifeTime
  • RemovePodsHavingTooManyRestarts
  • RemovePodsViolatingInterPodAntiAffinity
  • RemovePodsViolatingNodeAffinity
  • RemovePodsViolatingNodeTaints

IncludeNamespaces 매개변수를 사용하여 Descheduler 전략을 실행해야 하는 네임스페이스를 지정하거나 ExcludeNamespaces 매개변수를 사용하여 Descheduler 전략을 실행할 네임스페이스를 지정할 수 있습니다.

사전 요구 사항

  • 클러스터 관리자 권한이 있어야 합니다.

프로세스

  1. KubeDescheduler 오브젝트를 편집합니다.

    $ oc edit kubedeschedulers.operator.openshift.io cluster -n openshift-kube-descheduler-operator
  2. 하나 이상의 전략에 IncludeNamespaces 또는 ExcludeNamespaces 매개변수를 추가합니다.

    apiVersion: operator.openshift.io/v1beta1
    kind: KubeDescheduler
    metadata:
    ...
    spec:
      deschedulingIntervalSeconds: 3600
      strategies:
      - name: "RemovePodsHavingTooManyRestarts"
        params:
        - name: "PodRestartThreshold"
          value: "10"
        - name: "IncludingInitContainers"
          value: "false"
        - name: "IncludeNamespaces" 1
          value: "my-project" 2
      - name: "PodLifeTime"
        params:
        - name: "MaxPodLifeTimeSeconds"
          value: "86400"
        - name: "ExcludeNamespaces" 3
          value: "my-other-project" 4
    1 3
    동일한 전략에 IncludeNamespacesExcludeNamespaces 를 둘 다 지정할 수 없습니다.
    2 4
    여러 네임스페이스를 쉼표로 구분합니다.
  3. 파일을 저장하여 변경 사항을 적용합니다.
Red Hat logoGithubRedditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 문서 정보

Red Hat을 사용하는 고객은 신뢰할 수 있는 콘텐츠가 포함된 제품과 서비스를 통해 혁신하고 목표를 달성할 수 있습니다. 최신 업데이트를 확인하세요.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

© 2024 Red Hat, Inc.