{"id":759,"date":"2011-06-20T09:21:09","date_gmt":"2011-06-20T08:21:09","guid":{"rendered":"http:\/\/kudzia.eu\/b\/?p=759"},"modified":"2011-06-20T13:50:11","modified_gmt":"2011-06-20T12:50:11","slug":"mysql-5-1-turning-onoff-query-logging-on-the-fly","status":"publish","type":"post","link":"https:\/\/kudzia.eu\/b\/2011\/06\/mysql-5-1-turning-onoff-query-logging-on-the-fly\/","title":{"rendered":"mysql 5.1 &#8211; turning on\/off query logging on the fly"},"content":{"rendered":"<p>i dont run query logging &#8211; more to avoid running out of the disk space on \/var\/log than for the performance reasons. but from time to time it&#8217;s good to be able to turn logging on to see what&#8217;s going on. in 5.1 and later versions it&#8217;s possible without restarting the mysqld.<br \/>\n<!--more--><br \/>\nto turn it on:<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\nset global general_log = 'off';  set global general_log_file = '\/var\/log\/mysql\/mysql.log'; set global general_log = 'on';\r\n<\/pre>\n<p>to turn it off:<\/p>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\nset global general_log = 'off';  \r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>i dont run query logging &#8211; more to avoid running out of the disk space on \/var\/log than for the performance reasons. but from time to time it&#8217;s good to be able to turn logging on to see what&#8217;s going on. in 5.1 and later versions it&#8217;s possible without restarting the mysqld.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[17],"tags":[12],"class_list":["post-759","post","type-post","status-publish","format-standard","hentry","category-tech","tag-mysql"],"_links":{"self":[{"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/posts\/759","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/comments?post=759"}],"version-history":[{"count":5,"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/posts\/759\/revisions"}],"predecessor-version":[{"id":762,"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/posts\/759\/revisions\/762"}],"wp:attachment":[{"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/media?parent=759"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/categories?post=759"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kudzia.eu\/b\/wp-json\/wp\/v2\/tags?post=759"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}