MongoDB and Windows Azure

21
Jim O’Neil Technical Evangelist http://aka.ms/jimoneil MongoDB and Windows Azure

description

Presentation on MongoDB and Windows Azure presented at MongoDB Boston on October 24th, 2012

Transcript of MongoDB and Windows Azure

Page 1: MongoDB and Windows Azure

Jim O’NeilTechnical Evangelist

http://aka.ms/jimoneil

MongoDB and Windows Azure

Page 2: MongoDB and Windows Azure

Agenda

• Overview of Windows Azure

• MongoDB on Windows Azure• Deploying MongoDB as a Cloud Service

• Deploying MongoDB to a Virtual Machine

• Resources and References

Page 3: MongoDB and Windows Azure

Windows Azure

Global Footprint8 Data Centers24 CDN Nodes

FlexibleCloud Services (PaaS)VMs (IaaS)Web Sites (“hosting”)

OpenWindows ServerUbuntuCentOSSUSE

Page 4: MongoDB and Windows Azure

StorageBig data Database TrafficMobile

Services

Applicationbuilding blocks

Caching IdentityMessagin

g

CDNMediaNetworkin

g

Page 5: MongoDB and Windows Azure

Open Source on Windows AzureMicrosoft collaborates with OSS communities to assure that applications, frameworks and tools work great with Windows Azure

Learn more: http://www.windowsazure.com/en-us/community/open-source-software/

Page 6: MongoDB and Windows Azure

Microsoft Open Technologies, Inc.• Wholly owned subsidiary

• Responsible for advancingthe company’s investmentin openness:• interoperability• open standards• open source

• Collaborating with the MongoDB community since 2011 to improve the MongoDB experience on Windows Azure

Page 7: MongoDB and Windows Azure

90-day Free Trial

http://aka.ms/GetAzureTrial

Page 8: MongoDB and Windows Azure

MongoDB + Windows Azure• MongoDB designed to run in the cloud• Windows Azure supports multiple

architectures for MongoDB deployment• The combination of MongoDB and Windows

Azure provides many benefits:• High scalability and elasticity• On-demand capacity• Pay for only what you use• Faster time-to-market

Page 9: MongoDB and Windows Azure

MongoDB as a Cloud Service (PaaS)• Easiest way to deploy MongoDB

on Windows Azure

• Windows Azure handles ongoing management of the OS and infrastructure

• Infinitely scalable, on demand

• Application and MongoDB in same cloud service provides security boundary

• MongoDB Azure wrapper: http://aka.ms/MongoAzurePaaS

Page 10: MongoDB and Windows Azure

A container of related service roles

Web Role Worker Role

Windows Azure Cloud Service (PaaS)

Page 11: MongoDB and Windows Azure

Blobstorage

Replica Set

MVC Movie

Replica Sets

Manager

Primary

Secondary

Secondary

Cloud Drives

Page 12: MongoDB and Windows Azure
Page 13: MongoDB and Windows Azure

MongoDB on VMs (IaaS)• When compared to worker role:

more control, but requires more responsibility• Sharding• Internal endpoints• Security

• Windows Installer: http://bit.ly/WKxGA7

• Linux walkthrough: http://bit.ly/KlAu3R/

Page 14: MongoDB and Windows Azure

Blob storage

Shardingmongos (router)

Key Range A-H

Primary

Secondary

Secondary

Key Range I-R

Primary

Secondary

Secondary

Key Range S-Z

Primary

Secondary

Secondary

Your App

mongos (router)mongo

sConfigserver

LB

Page 15: MongoDB and Windows Azure
Page 16: MongoDB and Windows Azure

Virtual Machine Sizes

Each Persistent Data Disk can be up to 1 TB

VM Size CPU Cores Memory Bandwidth

(Mbps)# Data Disks

Extra Small Shared 768 MB 5 1

Small 1 1.75 GB 100 2

Medium 2 3.5 GB 200 4

Large 4 7 GB 400 8

Extra Large 8 14 GB 800 16

Page 17: MongoDB and Windows Azure

Scripting Capabilities• Windows Azure PowerShell Cmdlets• Cross Platform Scripting Built on node.js• Service Management API• Capabilities:

• Provisioning, Removal• Reboot, Start• Import and Export VM settings• Support for Windows and Linux VMs• Fully Customize VM with Data Disks and Endpoint

Configuration• Automate Virtual Network Settings

Page 18: MongoDB and Windows Azure

Example: Provisioning a Replica Setazure vm create mongoc9 "OpenLogic__OpenLogic-CentOS-62-20120531-en-us-30GB.vhd" username password -l "West US" -e azure vm create mongoc9 "OpenLogic__OpenLogic-CentOS-62-20120531-en-us-30GB.vhd" username password -l "West US" -e 23 -c azure vm create mongoc9 "OpenLogic__OpenLogic-CentOS-62-20120531-en-us-30GB.vhd" username password -l "West US" -e 24 -c

azure vm endpoint create mongoc9 27017 27017azure vm endpoint create mongoc9-2 27018 27018azure vm endpoint create mongoc9-3 27019 27019

SSH into each instance and:get mongodb binaries and installcreate db dirstart mongod, initialize replica set

Page 19: MongoDB and Windows Azure

MongoDB + Windows Azure benefits

Flexible

Deployment: PaaS or IaaS

Languages: Java, PHP, Node.JS, .NET, Python, etc.

OS: Windows Server, CentOS, Ubuntu, SUSE

ScalableSupport for horizontal scaling and sharding

Support for responsive auto-scaling

Page 20: MongoDB and Windows Azure

Resources• MongoDB on Azure• MongoDB Experts video series• Windows Azure Training Kit• OSS-on-Azure tutorials• Install MongoDB on a Centos VM in Windows

Azure• Node.js Web Application with Storage on

MongoDBhttp://aka.ms/

AzureMongoBoston2012

Page 21: MongoDB and Windows Azure

Q&A

http://aka.ms/AzureMongoBoston2012