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
Deploying MongoDB on Amazon WS | Michael Karpitsky
Search
Minsk MongoDB User Group
July 05, 2012
Programming
2
110
Deploying MongoDB on Amazon WS | Michael Karpitsky
Michael Karpitsky
Meetup #5
Minsk MongoDB User Group
July 05, 2012
Tweet
Share
More Decks by Minsk MongoDB User Group
See All by Minsk MongoDB User Group
MongoDB by Chef | Yauhen Artsiukhou
bymongo
0
130
MongoDB at IronMQ | Alexander Kolesen
bymongo
0
850
Scaling MongoDB | Sergey Gavruk
bymongo
2
180
Event sourcing + CQRS + MongoDB | Alex Shkor
bymongo
1
640
How it works. Indexes | Kirill Duborenko
bymongo
5
280
Aggregation Framework | Mikhail Burtylev
bymongo
1
98
MongoDB 2.2: Release update + Roadmap | Alvin Richards
bymongo
1
100
Meetup#6 Intro | Alex Litvinok
bymongo
1
46
About the problem of DBMS choice & what to do if you have gone the wrong way | Roman Bugaev
bymongo
3
120
Other Decks in Programming
See All in Programming
LLMOpsのパフォーマンスを支える技術と現場で実践した改善
po3rin
8
980
tool ディレクティブを導入してみた感想
sgash708
1
150
エンジニアのための”最低限いい感じ”デザイン入門
shunshobon
0
130
画像コンペでのベースラインモデルの育て方
tattaka
3
1.9k
デザインシステムが必須の時代に
yosuke_furukawa
PRO
2
110
Constant integer division faster than compiler-generated code
herumi
2
700
『リコリス・リコイル』に学ぶ!! 〜キャリア戦略における計画的偶発性理論と変わる勇気の重要性〜
wanko_it
1
600
Understanding Ruby Grammar Through Conflicts
yui_knk
1
130
AIでLINEスタンプを作ってみた
eycjur
1
200
ソフトウェアテスト徹底指南書の紹介
goyoki
1
110
TDD 実践ミニトーク
contour_gara
0
150
🔨 小さなビルドシステムを作る
momeemt
2
530
Featured
See All Featured
YesSQL, Process and Tooling at Scale
rocio
173
14k
GitHub's CSS Performance
jonrohan
1031
460k
Producing Creativity
orderedlist
PRO
347
40k
KATA
mclloyd
32
14k
How to train your dragon (web standard)
notwaldorf
96
6.2k
How to Ace a Technical Interview
jacobian
279
23k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
8
480
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
283
13k
Rails Girls Zürich Keynote
gr2m
95
14k
Testing 201, or: Great Expectations
jmmastey
45
7.6k
The Language of Interfaces
destraynor
160
25k
Site-Speed That Sticks
csswizardry
10
790
Transcript
Михаил Карпицкий MaeSens.by
А нужен ли AWS? • Небольшой проект – mongolab
• Все сейчас работает и ничего не планирует расти • Хочу пробовать облака! • Не устраивает текущая производительность • Предполагаем рост
OK! Amazon!
Типы EC2-‐инстансов
Бюджетный вариант Replica Sets app mongod (primary)
mongod (secondary) mongod (arbiter)
primary/secondary mongod EBS EBS EBS
EBS EBS EBS EBS /data/db /data/db/journal /var/log Raid10 Raid1
Настройки OS • ext4, xfs • raid10, raid1
• $ blockdev -‐-‐setra 128 /dev/md0 (read-‐ahead) • выключить ayme, dirayme # cat /etc/fstab UUID=6.. /data/db ext4 noayme,nodirayme 0 0
Security group internet app mongod mongod
Port 22, 80, 443 Port 22 Port 22 Port 27017 Port 27017 Port 27017
Security group • Порт 22 из 0.0.0.0/0 •
Порты 27017, 27018 и 27019 из security group приложения • Порты 27017, 27018 и 27019 из security group mongo
> rs.status() • $ mongo • > rs.iniyate()
• > rs.add(node1) • > rs.add(node2) • > rs.status()
Backup (вариант 1) • > use admin •
> db.runCommand({fsync:1, lock:1}); • $ ec2-‐create-‐snapshot –d backup-‐date vol-‐ {1..4} • > db.$cmd.sys.unlock.findOne();
Backup (вариант 2) • $ mongodump –d database
• $ tar zcvf /backups/backup-‐date.tgz dump • $ ec2-‐create-‐snapshot –d backups-‐vol-‐date backup-‐vol-‐1
Вопросы? • Михаил Карпицкий • hŠp://maesens.by/
•
[email protected]
• skype: michael.karpitsky