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
Docker Containers Monitoring by Leo Unbekandt
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
API Strategy & Practice Conference
April 24, 2015
Technology
110
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Docker Containers Monitoring by Leo Unbekandt
API Strategy & Practice Conference
April 24, 2015
More Decks by API Strategy & Practice Conference
See All by API Strategy & Practice Conference
APIStrat 2016 | The end of polling: why and how to transform a REST API into a Data Streaming API (Audrey Neveu)
apistrat
12
340
APIStrat 2016 | OpenAPI Trek: Beyond API Documentation (Arnaud Lauret)
apistrat
5
250
APIStrat 2016 | Flying Dreams: Real-Time Communication from the Edge of Space (Jonathan Barton, Neha Abrol)
apistrat
1
180
APIStrat 2016 | On-prem support? That was so 1982 (Charlie Ozinga)
apistrat
0
150
APIStrat 2016 | Effortless microservices in production with Kubernetes (Ken Wronkiewicz)
apistrat
0
190
Song by Tony Blank
apistrat
0
220
API Lifecycle Manager by Steve Fonseca
apistrat
2
280
APIs In The Enterprise: How Walgreens Formed It's Digital Business by Drew Schweinfurth
apistrat
1
420
Developers Are Difficult by Andrew Noonan
apistrat
0
160
Other Decks in Technology
See All in Technology
AWS ネットワーク構築でハマった(ハマりかけた) 5選とそこから得た教訓
nagisa53
4
220
Kiro Crew入門 - 常駐エージェントの仕組みと使いどころ / Intro to Kiro Crew
k_adachi_01
1
110
名刺メーカーDevグループ 紹介資料
sansan33
PRO
0
1.2k
LanceDB入門
mocobeta
7
510
生成 AI の基礎 〜 サンプル実装で学ぶ基本原理
enakai00
7
4.4k
Genie Codeハンズオン基礎編
taka_aki
1
120
制約理論(ToC)入門 2026版
recruitengineers
PRO
8
2.3k
ラジオの科学
frievea
0
320
侵入は突然に 〜 IoTマルウェアと悪用される家庭の機器 ~ / When Intrusion Strikes: IoT Malware and the Abuse of Home Devices
nttcom
0
5.6k
Sansan Engineering Unit 紹介資料
sansan33
PRO
1
4.9k
【CEDEC2026】Creative Approaches to Localizing the Dialects and Unique Speech of Umamusume: Pretty Derby Characters in English
cygames
PRO
3
22k
JavaScript 研修 (2026)
recruitengineers
PRO
2
540
Featured
See All Featured
Winning Ecommerce Organic Search in an AI Era - #searchnstuff2025
aleyda
1
2.1k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.5k
Highjacked: Video Game Concept Design
rkendrick25
PRO
1
430
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.7k
[RailsConf 2023] Rails as a piece of cake
palkan
59
6.9k
Thoughts on Productivity
jonyablonski
76
5.3k
Utilizing Notion as your number one productivity tool
mfonobong
4
540
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Optimizing for Happiness
mojombo
378
71k
Information Architects: The Missing Link in Design Systems
soysaucechin
0
1.1k
Building Flexible Design Systems
yeseniaperezcruz
330
40k
Transcript
Docker containers monitoring Berlin 2015
Léo Unbekandt @Soulou CTO at Scalingo
Deploy, Build, Scale, Repeat
Our customers want metrics to help them in their decision
making
DOCKER AS A TOOL ?
DOCKER AS A TOOL • Deployment … OK
DOCKER AS A TOOL • Deployment … OK • Execution
… OK
DOCKER AS A TOOL • Deployment … OK • Execution
… OK • Monitoring … ?
- Memory usage - CPU percentage - Disk IO -
Network bandwidth What metrics?
Docker Remote API GET /containers/:id/stats Stats API
Docker Remote API generates load
Docker Remote API is not configurable
Docker →is not enough So
Linux API Control groups Namespaces
Control Groups CPU, Memory, IO Namespaces Network
Memory usage? Memory cgroup /sys/fs/cgroup/memory/docker/:id
Memory cgroup Files memory.usage_in_bytes memory.limit_in_bytes memory.memsw.usage_in_bytes memory.memsw.limit_in_bytes Bytes Are Easy
CPU usage? cpuacct cgroup /sys/fs/cgroup/cpuacct/docker/:id
Cpuaccnt cgroup Files cpuacct.usage cpuacct.usage_percpu → number of nanoseconds allocated
to the container since its start
Nanoseconds? Let's calculate!
How to get a CPU percentage? /proc/stat User nice system
idle iowait irq softirq 7277 51882 500481 6104557 72847 217 168631 Sum of values = CPU usage since system boot (in 1/100th second)
Delta of container usage = 0-100% ———————————————————— Delta of system
usage How to get a CPU percentage?
What are the IO? blkio cgroup /sys/fs/cgroup/blkio/docker/:id → Bytes read/write
by device
blkio cgroup File blkio.io_service_bytes
Namespaces Networking
Not a control group unfortunately… Network namespace
Network namespace Monitoring agent in the namespace setns() Linux system
call
Network namespace Don't worry github.com/Scalingo/go-netns
Interface Received bytes packets errs … eth0 12520750 102418 0
lo 7796 560 0 Interface Transmit bytes packets errs … eth0 641338 165423 0 lo 97796 250 0 Netstat in namespace
Enter “Acadock” Acadock monitoring Linux APIs Docker HTTP API Acadock
HTTP API Data visualisation via websockets
Got what we want
Thank you Léo Unbekandt - @Soulou github.com/Scalingo/acadock-monitoring github.com/Scalingo/acadock github.com/Scalingo/go-netns github.com/Scalingo/go-netstat