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
VolumePluginの仕組みと実装解説
Search
Kyohei Mizumoto
February 22, 2021
Technology
0
94
VolumePluginの仕組みと実装解説
勉強会の資料です。
https://k8sinternal.connpass.com/event/203946/
Kyohei Mizumoto
February 22, 2021
Tweet
Share
More Decks by Kyohei Mizumoto
See All by Kyohei Mizumoto
コンテナサプライチェーンセキュリティ
kyohmizu
1
80
サイバーセキュリティの最新動向:脅威と対策
kyohmizu
1
220
コンテナセキュリティの基本と脅威への対策
kyohmizu
4
1.5k
安全な Kubernetes 環境を目指して
kyohmizu
4
1.1k
Unlocking Cloud Native Security
kyohmizu
5
1.3k
コンテナ × セキュリティ × AWS
kyohmizu
10
3.8k
コンテナセキュリティ
kyohmizu
10
4.2k
コンテナイメージのマルウェア検出とその実用性について
kyohmizu
4
3.4k
Play with 🐐 in Kubernetes
kyohmizu
1
1.3k
Other Decks in Technology
See All in Technology
分解して理解する Aspire
nenonaninu
1
350
なぜ私は自分が使わないサービスを作るのか? / Why would I create a service that I would not use?
aiandrox
0
790
Nekko Cloud、 これまでとこれから ~学生サークルが作る、 小さなクラウド
logica0419
2
990
RECRUIT TECH CONFERENCE 2025 プレイベント【高橋】
recruitengineers
PRO
0
160
表現を育てる
kiyou77
1
220
Building Products in the LLM Era
ymatsuwitter
10
5.6k
株式会社EventHub・エンジニア採用資料
eventhub
0
4.3k
レビューを増やしつつ 高評価維持するテクニック
tsuzuki817
1
770
偶然 × 行動で人生の可能性を広げよう / Serendipity × Action: Discover Your Possibilities
ar_tama
1
1.2k
プロダクトエンジニア 360°フィードバックを実施した話
hacomono
PRO
0
100
Tech Blogを書きやすい環境づくり
lycorptech_jp
PRO
1
250
Windows の新しい管理者保護モード
murachiakira
0
110
Featured
See All Featured
BBQ
matthewcrist
87
9.5k
VelocityConf: Rendering Performance Case Studies
addyosmani
328
24k
Into the Great Unknown - MozCon
thekraken
35
1.6k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
33
2.8k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
226
22k
The Invisible Side of Design
smashingmag
299
50k
The Art of Programming - Codeland 2020
erikaheidi
53
13k
4 Signs Your Business is Dying
shpigford
182
22k
Building a Scalable Design System with Sketch
lauravandoore
461
33k
Build The Right Thing And Hit Your Dates
maggiecrowley
34
2.5k
Measuring & Analyzing Core Web Vitals
bluesmoon
6
240
The Power of CSS Pseudo Elements
geoffreycrofte
75
5.5k
Transcript
VolumePluginの仕組みと実装解説
varsion: v2 name: "Kyohei Mizumoto" role: "SRE" interests: - "kubernetes"
- "public cloud" - "golang" twitter: "@kyohmizu" url: "https://kyohmizu.com/" whoami
今⽇話すこと VolumePluginの概要 Volume作成の仕組み 実装解説 VolumeManager VolumePlugin (emptyDir/ConfigMap/Secret)
注意点 kubernetes v1.20.2ベースでお話しします Linuxノードに直接作成するVolumeが対象です (Windowsノード、CSI等は取り扱いません) 理解不⾜により内容に誤りがある可能性があります…︕
kubeletについて こちらを参照 https://speakerdeck.com/bells17/kubelet
VolumePluginについて kubelet内で動作するPlugin pod.spec.volumesに基づいてノード上にVolumeを作成する Volumeの種類ごとにPluginが⽤意されている https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.20/#volume-v1-core
Volume作成の仕組み
引⽤︓https://speakerdeck.com/bells17/kubelet?slide=17
None
None
Volume作成の仕組み desired state of world ノードに作成・アタッチすべきVolume⼀覧 actual state of world
ノードに作成・アタッチされたVolume⼀覧 desired state of world populator ノードにスケジュールされたPod⼀覧からdswを更新する reconciler dswとaswを⽐較し、未作成のVolumeの作成とaswの更新を⾏う
実装解説
実装解説 VolumePlugin定義 初期化 (kubelet起動時) Volume作成の流れ VolumePluginの実装 emptyDir ConfigMap Secret
実装解説 emptyDir/ComfigMap/Secretの保存パスについて Secretはメモリ領域(tmpfs)に作成される ComfigMap/Secretの動的更新と修復 emptyDirのv1.20での修正内容
実装解説 資料のリンク https://gist.github.com/kyohmizu/23ab1e76ebc2a2984694b144a0be9b78