Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Optimizing Your Cloud Applications in RightScale


Published on

RightScale Webinar: Performance tuning applications in the public cloud is both easier and harder than on your own server hardware. It's much easier to scale up and scale out in the cloud but you generally don't have much (if any) control over the hardware. With public cloud, you take the building blocks offered by the cloud infrastructure and design the application architecture to scale based on the capacity planning requirements and scalability testing results. In this session, we'll talk through our experiences scaling and performance tuning the RightScale platform in the cloud and share tips for sizing, auto-scaling, monitoring, and troubleshooting large-scale cloud deployments.

Published in: Technology
  • Be the first to comment

Optimizing Your Cloud Applications in RightScale

  1. 1. Optimizing Your Cloud Applications in RightScale<br />October 13, 2011<br />Watch the video of this webinar<br />
  2. 2. Your Panel Today<br />Presenting<br /><ul><li>Rafael H. Saavedra, VP Engineering, RightScale
  3. 3. Raphael Simon, Sr. Systems Architect, RightScale</li></ul>Q&A <br />Jordan Evans, Account Manager, RightScale<br />Please use the “Questions” window to ask questions any time!<br />
  4. 4. Agenda<br />Introduction<br />3-tier application architecture<br />Vertical & horizontal scaling<br />RightScale monitoring and cluster graphs<br />New Relic RPM<br />Support for optimizing DB performance<br />Load testing<br />Please use the “Questions” window to ask questions any time!<br />
  5. 5. Multi-tenancy<br />Shared resource pooling<br />Geo-distribution and ubiquitous network access<br />Service oriented<br />Dynamic resource provisioning<br />Self-organizing<br />Utility based pricing<br />Cloud computing characteristics<br />
  6. 6. No upfront investment<br />Lowering operating costs<br />Highly scalable<br />Easy access<br />Reduces business risk and maintenance costs<br />Enables process automation<br />Cloud computing advantages<br />
  7. 7. 3-tier application architecture<br />Load balancers<br />An array of application servers<br />Master-slave <br />
  8. 8. Optimizing Your Cloud Applications in RightScale<br />Vertical & Horizontal Scaling<br />
  9. 9. Instance size (vertical scaling)<br />Instance autoscaling (horizontal scaling)<br />Server arrays<br />RightScale support for performance optimization<br />ServerTemplates are configured to capture performance data<br />CollectdRightScripts<br />Hardware & OS monitoring data<br />Specialized plugins – MySQL, HAProxy, Apache, NgInx, IIS, etc<br />Monitoring graphs: individual, cluster, stacked, heat maps<br />Alerts & escalations<br />New Relic RPM<br />Cloud performance optimization<br />
  10. 10. Compute units vs memory<br />Scaling up – spectrum of instance sizes<br />
  11. 11. Server arrays provide horizontal scaling <br />
  12. 12. The array scales up or down based on performance votes<br />Tags allow scaling on an arbitrary decision set<br />Decision threshold controls reaction time<br />Sleep time allows new resources to have an impact<br />Scaling can be time dependent<br />Detailed setup instructions:<br />Fast response to changes in load conditions using alerts <br />Allocation of servers to availability zones based on weights<br />Deployment-based so configuration is consistent <br />Arrays can be pre-scaled to support anticipated demand <br />Server arrays provide horizontal scaling <br />
  13. 13. Optimizing Your Cloud Applications in RightScale<br />Monitoring & Cluster Graphs<br />with RightScale<br />
  14. 14. Server monitoring graphs<br />
  15. 15. Cluster monitoring<br />Individual graphs<br />Good for a dozen servers<br />Displays all standard graphs with full detail<br />Stacked graphs<br />Displays the contribution of many servers to a total<br />Great to see the sum and variability of activity in a cluster<br />Difficult to make out individual servers<br />Examples: requests/sec, cpu busy cycles, I/O bytes/sec<br />Heat maps<br />Displays a bar for each server<br />Great to see uneven distribution across servers<br />Great to quickly spot performance problems across many servers<br />Difficult to read absolute values or see the total cluster activity<br />
  16. 16. Cluster monitoring architecture<br />Architecture<br />Monitoring front-end serverspull data from storage servers<br />Up to 100 servers on one graph(to be increased)<br />monitoring<br />storage<br />servers<br />monitoring<br />front-end<br />servers<br />your servers<br />
  17. 17. Cluster monitoring<br />Current cluster monitoring: one graph per server<br />
  18. 18. Stacked graphs<br />Each color band shows contribution of one server<br />Servers are stacked on top of one another<br />
  19. 19. Heat maps<br />Each horizontal strip shows one server<br />The color shows how “hot” the server is running<br />
  20. 20. Heat map with 100 servers<br />
  21. 21. Stacked graph of the same 100 servers<br />
  22. 22. Optimizing Your Cloud Applications in RightScale<br />Application Performance Analytics with New Relic<br />
  23. 23. Real-Time App Performance Analytics<br />Supports Ruby, PHP, Java & .Net<br />SQL & NoSQL performance<br />Web transaction tracing<br />Performance notifications<br />Availability monitoring<br />Scalability analysis<br />New Relic RPM <br />
  24. 24. New Relic RPM<br />Direct access from RightScale dashboard<br />
  25. 25. New Relic RPM<br />Historical statistics over a period of time<br />
  26. 26. New Relic RPM<br />Distribution of the most time consuming requests<br />
  27. 27. New Relic RPM<br />Statistics about response times from different countries<br />
  28. 28. New Relic RPM<br />Detailed response times by browser<br />
  29. 29. An expensive query<br />The N+1 query problem<br />New Relic RPM – 2 Examples<br />
  30. 30. Optimizing Your Cloud Applications in RightScale<br />Optimizing Database Performance<br />
  31. 31. Optimizing DB performance<br />RightScale MySQLServerTemplates<br />Configuration files tailored to instance size<br />innodb_buffer_pool_size<br />key_buffer_size<br />thread_size<br />sort_buffer_size<br />The never ending task of identifying current bottlenecks<br />Disk seeks<br />Performance of disk operations<br />Scale up when working set cannot fit in memory – avoid active swapping<br />Constant monitoring of performance graphs, logs and query<br />Schema considerations<br />
  32. 32. Schema considerations<br />Lookups need to be indexed<br />Sorting requires an index<br />Joins need to be done on indices<br />Become slower as tables grow<br />Compounded indices should be used consistently<br />Do not abuse indices<br />Each index requires a disk write<br />Compact tables if they become fragmented<br />Deleted rows do not remove the corresponding index entries<br />
  33. 33. Monitoring DB performance<br />Standard collectd statistics<br />User vs wait time (disk operations)<br />Performance of disk operations<br />Scale up when working set cannot fit in memory<br />MySQLcollectdplugin<br />Monitor INSERT, SELECT, UPDATE operations<br />The breakdown of read operations can indicate missing indices<br />Monitoring /var/log/mysqlslow.log file<br />Identify slow queries<br />Use MySQL EXPLAIN command to identify query plan<br />
  34. 34. MySQLCollectdPlugin<br />Uses MySQL SHOW STATUS command to collect statistics<br />A large set of counters that are divided into 10 categories<br />Connections<br />IO Requests<br />Select Rates<br />Read Rates<br />Key Rates<br />Commands Rates<br />Query Cache<br />Tables<br />Memory<br />Misc.<br />
  35. 35. MySQLCollectdPlugin<br />Uses MySQL SHOW STATUS command to collect statistics<br />
  36. 36. Mysqlslow.log & explain command<br />
  37. 37. MySQL performance depends on locality<br />Wait time should be minimum when working set fits in memory<br />Performance degrades once wait time is significant<br />wait time insignificant<br />user time dominates<br />
  38. 38. MySQL reads graphs<br />Read-random-next represents a table scan<br />Read-next represents an index scan<br />
  39. 39. Optimizing Your Cloud Applications in RightScale<br />Load Testing<br />
  40. 40. Load testing using httperf<br />RightScale provides ServerTemplates in the marketplace<br /><br />Tutorial on httperf setup and configuration<br /><br />
  41. 41. Getting Started and Q&A<br />Contact RightScale:<br />Next up in the “I’m in the Cloud – Now What?” series:<br />October 20<br />Automating Servers in the Cloud<br /><ul><li> Darryl Eaton, Dir. Product Management, RightScale</li></ul><br />(866) 720-0208<br /><br /><br />More Info<br />Webinar archive:<br />Whitepapers:<br />Free Edition:<br />RightScale Conference<br />Nov 8-9 in Santa Clara, CA<br /><br /><ul><li>Attend technical breakout sessions
  42. 42. Talk with RightScale customers
  43. 43. Ask questions at the Genius Bar</li>