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
Mongo: Performance and Troubleshooting
Search
gamechanger
August 21, 2012
Technology
0
310
Mongo: Performance and Troubleshooting
gamechanger
August 21, 2012
Tweet
Share
More Decks by gamechanger
See All by gamechanger
Concurrency + Mongo
gamechanger
0
110
Mongo and Ops
gamechanger
0
110
Other Decks in Technology
See All in Technology
バッチ処理で悩むバックエンドエンジニアに捧げるAWS Glue入門
diggymo
3
110
Snowflakeの生成AI機能を活用したデータ分析アプリの作成 〜Cortex AnalystとCortex Searchの活用とStreamlitアプリでの利用〜
nayuts
0
160
ヒューリスティック評価を用いたゲームQA実践事例
gree_tech
PRO
0
440
5年目から始める Vue3 サイト改善 #frontendo
tacck
PRO
2
130
MCPで変わる Amebaデザインシステム「Spindle」の開発
spindle
PRO
3
2.3k
AWSで推進するデータマネジメント
kawanago
0
880
Jaws-ug名古屋_LT資料_20250829
azoo2024
3
220
なぜスクラムはこうなったのか?歴史が教えてくれたこと/Shall we explore the roots of Scrum
sanogemaru
1
440
Webブラウザ向け動画配信プレイヤーの 大規模リプレイスから得た知見と学び
yud0uhu
0
180
攻撃と防御で実践するプロダクトセキュリティ演習~導入パート~
recruitengineers
PRO
4
1.8k
Kubernetes における cgroup v2 でのOut-Of-Memory 問題の解決
pfn
PRO
0
450
おやつは300円まで!の最適化を模索してみた
techtekt
PRO
0
260
Featured
See All Featured
Making Projects Easy
brettharned
117
6.4k
A Modern Web Designer's Workflow
chriscoyier
696
190k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
131
19k
Testing 201, or: Great Expectations
jmmastey
45
7.6k
Practical Orchestrator
shlominoach
190
11k
Music & Morning Musume
bryan
46
6.8k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
111
20k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
26
3k
How STYLIGHT went responsive
nonsquared
100
5.8k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
61k
Fashionably flexible responsive web design (full day workshop)
malarkey
407
66k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
18
1.1k
Transcript
Performance & Troubleshooting @kirilnyc @gcsports
• How MongoDB works (layman's version) • Common failure cases
• Best practices
Fundamentals • OS Pager, LRU cache ejection • Working Set
and implications • Documents on disk
Virtual Memory LRU
Working Set
Documents on Disk
Failing • Underestimating Working Set • Ill-Fitting Use Cases •
Schema Design Mistakes
Oops, Overload
Estimating Working Set • Indexes • Core operational data (user
records, etc) • Secondary records (logs, sessions) • Long tail data (historical, related) • Scans*
I Know, Let's use Mongo!
Sub-optimal Use Cases • Session storage • Big fragmented collections
• Giant working sets + performance demands • Clearly tabular data
Simulated Joins!!!
Let's NoSQL! • Look for the largest granularity that works
• Eschew lookup collections • Prefer containment over reference • Query sparingly
Best Practices • Denormalize heavily • Do Capacity Planning •
Live in your slow query logs • Watch the numbers
Documents No thanks. Yes please.
Capacity Planning
Logs *yawn* Ruh-roh...
Numbers • Query load (subjective, learn yours) • Lock percentage
(< 50%) • Queues (single digits) • Page faults (single digits)
@kirilnyc CTO, GameChanger Media http://GC.io/about