{"id":260,"date":"2015-11-23T10:17:06","date_gmt":"2015-11-23T10:17:06","guid":{"rendered":"http:\/\/www.haxed.me.uk\/?p=260"},"modified":"2015-11-23T10:17:06","modified_gmt":"2015-11-23T10:17:06","slug":"checking-size-of-database-within-mysql","status":"publish","type":"post","link":"https:\/\/haxed.me.uk\/index.php\/2015\/11\/23\/checking-size-of-database-within-mysql\/","title":{"rendered":"Checking Size of Database within MySQL"},"content":{"rendered":"<p>We had an issue where the rackspace intelligence monitor was giving a different value to the control panel instance of a dbaas. So I came up with a way of testing MySQL for the database size. There is nothing more reliable than running the query like this, I think.<\/p>\n<pre>\r\nSELECT table_schema AS \"Database\", \r\nROUND(SUM(data_length + index_length) \/ 1024 \/ 1024, 2) AS \"Size (MB)\" \r\nFROM information_schema.TABLES \r\nGROUP BY table_schema;\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>We had an issue where the rackspace intelligence monitor was giving a different value to the control panel instance of a dbaas. So I came up with a way of testing MySQL for the database size. There is nothing more &hellip; <a href=\"https:\/\/haxed.me.uk\/index.php\/2015\/11\/23\/checking-size-of-database-within-mysql\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[15,10,7,2,20],"tags":[],"class_list":["post-260","post","type-post","status-publish","format-standard","hentry","category-cloud","category-filesystem","category-management-tools","category-mysql","category-webhosting"],"_links":{"self":[{"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/posts\/260","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/comments?post=260"}],"version-history":[{"count":1,"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/posts\/260\/revisions"}],"predecessor-version":[{"id":261,"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/posts\/260\/revisions\/261"}],"wp:attachment":[{"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/media?parent=260"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/categories?post=260"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/haxed.me.uk\/index.php\/wp-json\/wp\/v2\/tags?post=260"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}