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
260
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
2024/4/26 コンピュータ歴史博物館解説告知
toshi_atsumi
0
200
Data and AI Governance: Existing Challenges and Emerging Trends
scotthsieh825
0
160
インシデントレスポンスのライフサイクルを廻すポイントってなに / Pinpoints of Incidentresponse Lifecycle for Operation
sakaitakeshi
1
300
継続的な改善 x ⾮連続的な進化
sansantech
PRO
3
100
長期間TiDBを使ってきた話 @ 私たちはなぜNewSQLを使うのかTiDB選定5社が語る選定理由と活用LT / Experiences with TiDB Over Time
chibiegg
2
740
Algyan イベント振り返り
linyixian
0
190
株式会社EventHub・エンジニア採用資料
eventhub
0
1.9k
SIEMを用いて、セキュリティログ分析の可視化と分析を実現し、PDCAサイクルを回してみた
coconala_engineer
0
220
Hands-on / Kaname Frusawa / Cloud Compare Users Meetup 2024 at University of Tokyo on April 17
paraworld
2
470
オーナーシップを持つ領域を明確にする
konifar
12
2.7k
Garoon 開発チーム / Garoon development team
cybozuinsideout
PRO
2
2.9k
検証を通して見えてきたTiDBの性能特性
lycorptech_jp
PRO
6
3.4k
Featured
See All Featured
Building Applications with DynamoDB
mza
88
5.6k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
29
6k
10 Git Anti Patterns You Should be Aware of
lemiorhan
646
57k
For a Future-Friendly Web
brad_frost
171
8.9k
Making the Leap to Tech Lead
cromwellryan
123
8.5k
5 minutes of I Can Smell Your CMS
philhawksworth
199
19k
Design by the Numbers
sachag
274
18k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
243
20k
What's new in Ruby 2.0
geeforr
337
31k
Making Projects Easy
brettharned
108
5.5k
Visualization
eitanlees
135
14k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
13
1.5k
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