Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
コンテナをたくさん詰め込んだシステムとランタイムの変化
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Hiroaki Mizuguchi
December 16, 2024
Programming
380
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
コンテナをたくさん詰め込んだシステムとランタイムの変化
10年近くコンテナを利用したシステムを運用してコンテナランタムの使い方がどのように変化してきたのか取り上げます
Hiroaki Mizuguchi
December 16, 2024
Other Decks in Programming
See All in Programming
UnityでSystem.Net.WebSocketsなWebSocketサーバが動かないのでUnity Monoのコードを覗いてみた / about implementing websocket server with unity mono
drumath2237
1
560
IBM Bob Dojo #1 仕様駆動開発入門
oniak3ibm
PRO
0
350
速く作れる。その次は、速く確かめられる開発へ 〜AIネイティブ開発を支える、Shift Down〜 / Can build fast. Next, moving to development where we can verify fast.
rkaga
8
5.6k
Agents on Rails - Rails at Scale 2026
irinanazarova
0
350
KiroのSpecで「五目並べ」を作ってみる
satoshi256kbyte
1
360
mrbgem 三角測量 開発
ogom
0
210
見えないものを探る要求要件定義に必要な基本的思考 / invisible-requirement-thinking
minodriven
15
7.8k
GemmaをJevのように使ってみる / Use Gemma like Jev
kishida
5
720
月間100万人のサービス刷新で、 技術選定をHonoに振り切った話
yutobara
2
3.1k
Starting & Sustaining Code-Based E2E Testing for Non-Coding QA Teams( #jasstniigata )
teyamagu
PRO
1
920
ソニーのクラウド共通基盤の変遷とAI時代の開発スタイルに合わせた進化 / The Journey of Sony’s Common Cloud Platform and Its Evolution for AI-Native Development
kenjiyoneyama
0
240
Unity6 URPによる海底をテーマにしたVJシステムの解説 | Unity Shader 完全に理解した 勉強会
gam0022
0
340
Featured
See All Featured
Digital Projects Gone Horribly Wrong (And the UX Pros Who Still Save the Day) - Dean Schuster
uxyall
1
3.3k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
52
6.1k
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
450
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
2
930
How to Ace a Technical Interview
jacobian
280
24k
Become a Pro
speakerdeck
PRO
31
6.3k
Skip the Path - Find Your Career Trail
mkilby
1
250
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
2
530
Conquering PDFs: document understanding beyond plain text
inesmontani
PRO
4
3.2k
Templates, Plugins, & Blocks: Oh My! Creating the theme that thinks of everything
marktimemedia
31
2.9k
Kristin Tynski - Automating Marketing Tasks With AI
techseoconnect
PRO
0
540
Into the Great Unknown - MozCon
thekraken
41
2.8k
Transcript
コンテナをたくさん 詰め込んだシステム とランタイムの変化 HIROAKI MIZUGUCHI INTERNET INITIATIVE JAPAN INC. CONTAINER
RUNTIME MEETUP #6 2024-12-16
自己紹介 名前: 水口 弘明 X: @m_akihiro, Github: akihiro
所属: Internet Initiative Japan Inc. 仕事: ネットワーク監視システムの開発運用、サーバOS周りのコンサルティング
IIJプライベートバックボーンサービス IIJのサービスや他社クラウドを相互接続 できる閉域網を提供 テナントごとに独立した閉域網を多数管理 2013年10月サービス開始
なぜ多数のコンテナを動かすのか? テナント毎にアドレス空間は独立し、テナント間ではアドレスが重複するから Tenant A Tenant B Tenant C Probe
For A Probe For B Probe For C 192.168.0.10 192.168.0.10 192.168.0.10 backend 169.254.0.0/16, fe80::/10 Link-Local Address
2014年 device mapperの導入 Containerのlayered filesystemとしてdevice mapper実装を導入 コンテナの収容に対してdevice mapperがボトルネック
o ブロックデバイスレイヤーで実装 o コンテナ毎にファイルキャッシュが独立 64GBのホストに250テナント/500コンテナを収容 o NetNSを保持するpause+CNI機能を持つ内製したgolang製のコンテナ o 監視サービス用の内製したpython3のコンテナ o 50GBほどのメモリ消費で安定していた Devicemapper Filesystem (file cache) Application
2018年 overlayfsの導入 Runtimeのlayered filesystemとしてoverlayfs実装を採用 同一コンテナイメージならファイルキャッシュが共有される コンテナ内部プログラムの書き換え
NetNS保持コンテナとしてk8sのpauseに置き換え、CNI相当をホスト側へ 監視プログラムをGo言語製に置き換え 96GBのホストに500テナント/1000コンテナを収容 メモリ消費は15GB程度で安定 Filesystem (file cahce) OverlayFS Application
Container Runtimeのfootprint 2014年docker、2018年docker+containerdを採用 コンテナの数に比例してContainer Runtimeのfootprintが問題視 500テナント/1000コンテナのOSのThread数
GoのRuntimeはCPU数程度のスレッドを作る。不足するともっと沢山作る containerd: 1k threads containerd-shim: total 10k threads pauseコンテナ: 500 threads アプリ本体のコンテナ(tini相当+本体): total 20k threads
2024年 daemonlessのpodman daemonlessのpodman+quadletを採用 管理用の常駐プロセス不要 containerd-shim相当のconmonはsingle thread動作
podmanは直接netnsを指定可能 → pauseコンテナ不要 アプリケーションコンテナの設計見直し Zombie reaperをGo製の内製ツールからtini(single thread動作)に変更 1ホスト当たり1000テナント/1000コンテナを収容
非k8s環境でのコンテナ管理 Podman Quadletとsystemdの組み合わせが良い(個人の感想です) Quadletはpodmanのsystemd-generatorとして実装 systemd.service likeな設定ファイルでコンテナ管理できる
Podman quadletとansibleの組み合わせが良い(個人の感想です) Ansibleとpodmanは共にredhatが開発している Podman用のansible roleもメンテナンスされている 沢山のコンテナの設定をjinjaテンプレートで管理できる NRIのような高度なリソース管理機能が要らないならおすすめ