{"id":838,"date":"2012-07-31T08:29:00","date_gmt":"2012-07-31T08:29:00","guid":{"rendered":"http:\/\/www.websitedesignwebsitedevelopment.com\/?p=838"},"modified":"2014-03-24T10:34:07","modified_gmt":"2014-03-24T10:34:07","slug":"database-optimization-experience-rackspace-cloud","status":"publish","type":"post","link":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/","title":{"rendered":"Database Optimization Experience &#8211; Rackspace Cloud"},"content":{"rendered":"<h2>Database Optimization Experience &#8211; Rackspace Cloud<\/h2>\n\n\t\t<style>\n\t\t\t#gallery-1 {\n\t\t\t\tmargin: auto;\n\t\t\t}\n\t\t\t#gallery-1 .gallery-item {\n\t\t\t\tfloat: left;\n\t\t\t\tmargin-top: 10px;\n\t\t\t\ttext-align: center;\n\t\t\t\twidth: 33%;\n\t\t\t}\n\t\t\t#gallery-1 img {\n\t\t\t\tborder: 2px solid #cfcfcf;\n\t\t\t}\n\t\t\t#gallery-1 .gallery-caption {\n\t\t\t\tmargin-left: 0;\n\t\t\t}\n\t\t\t\/* see gallery_shortcode() in wp-includes\/media.php *\/\n\t\t<\/style>\n\t\t<div id='gallery-1' class='gallery galleryid-838 gallery-columns-3 gallery-size-thumbnail'><dl class='gallery-item'>\n\t\t\t<dt class='gallery-icon landscape'>\n\t\t\t\t<a href='https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/attachment\/db_optimization\/'><img loading=\"lazy\" decoding=\"async\" width=\"150\" height=\"150\" src=\"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization-150x150.png\" class=\"attachment-thumbnail size-thumbnail\" alt=\"\" \/><\/a>\n\t\t\t<\/dt><\/dl><dl class='gallery-item'>\n\t\t\t<dt class='gallery-icon landscape'>\n\t\t\t\t<a href='https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/attachment\/db_optimization_0\/'><img loading=\"lazy\" decoding=\"async\" width=\"150\" height=\"150\" src=\"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0-150x150.png\" class=\"attachment-thumbnail size-thumbnail\" alt=\"\" \/><\/a>\n\t\t\t<\/dt><\/dl>\n\t\t\t<br style='clear: both' \/>\n\t\t<\/div>\n\n<h3>Conversation:<\/h3>\n<p>Hello,<\/p>\n<p>It has come to our attention that the database xyz has been running some queries that take an extremely long time to complete and have started to become detrimental to the shared resource that the database is hosted on. At this time, we have not imposed any restrictions on the database, however, if the issue persists, such restrictions may become necessary in order to preserve the shared resource in question.<\/p>\n<p>Here are the queries in question that have been running slowly.<\/p>\n<p>If you have any questions, please feel free to contact us!<br \/>\nThank you,<\/p>\n<p>Cloud Sites Operations<br \/>\nPreviously the script was querying to 4 or more tables for single record or list of records. It is corrected by DE-normalization. Now only tbl_content table and sometimes the favorite articles table will be using in JOIN query but most of the queries will be depending on single table. For this, we have implemented a cron job script which query to the required tables via JOIN and update that single tbl_content table. We have checked the facebook URL as well. Please check the website at your end and update us if any further improvement is required. Thanks for the cooperation regarding database privileges reversion.<\/p>\n<p>If, in case, you think its necessary to disable the database like it was on 27 July 2012. You can put &#8220;die();&#8221; or &#8220;exit();&#8221; in index.php instead of disabling the database. Because our cron jobs script is continuously fetching the news from API and it does matter for us. We are standby with you to resolve the queries problem. I think only 1 query is left which you requested to review. Can you please check it again because that is updated as well.<\/p>\n<p>Thank you,<\/p>\n<p>Fahad Mahmood<br \/>\nHello,<\/p>\n<p>I haven&#8217;t noticed any load spikes on this MySQL host since re-enabling this database, however I do see some extremely long running queries. For example, a query examines over 55 million rows and runs for several minutes:<\/p>\n<p>Please look into indexing and optimizing these. I don&#8217;t see any issues at the moment but if several of these queries were executed simultaneously it could create excessive load and performance issues for other customers. For a large, high resource database like this you might also consider looking into Cloud Servers or a dedicated solution where you would have full control over server configuration and resources.<\/p>\n<p>Regards,<\/p>\n<p>Systems Operations<br \/>\nRackspace Cloud Sites<br \/>\nHello,<\/p>\n<p>I have reviewed both queries, please have a look on the first one again. I have implemented LIMIT on it even for pagination count.<\/p>\n<p>The second query is in our CRON JOB script which will not be running by any user or user related activity. It runs on weekly basis and picks limited no. of records from different categories to FORM a weekly newsletter. I will ask the CTO about this query but i am sure that it will not create problem in future because its frequency will remain the same as it is user independent activity.<\/p>\n<p>We are still looking for improvement of the queries if you feel any of them?<\/p>\n<p>Thanks,<\/p>\n<p>Fahad Mahmood<br \/>\nHello Fahad,<\/p>\n<p>Thanks for your work in optimizing this database. I don&#8217;t see any slow queries from our slow logs today so I went ahead and restored the connection limit for your database users. We will continue to monitor over the next 24 hours and let you know if we run into any issues.<\/p>\n<p>Regards,<\/p>\n<p>Systems Operations<br \/>\nRackspace Cloud Sites<br \/>\nHello,<\/p>\n<p>I haven&#8217;t seen any recent long running queries and there haven&#8217;t been any load spikes on this MySQL server over the past few hours. I&#8217;m going to go ahead and mark this ticket as solved. We&#8217;ll continue monitoring and let you know if we come across any further issues.<\/p>\n<p>Regards,<\/p>\n<p>Systems Operations<br \/>\nRackspace Cloud Sites<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Database Optimization Experience &#8211; Rackspace Cloud Conversation: Hello, It has come to our attention that the database xyz has been running some queries that take an extremely long time to complete and have started to become detrimental to the shared resource that the database is hosted on. At this time, we have not imposed any [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":840,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[60],"tags":[],"class_list":["post-838","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-database"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.9 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Database Optimization Experience - Rackspace Cloud<\/title>\n<meta name=\"description\" content=\"Database Optimization Experience - Rackspace Cloud\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Database Optimization Experience - Rackspace Cloud\" \/>\n<meta property=\"og:description\" content=\"Database Optimization Experience - Rackspace Cloud\" \/>\n<meta property=\"og:url\" content=\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/\" \/>\n<meta property=\"og:site_name\" content=\"AndroidBubble Blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/pages\/Website-Design-Website-Development\/172363336135453\" \/>\n<meta property=\"article:published_time\" content=\"2012-07-31T08:29:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2014-03-24T10:34:07+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png\" \/>\n\t<meta property=\"og:image:width\" content=\"991\" \/>\n\t<meta property=\"og:image:height\" content=\"503\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Fahad\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Fahad\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/\"},\"author\":{\"name\":\"Fahad\",\"@id\":\"https:\/\/androidbubble.com\/blog\/#\/schema\/person\/0a833b633f744c3a5e0de7c9a94e71f7\"},\"headline\":\"Database Optimization Experience &#8211; Rackspace Cloud\",\"datePublished\":\"2012-07-31T08:29:00+00:00\",\"dateModified\":\"2014-03-24T10:34:07+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/\"},\"wordCount\":649,\"image\":{\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png\",\"articleSection\":[\"Database\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/\",\"url\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/\",\"name\":\"Database Optimization Experience - Rackspace Cloud\",\"isPartOf\":{\"@id\":\"https:\/\/androidbubble.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png\",\"datePublished\":\"2012-07-31T08:29:00+00:00\",\"dateModified\":\"2014-03-24T10:34:07+00:00\",\"author\":{\"@id\":\"https:\/\/androidbubble.com\/blog\/#\/schema\/person\/0a833b633f744c3a5e0de7c9a94e71f7\"},\"description\":\"Database Optimization Experience - Rackspace Cloud\",\"breadcrumb\":{\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#primaryimage\",\"url\":\"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png\",\"contentUrl\":\"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png\",\"width\":\"991\",\"height\":\"503\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/androidbubble.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Website Development\",\"item\":\"https:\/\/androidbubble.com\/blog\/category\/website-development\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Database\",\"item\":\"https:\/\/androidbubble.com\/blog\/category\/website-development\/database\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Database Optimization Experience &#8211; Rackspace Cloud\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/androidbubble.com\/blog\/#website\",\"url\":\"https:\/\/androidbubble.com\/blog\/\",\"name\":\"AndroidBubble Blog\",\"description\":\"Articles &amp; Posts\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/androidbubble.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/androidbubble.com\/blog\/#\/schema\/person\/0a833b633f744c3a5e0de7c9a94e71f7\",\"name\":\"Fahad\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/androidbubble.com\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/afab5bcad71955d142a69df1758e6710aed4ab9cc2b5da28c54a7c3f39801b73?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/afab5bcad71955d142a69df1758e6710aed4ab9cc2b5da28c54a7c3f39801b73?s=96&d=mm&r=g\",\"caption\":\"Fahad\"},\"sameAs\":[\"http:\/\/www.androidbubbles.com\/\",\"https:\/\/x.com\/phpFlex\"],\"url\":\"https:\/\/androidbubble.com\/blog\/author\/admin\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Database Optimization Experience - Rackspace Cloud","description":"Database Optimization Experience - Rackspace Cloud","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/","og_locale":"en_US","og_type":"article","og_title":"Database Optimization Experience - Rackspace Cloud","og_description":"Database Optimization Experience - Rackspace Cloud","og_url":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/","og_site_name":"AndroidBubble Blog","article_publisher":"https:\/\/www.facebook.com\/pages\/Website-Design-Website-Development\/172363336135453","article_published_time":"2012-07-31T08:29:00+00:00","article_modified_time":"2014-03-24T10:34:07+00:00","og_image":[{"width":991,"height":503,"url":"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png","type":"image\/png"}],"author":"Fahad","twitter_misc":{"Written by":"Fahad","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#article","isPartOf":{"@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/"},"author":{"name":"Fahad","@id":"https:\/\/androidbubble.com\/blog\/#\/schema\/person\/0a833b633f744c3a5e0de7c9a94e71f7"},"headline":"Database Optimization Experience &#8211; Rackspace Cloud","datePublished":"2012-07-31T08:29:00+00:00","dateModified":"2014-03-24T10:34:07+00:00","mainEntityOfPage":{"@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/"},"wordCount":649,"image":{"@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#primaryimage"},"thumbnailUrl":"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png","articleSection":["Database"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/","url":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/","name":"Database Optimization Experience - Rackspace Cloud","isPartOf":{"@id":"https:\/\/androidbubble.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#primaryimage"},"image":{"@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#primaryimage"},"thumbnailUrl":"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png","datePublished":"2012-07-31T08:29:00+00:00","dateModified":"2014-03-24T10:34:07+00:00","author":{"@id":"https:\/\/androidbubble.com\/blog\/#\/schema\/person\/0a833b633f744c3a5e0de7c9a94e71f7"},"description":"Database Optimization Experience - Rackspace Cloud","breadcrumb":{"@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#primaryimage","url":"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png","contentUrl":"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png","width":"991","height":"503"},{"@type":"BreadcrumbList","@id":"https:\/\/androidbubble.com\/blog\/website-development\/database\/database-optimization-experience-rackspace-cloud\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/androidbubble.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Website Development","item":"https:\/\/androidbubble.com\/blog\/category\/website-development\/"},{"@type":"ListItem","position":3,"name":"Database","item":"https:\/\/androidbubble.com\/blog\/category\/website-development\/database\/"},{"@type":"ListItem","position":4,"name":"Database Optimization Experience &#8211; Rackspace Cloud"}]},{"@type":"WebSite","@id":"https:\/\/androidbubble.com\/blog\/#website","url":"https:\/\/androidbubble.com\/blog\/","name":"AndroidBubble Blog","description":"Articles &amp; Posts","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/androidbubble.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/androidbubble.com\/blog\/#\/schema\/person\/0a833b633f744c3a5e0de7c9a94e71f7","name":"Fahad","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/androidbubble.com\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/afab5bcad71955d142a69df1758e6710aed4ab9cc2b5da28c54a7c3f39801b73?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/afab5bcad71955d142a69df1758e6710aed4ab9cc2b5da28c54a7c3f39801b73?s=96&d=mm&r=g","caption":"Fahad"},"sameAs":["http:\/\/www.androidbubbles.com\/","https:\/\/x.com\/phpFlex"],"url":"https:\/\/androidbubble.com\/blog\/author\/admin\/"}]}},"views":490,"jetpack_featured_media_url":"https:\/\/androidbubble.com\/blog\/wp-content\/uploads\/2012\/07\/db_optimization_0.png","_links":{"self":[{"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/posts\/838","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/comments?post=838"}],"version-history":[{"count":5,"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/posts\/838\/revisions"}],"predecessor-version":[{"id":1620,"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/posts\/838\/revisions\/1620"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/media\/840"}],"wp:attachment":[{"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/media?parent=838"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/categories?post=838"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/androidbubble.com\/blog\/wp-json\/wp\/v2\/tags?post=838"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}