본문으로 바로가기 본문 바로가기
WIKI 기술 지식 베이스

Kubernetes Cluster Autoscaler 지원

원문 보기 위키 갱신

Kubernetes Cluster Autoscaler 지원 (실험적 기능)

Longhorn은 기본적으로 Kubernetes Cluster Autoscaler가 노드를 축소(scaling down)하지 못하도록 막고 있어요. Kubernetes Cluster Autoscaler Enabled 설정을 켜면 이 제한을 풀 수 있지만, 재구축 비용과 데이터 안전성에 대한 주의가 필요해요.

출처: 문서

본문

기본적으로 Longhorn은 다음 이유로 Kubernetes Cluster Autoscaler가 노드를 축소하지 못하게 막아요:

  • Longhorn이 모든 엔진 및 복제본 instance-manager 파드에 대해 PodDisruptionBudget을 생성해요.
  • Longhorn instance manager 파드는 엄격한(strict) PodDisruptionBudget을 가지고 있어요.
  • Longhorn instance manager 파드는 Kubernetes 내장 워크로드 컨트롤러에 속하지 않아요.
  • Longhorn 파드는 로컬 스토리지 볼륨 마운트를 사용해요.

자세한 내용은 What types of pods can prevent CA from removing a node?를 참고하세요.

Kubernetes Cluster Autoscaler의 스케일링을 허용하려면 Kubernetes Cluster Autoscaler Enabled 설정을 활성화하면 돼요.

이 설정을 활성화하면 Longhorn은 instance-manager PodDisruptionBudget을 가능한 최소한만 유지해요. 각 볼륨은 instance-manager PodDisruptionBudget의 보호를 받는 복제본을 최소 하나 이상 가지면서, Cluster Autoscaler의 축소를 막는 중복 PodDisruptionBudget은 존재하지 않게 돼요.

이 설정을 활성화하면 Longhorn은 Kubernetes 내장 워크로드 컨트롤러에 속하지 않거나 로컬 스토리지 마운트를 사용하는 Longhorn 워크로드에 cluster-autoscaler.kubernetes.io/safe-to-evict 어노테이션도 추가해요.

경고: Kubernetes Cluster Autoscaler가 재사용 가능한 복제본을 가진 노드를 제거할 수 있기 때문에, 복제본 재구축 비용이 커질 수 있어요.

더 알아보기 (Learn more)