1
Steve StasoChief Architect, Web Infrastructure SolutionsGlobal Systems Practice
GET MORE FROM YOUR WEB SERVICE
Scaling MySQL By Leveraging Sun Systems
22
Scaling Concepts and Approaches
Recommendations When/How to Scale
Scaling Test ResultsSun Systems for MySQLLearn more
Agenda
3
Dramatically Change Economics of Web Service Delivery
Drive better performance, value● Get greater performance ● Improve price performance, reduce costs● Operating System, processor choice
Scale for explosive Growth● Scale to +1M concurrent users● Choose best deployment technologies● Predict performance under stress
Simplify Deployments● Leverage best practices, Blue Prints, reference
architectures, subscriptions, systems, software, management expertise
44
Scaling Concepts and Approaches
Recommendations When/How to Scale
Scaling Test ResultsSun Systems for MySQLLearn more
Agenda
5
How to Scale?NetworkLoad
CPULoad
RAM/Caching
I/OLoad
StorageRequirement
• Distribute the connections over multiple servers
• Increase the number of NICs and networks
• More CPUs help up to optimal thread count, more than that is useless
• Scale-out can impact app server activity, scalability can be difficult
• Reduce the logic in the DB server
• More memory is always good• A scale-out can increase the
complexity of the environment• External distributed caching
• Faster disks and controllers always help
• Scale-out is the best option after an initial optimization at server level
• SAN and NAS for large data centers• Scale-out is often cost effective
6
Choose the Right Server ArchitectureServer Scale-up vs. Scale-out for Database Deployments
Scaling Out
Scal
ing
Up
7
Choose the Right Server ArchitectureServer Scale-up vs. Scale-out for Database Deployments
Scaling Out
Scal
ing
Up
8
Choose the Right Server ArchitectureServer Scale-up vs. Scale-out for Database Deployments
Scaling Out
Scal
ing
Up
Diagonal Scaling
9
VirtualizeMethods, benefits, recommendations
Increase utilization, less heat and energy usage
ComputeMemory latency
Build Next Generation Virtual Datacenter
Up to 10 x better price/performance
10
OS
App
App
App
LD
App
App
App
OS
Hypervisor
OS
App
App
App
LD
App
App
App
OS
Hardware
Hypervisor
VM
App
App
App
OS
VM
App
App
App
OS
Implementations of Virtualization
HardwarePartitioning
Zone
App
App
App
OS
Zone Support
Zone
App
App
App
Hardware
OS VirtualizationHardware based Software based
Hardware
Virtualization Enablement Layer
OS
Hardware
DesktopVirtualization
Hypervisor
VM
App
App
App
OS
App
App
App
Hardware
VM
OS
Software
Type I Type I Type II
Hardware
System Virtualization
11
Leading Virtualization ChoicesDifferent approaches, benefits in virtualizing web stack
LDOMSSun xVM
Hyper-V
(future plans)
BSD opensolaris™opensolaris™
12
Server/OS VirtualizationSun Server Virtualization = Decreased Costs, Reduced Complexity
CoolThreads Servers x64/x86 Servers
• Integrated, open source, no cost, and flexible virtualization technology – Logical Domains (LDoms)
• Record-breaking performance• Breakthrough energy and space
efficiency• Available in racks or blades
• Most powerful, scalable, virtualized designs, operating on today’s range of OS options
• Choice of hypervisor and OS allows for investment protection
• Available in racks or blades
LDOMS
1313
Scaling Concepts and Approaches
Recommendations When/How to Scale
Scaling Test ResultsSun Systems for MySQLLearn more
Agenda
14
The Benchmark
DBT2Stored Procedures
DBT2datagen
DBT2 call set with random IDs
mysqlslap
● 100 warehouses created with the datagen utility● 15 GB of data generated for each DB● Extra table used to set random conditions● Extra tables added for transaction count
SP calls to:● Delivery● New Order● Payment
● Order Status● Stock Level
● 100 calls:● 4 Delivery● 45 New Order● 43 Payment
● 4 Order Status● 4 Stock Level● + internal SP calls
● Shoot-out with:● 1,2,4,8,16,32,64,128,256 concurrent connections● 10 iterations● Warm-up (cold) and hot phases
MySQL testbedenvironment
● Red Hat Ent Linux 5.1 64 bit● Solaris 10 x86_64 and SPARC 64● mysql 5.1.26 rc 64 bit● mysql coolstack 1.3.1 (based on 5.1.26) 64 bit
● 512k complex transactions● 51,200 per iteration● 250M single queries● high peak of 40k qps with “\s”
15
The Systems For MySQL Scaling
● 2xAMD 2220 Dual Core 2.8Ghz, 1MB Cache/core● 12 GB RAM, 73 GB SAS Drives 15krpm● 2U Rack Unit, 550PS● MySQL x 1 instance 8GB buffer pool● Estimated List Price: US$5,888● 8xAMD 8220 Dual Core 2.8Ghz, 1MB Cache/core● 64 GB RAM, 73 GB 15k SAS Drives+External Storage● 4U Rack Unit, 850PS● MySQL x 4 instances 6GB buffer pool● Estimated List Price: US$29,995
● 1T2 8 Cores 64 Threads 1.4Ghz, 4MB Cache● 64 GB RAM, 73 GB 15k SAS Drives+External Storage● 2U Rack Unit, 750PS● MySQL x 6 instances 6GB buffer pool● Estimated List Price: US$32,115
Sun Fire x4200 Server
Sun Fire x4600 Server
Sun Fire T5220 Server
16
The DatabaseMySQL Enterprise Solution Enterprise software and services delivered in an annual subscription
• Subscription:• MySQL Enterprise
• License (OEM):• Embedded Server• Support
• MySQL Cluster Carrier-Grade• Training• Consulting• NRE
Database
Monitoring
Support
● The most up-to-date MySQL Enterprise software
● Monthly rapid updates● Quarterly service packs● Hot-fix program● Indemnification
● Virtual database assistant● Global monitoring of all servers● Web-based central console● Built-in advisors, expert advice● Problem query detection/analysis
● Online self-help MySQL Knowledge Base● 24/7 problem resolution with priority
escalation● Consultative help● High-Availability and Scale-Out
17
Test Results: Single Instance
Sun Fire x4200
18
Test Results: Single Instance
Sun Fire T5220
Sun Fire x4600
19
Test Results: Four Instances
Sun Fire x4600
20
Test Results: Six Instances
Sun Fire T5220
2121
Scaling Concepts and Approaches
Recommendations When/How to Scale
Scaling Test ResultsSun Systems for MySQLLearn more
Agenda
22
The application life-cycleThe takeaway for how and when to scale
Start-up● Single instance● Small box or full virtualization Sun Fire x4200
Sun Fire x4200
Sun FireT5220
Digital Entrepreneur● Multiple instances● Virtualized, consolidated
environment
Enterprise● Multiple instances● Virtualized, consolidated
environment
Sun Fire x4600
23
What Can Sun Systems for MySQL Do for Your Web Deployments
● Linux, OpenSolaris, Solaris and Windows; Intel, AMD and SPARC
● Up to 3x more transactions, 3x less power & space,10x price/performance
● Open Storage delivers 2x better storage density, 2x better price/performance,10x the capacity
● Deliver competitive advantage with fast I/O, large memory, optimized Web Stack, system design innovations, SSDs, open source virtualization
● Reduce power, space, cooling costs● Get to market faster with new Web services● Scalability to support millions of users● Free 60 day Try & Buy of systems plus MySQL
Enterprise, get up to 40% off to keep
24
19% Faster than the Dell PE R900on SPEC® JBB2005
World Record Performance Best x86 single Java Virtual Machine
performance on SPEC®jbb2005 benchmark
Targeted at enterprise customers looking for exceptional business process performance in a dense 2RU, 24-processor core platform
• Solaris 10 10/08 Operating system• Java HotSpot™software version 1.6.0_06 Performance Release
Sun Fire X4450 Server
Source: SPEC and SPECjbb are registered trademarks of the Standard Performance Evaluation Corporation. Competitive benchmark results reflect data published as of 9/12/08. For the latest results, visit http://www.spec.org. Sun Fire X4450 (Intel Xeon X7460, 24 cores, 4 chips, 6 cores/chip, Solaris 10): 448,262 SPECjbb2005 bops, 448,262 SPECjbb2005 bops/JVM.
25
Half the Space!
X4450 DL580 G5 PE R900 X3850 M2
Reduced Operating Costs for the Eco Enterprise
26
Sun™ Blade Servers: Superior Flexibility and EfficiencyModular architecture delivers flexibility and efficiencies
• Aggregation of multiple servers
• Common power, cooling, and I/O improves efficiency and reliability
• Modular hot-swappable form factor improves serviceability
Management
Storage
Compute
Cooling
I/O
Power
Modularcomputing
27
●DTrace: safe, comprehensive observability
●Predictive Self Healing for reliability
●ZFS: innovative approach to data Mgmt, scalability, integrity and performance
●Record setting performance●Built-in virtualization●Over 1000 x86 and SPARC systems supported
●180+ open source applications
Fast and Open; Optimized for the Web
28
Professional Network Site Increases Performance by 54% on MySQL
Business Issues• Fast growth was causing reduced
MySQL database response times• Needed scale and manageability for
exponential growth
Sun Solution• Sun & MySQL Enterprise Platinum,
Professional Services• Sun Servers & Solaris
Business Results• 54% improvement in query
performance• 39% reduction in database footprint• Scalable, manageable infrastructure
for further growth
“By using Sun products and Sun Professional Services for our
solution, we can scale horizontally, and we can scale vertically. And we
don't have to change one line of our software code to run dual-core,
quad-core, or sixteen-core machines – or any other hardware
that Sun provides. ” ― Jean-Luc Vaillant, CTO, LinkedIn
sun.com/customers
29
● 10x prove price/performance, 3x more throughput, 83% less power
● Fast, free, open hypervisor, low cost storage arrays
● Breakthrough throughput, eco-efficiency and reliability
● Consolidate up to 128 virtual MySQL servers in 1U/blade format
● Scale MySQL with TomCat, Apache, Lighttpd, SugarCRM, Drupal, others
● Try risk, cost, hassle free, get up to 40% off to convert Try & Buy
Sun Systems for MySQL Virtualization Reduce Environmental Costs, Virtualize & Scale for Maximum Eco-Efficiency
Scaling Sky-high for MySQL Virtualization
T5220 T6320
30
Virtualization with LDoms
• LDoms & CoolThreads improve scalability and utilization• Blueprint demonstrating how LDoms enabled a TomCat / MySQL
service to scale 10x when compared to a single application instance.
• http://wikis.sun.com/download/attachments/24543563/820-4995.pdf
1 2 4 6 8 10 120
1000
2000
3000
4000
5000
6000
7000
8000
9000
Tomcat running JPetStore, MySQL Backend
Number of Logical Domains
Tran
sact
ion
s p
er S
eco
nd
(T
PS
)
31
Messaging Services Innovator Gets 10X Better MySQL Price/Performance
Business Issues•Deliver highly scalable advanced messaging services•Process messages faster and at reduced cost, operate more efficiently
Sun Solution•Sun & MySQL Enterprise Platinum, Professional Services•Sun Servers & Solaris
Business Results•4.5x higher performance, 2x headroom •4x less, 83% less power use•Storage admin from weeks to hours•10x better $/performance for MySQL infrastructure
“We are a company that believes in empowering our customers,
and that power for us comes from Sun. With Sun technology, the only limitation on what we can deliver is our ability to dream. If we can dream it, we can do it ”
― Jason Williams, CTO at DigiTarwww.sun.com/customers
32
● 2x cost/performance over closest competitive offering
● Industry's highest data throughput● 15% less than HP with 2x density,
10% less Dell at nearly 3x density● Up to 70% less power, cooling● Reduces common admin tasks by
as much as 82%● Ideal for rapid Rich Media growth:
photo, video, audio● Try risk, cost and hassle free, get
20% off to convert Try & Buy
Sun Systems MySQL Rich Media StorageGain Control of Exploding Storage Costs for Rich Media
Store Rich Media Without Paying the Price
x4540J4200
J7000
33
Tune and Scale MySQL: Providing Unprecedented Storage Analytics
• Automatic real-time visualization ofapplication and storage related workloads
• Solve performance issues through understanding data usage
• Simple, sophisticated instrumentationwith real-time comprehensive analysis
• Supports multiple simultaneous applicationand workload analysis in real- time
• Analysis can be saved, exported andreplayed for further analysis.
• Built on DTrace instrumentation
34
(5) 400GB 4200 RPM SATA Drives(7) 146GB 10,000 RPM SAS Drives
(1) 32G SSD ZILDevice
(1) 80G SSD CacheDevice
ZFS Hybrid Storage PoolSun X4250 Storage Server Example
Configuration BConfiguration A
● 4 Xeon 7350 Processors● 32GB FB DDR2 ECC DRAM● OpenSolaris with ZFS
35
Raw Capacity(TB)
ZFS Hybrid Pool ExampleBased on Actual Benchmark Results
Hybrid Storage Pool (DRAM + Read SSD + Write SSD + 5x 4200 RPM SATA)
Traditional Storage Pool (DRAM + 7x 10K RPM 2.5”)
Storage Power(Watts)
Read IOPs Write IOPs Cost
3.2x
11%
4%4.9x
2x
36
MySQLEnterprise Unlimited
MySQL Unlimited
• Fixed annual subscription> Unlimited servers> Unlimited CPUs> Unlimited cores
• Simplify> No counting> No compliance issues
• Pricing> No proprietary DBMS license fees> Price starts at $40K/year
3737
Scaling Concepts and Approaches
Recommendations When/How to Scale
Scaling Test ResultsSun Systems for MySQLLearn more
Agenda
38
Start Scaling Your MySQL WithSun Systems for MySQL
Learn More
• Download MySQL TCO White paper
• Download “Scaling Beyond x86: Using LDOMS”
Try it Yourself
• Try a Sun system free for 60 days with MySQL Enterprise
• Kick the tires. Check under the hood. Test it. Stress it.
• Get up to 40% to convert Try & Buy to purchase
• Buy it or return it and pay nothing – not even shipping
sun.com/tryandbuysun.com/mysqlsystems
39
Performance Tuning - Benchmarks - Cloud ComputingData Warehousing - Business Intelligence - Replication
Scale-Out - Java, PHP, .NET, Ruby & AJAXHigh Availability - MySQL Cluster - And much more…
Early Registration Now Open!https://en.oreilly.com/mysql2009/public/register/
40
GET MORE FROM YOUR WEB SERVICE
Scaling MySQL By Leveraging Sun Systems
Learn More:
http://www.sun.com/mysqlsystems
Steve StasoSun Microsystems