Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Amazon Load Balancer Controller クイックオーバービュー / A...
Search
Kohei Ota
November 20, 2020
Technology
1
1.9k
Amazon Load Balancer Controller クイックオーバービュー / Amazon Load Balancer Controller quick overview
Kohei Ota
November 20, 2020
Tweet
Share
More Decks by Kohei Ota
See All by Kohei Ota
CloudNative Meets WebAssembly: Exploring Wasm's Potential to Replace Containers
inductor
3
2.2k
The Cloud Native Chronicles: 10 Years of Community Growth Inside and Outside Japan
inductor
0
110
Cracking the KubeCon CfP
inductor
2
540
KubeCon Recap -Platform migration at Scale-
inductor
1
960
コンテナビルド最新事情 2022年度版 / Container Build 2022
inductor
3
460
データベースとストレージのレプリケーション入門 / Intro-of-database-and-storage-replication
inductor
26
6.2k
KubeConのケーススタディから振り返る、Platform for Platforms のあり方と その実践 / Lessons from KubeCon case studies: Platform for Platforms and its practice
inductor
3
790
オンラインの技術カンファレンスを安定稼働させるための取り組み / SRE activity for online conference platform
inductor
1
1.2k
Kubernetesネットワーキング初級者脱出ガイド / Kubernetes networking beginner's guide
inductor
19
6.1k
Other Decks in Technology
See All in Technology
依存パッケージの更新はコツコツが勝つコツ! / phpcon_nagoya2025
blue_goheimochi
3
180
Swiftの “private” を テストする / Testing Swift "private"
yutailang0119
0
140
データエンジニアリング領域におけるDuckDBのユースケース
chanyou0311
2
220
なぜ私は自分が使わないサービスを作るのか? / Why would I create a service that I would not use?
aiandrox
0
890
コンテナサプライチェーンセキュリティ
kyohmizu
1
120
Classmethod AI Talks(CATs) #17 司会進行スライド(2025.02.19) / classmethod-ai-talks-aka-cats_moderator-slides_vol17_2025-02-19
shinyaa31
0
160
転生CISOサバイバル・ガイド / CISO Career Transition Survival Guide
kanny
3
1.1k
Cloud Spanner 導入で実現した快適な開発と運用について
colopl
1
930
エンジニアのためのドキュメント力基礎講座〜構造化思考から始めよう〜(2025/02/15jbug広島#15発表資料)
yasuoyasuo
18
7.2k
プロダクトエンジニア 360°フィードバックを実施した話
hacomono
PRO
0
120
TAMとre:Capセキュリティ編 〜拡張脅威検出デモを添えて〜
fujiihda
2
370
Windows の新しい管理者保護モード
murachiakira
0
180
Featured
See All Featured
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
40
2k
What's in a price? How to price your products and services
michaelherold
244
12k
The Language of Interfaces
destraynor
156
24k
The Straight Up "How To Draw Better" Workshop
denniskardys
232
140k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
120k
Into the Great Unknown - MozCon
thekraken
35
1.6k
Designing on Purpose - Digital PM Summit 2013
jponch
117
7.1k
Reflections from 52 weeks, 52 projects
jeffersonlam
348
20k
StorybookのUI Testing Handbookを読んだ
zakiyama
28
5.5k
Embracing the Ebb and Flow
colly
84
4.6k
Product Roadmaps are Hard
iamctodd
PRO
50
11k
Transcript
ALB Ingress Controllerあらため AWS Load Balancer Controller クイックオーバービュー JAWS-UGコンテナ支部 #18
Presented by @inductor
じこしょうかい apiVersion: inductor.apps/v1 kind: Person metadata: name: “Kohei Ota” Twitter:
“@_inductor_” GitHub: “@inductor” org: “HPE” role: “Solutions Architect” community: “CNCF Ambassador, CloudNative Days organizer, Docker Meetup Tokyo organizer” spec: replicas: 1
Load Balancer Controllerのおもな追加点 LoadBalancer Serviceが使えるようになった! → 名前がAWS Ingress Controllerじゃなくなった一番大きな理由 AWSのロードバランサーを管理するためのカスタムコントローラー爆誕!
1つのALBを複数のIngressリソースで利用可能になった → これまでのALB IngressはIngressの数=ALBの数でコストかかりがちだった 既存のALBに相乗りするなどもできず、Ingress削除=ALB削除 カスタムリソースTargetGroupBindingが追加 → 既存のALB/NLBに対して割り当てるTarget Groupを管理するためのリソース LBのライフサイクルがKubernetesのServiceに依存しなくなるメリットがある (例: クラスターを消したいけどLBは残したいケース)
Load Balancer Controllerのおもな追加点 LoadBalancer Serviceが使えるようになった! → 名前がAWS Ingress Controllerじゃなくなった一番大きな理由 AWSのロードバランサーを管理するためのカスタムコントローラー爆誕!
1つのALBを複数のIngressリソースで利用可能になった → これまでのALB IngressはIngressの数=ALBの数でコストかかりがちだった 既存のALBに相乗りするなどもできず、Ingress削除=ALB削除 カスタムリソースTargetGroupBindingが追加 → 既存のALB/NLBに対して割り当てるTarget Groupを管理するためのリソース LBのライフサイクルがKubernetesのServiceに依存しなくなるメリットがある (例: クラスターを消したいけどLBは残したいケース) 今日は主にここにフォーカ スします
EKSにおけるLoadBalancer Serviceの種類 LBの種類とモード YAMLのアノテーション LB Controller CLB なし 不要 NLB(instance
mode) service.beta.kubernetes.io/aws-load-balancer-type: "nlb" 不要 NLB(ip mode) service.beta.kubernetes.io/aws-load-balancer-type: "nlb-ip" 必要
EKSにおけるLoadBalancer Serviceの種類 LBの種類とモード YAMLのアノテーション LB Controller CLB なし 不要 NLB(instance
mode) service.beta.kubernetes.io/aws-load-balancer-type: "nlb" 不要 NLB(ip mode) service.beta.kubernetes.io/aws-load-balancer-type: "nlb-ip" 必要 既存のin-tree cloud provider 実装で管理
なぜIPモードの対応が必要か
TargetGroup NodePort TCP: 30001 NodePort TCP: 30001 NodePort TCP: 30001
これまでのService LoadBalancerの振り分け NLB Listener Node Node Node kube-proxy kube-proxy kube-proxy Destination Pod
TargetGroup NodePort TCP: 30001 NodePort TCP: 30001 NodePort TCP: 30001
これまでのService LoadBalancerの振り分け NLB Listener Node Node Node kube-proxy kube-proxy kube-proxy Destination Pod 1. LBがノード(各EC2)のNodePortにロードバランシングしつ つ通信を転送 2. NodePort ServiceからPodのいるノードに通信を転送 3. Podに通信が到達 → これがいわゆる”Instance mode”
IPモードの動き
TargetGroup これまでのService LoadBalancerの振り分け NLB Listener Node Node Node amazon-vpc-cni-k8s Destination
Pod
TargetGroup これまでのService LoadBalancerの振り分け NLB Listener Node Node Node amazon-vpc-cni-k8s Destination
Pod シンプル!!
Appendix: amazon-vpc-cni-k8sについて AWSのVPC上でKubernetesのネットワークを動かすためのCNIプラグイン → CNIが何かについては同じくコンテナ支部で前ぼくが話した 「OSSから理解するEKSとそのエコシステムについて」を御覧ください PodやService(ClusterIP含)にVPCのIPアドレスを割り当てることができるため、AWS のリソースからPod/Serviceに直接通信するようなことも可能 → コンテナネイティブロードバランシングってやつ
今までのService LB実装ではこれに対応しきれていなかった
デモ
まとめ Load Balancer ControllerのNLB-IPを使うとネットワーク由来のボトルネックが 改善される!! ALB Ingressにも嬉しい改善がいっぱい!(今回は時間の関係上取り扱わず) 今日扱った内容の補足資料はこちら YAMLおきば: https://github.com/inductor/aws-container-meetup-sample
前回資料: https://speakerdeck.com/inductor/understanding-eks-and-its-ecosystem-from-oss-perspective