{"id":25597,"date":"2024-11-24T08:11:01","date_gmt":"2024-11-24T00:11:01","guid":{"rendered":"https:\/\/fwq.ai\/blog\/25597\/"},"modified":"2024-11-24T08:11:01","modified_gmt":"2024-11-24T00:11:01","slug":"mysql-5-7-%e5%ae%89%e8%a3%85%e5%bf%85%e5%a4%87%e7%9a%84-my-ini-%e9%85%8d%e7%bd%ae%ef%bc%9a%e5%93%aa%e4%ba%9b%e5%8f%82%e6%95%b0%e6%98%af%e5%bf%85%e9%9c%80%e7%9a%84%ef%bc%9f-2","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/25597\/","title":{"rendered":"MySQL 5.7 \u5b89\u88c5\u5fc5\u5907\u7684 my.ini \u914d\u7f6e\uff1a\u54ea\u4e9b\u53c2\u6570\u662f\u5fc5\u9700\u7684\uff1f"},"content":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/001\/246\/273\/173063738196255.jpg\" class=\"aligncenter\" title=\"MySQL 5.7 \u5b89\u88c5\u5fc5\u5907\u7684 my.ini \u914d\u7f6e\uff1a\u54ea\u4e9b\u53c2\u6570\u662f\u5fc5\u9700\u7684\uff1f\u63d2\u56fe\" alt=\"MySQL 5.7 \u5b89\u88c5\u5fc5\u5907\u7684 my.ini \u914d\u7f6e\uff1a\u54ea\u4e9b\u53c2\u6570\u662f\u5fc5\u9700\u7684\uff1f\u63d2\u56fe\" \/><\/p>\n<p><strong>MySQL 5.7 \u5b89\u88c5\u4e2d\u5fc5\u5907\u7684 my.ini \u914d\u7f6e<\/strong><\/p>\n<p>\u5728 MySQL 5.7 \u7684\u5b89\u88c5\u8fc7\u7a0b\u4e2d\uff0c\u60a8\u53ef\u80fd\u9700\u8981\u914d\u7f6e my.ini \u6587\u4ef6\u4ee5\u6ee1\u8db3\u7279\u5b9a\u7684\u9700\u6c42\u3002\u5c3d\u7ba1 MySQL \u53ef\u4ee5\u4f7f\u7528\u9ed8\u8ba4\u914d\u7f6e\u9879\u542f\u52a8\uff0c\u4f46\u4ee5\u4e0b\u53c2\u6570\u5bf9\u4e8e\u5927\u90e8\u5206\u5b89\u88c5\u90fd\u662f\u5fc5\u9700\u7684\u6216\u63a8\u8350\u7684\uff1a<\/p>\n<ul>\n<li> <strong>basedir\uff1a<\/strong>\u6307\u5b9a MySQL \u7684\u5b89\u88c5\u4f4d\u7f6e\uff0c\u901a\u5e38\u4e3a \/usr\/local\/\u3002<\/li>\n<li> <strong>datadir\uff1a<\/strong>\u786e\u5b9a\u6570\u636e\u5b58\u50a8\u7684\u4f4d\u7f6e\uff0c\u5efa\u8bae\u521b\u5efa\u4e00\u4e2a\u4e13\u95e8\u7684\u76ee\u5f55\uff0c\u5982 \/data\/mysql\u3002<\/li>\n<\/ul>\n<p>\u5176\u4ed6\u5e38\u7528\u914d\u7f6e\u53c2\u6570\u5305\u62ec\uff1a<\/p>\n<ul>\n<li> <strong>default-character-set\uff1a<\/strong>\u5728\u5ba2\u6237\u7aef\u73af\u5883\u4e2d\u4f7f\u7528\u7684\u9ed8\u8ba4\u5b57\u7b26\u96c6\uff0c\u5efa\u8bae\u4f7f\u7528 &#8220;utf8&#8243;\u3002<\/li>\n<li> <strong>character-set-server\uff1a<\/strong>MySQL \u670d\u52a1\u5668\u4f7f\u7528\u7684\u9ed8\u8ba4\u5b57\u7b26\u96c6\uff0c\u4e5f\u5efa\u8bae\u4f7f\u7528 &#8220;utf8&#8243;\u3002<\/li>\n<li> <strong>default-storage-engine\uff1a<\/strong>\u9ed8\u8ba4\u5b58\u50a8\u5f15\u64ce\uff0c\u63a8\u8350\u4f7f\u7528 &#8220;INNODB&#8221;\u3002<\/li>\n<\/ul>\n<p>\u53ef\u4ee5\u901a\u8fc7\u5728 my.ini \u6587\u4ef6\u7684\u76f8\u5e94\u90e8\u5206\uff08[mysql] \u6216 [mysqld]\uff09\u4e2d\u6dfb\u52a0\u4e0a\u8ff0\u53c2\u6570\u6765\u914d\u7f6e\u8fd9\u4e9b\u9009\u9879\u3002\u8bf7\u6ce8\u610f\uff0c\u60a8\u9700\u8981\u6839\u636e\u81ea\u5df1\u7684\u5b89\u88c5\u73af\u5883\u8c03\u6574\u503c\u3002<\/p>\n<p>\u4ee5\u4e0a\u5c31\u662fMySQL 5.7 \u5b89\u88c5\u5fc5\u5907\u7684 my.ini \u914d\u7f6e\uff1a\u54ea\u4e9b\u53c2\u6570\u662f\u5fc5\u9700\u7684\uff1f\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>MySQL 5.7 \u5b89\u88c5\u4e2d\u5fc5\u5907\u7684 my.ini \u914d\u7f6e \u5728 MySQL 5.7 \u7684\u5b89\u88c5\u8fc7\u7a0b\u4e2d\uff0c\u60a8\u53ef\u80fd\u9700\u8981\u914d\u7f6e my.ini \u6587\u4ef6\u4ee5\u6ee1\u8db3\u7279\u5b9a\u7684\u9700\u6c42\u3002\u5c3d\u7ba1 MySQL \u53ef\u4ee5\u4f7f\u7528\u9ed8\u8ba4\u914d\u7f6e\u9879\u542f\u52a8\uff0c\u4f46\u4ee5\u4e0b\u53c2\u6570\u5bf9\u4e8e\u5927\u90e8\u5206\u5b89\u88c5\u90fd\u662f\u5fc5\u9700\u7684\u6216\u63a8\u8350\u7684\uff1a basedir\uff1a\u6307\u5b9a MySQL \u7684\u5b89\u88c5\u4f4d\u7f6e\uff0c\u901a\u5e38\u4e3a \/usr\/local\/\u3002 datadir\uff1a\u786e\u5b9a\u6570\u636e\u5b58\u50a8\u7684\u4f4d\u7f6e\uff0c\u5efa\u8bae\u521b\u5efa\u4e00\u4e2a\u4e13\u95e8\u7684\u76ee\u5f55\uff0c\u5982 \/data\/mysql\u3002 \u5176\u4ed6\u5e38\u7528\u914d\u7f6e\u53c2\u6570\u5305\u62ec\uff1a default-character-set\uff1a\u5728\u5ba2\u6237\u7aef\u73af\u5883\u4e2d\u4f7f\u7528\u7684\u9ed8\u8ba4\u5b57\u7b26\u96c6\uff0c\u5efa\u8bae\u4f7f\u7528 &#8220;utf8&#8243;\u3002 character-set-server\uff1aMySQL \u670d\u52a1\u5668\u4f7f\u7528\u7684\u9ed8\u8ba4\u5b57\u7b26\u96c6\uff0c\u4e5f\u5efa\u8bae\u4f7f\u7528 &#8220;utf8&#8243;\u3002 default-storage-engine\uff1a\u9ed8\u8ba4\u5b58\u50a8\u5f15\u64ce\uff0c\u63a8\u8350\u4f7f\u7528 &#8220;INNODB&#8221;\u3002 \u53ef\u4ee5\u901a\u8fc7\u5728 my.ini \u6587\u4ef6\u7684\u76f8\u5e94\u90e8\u5206\uff08[mysql] \u6216 [mysqld]\uff09\u4e2d\u6dfb\u52a0\u4e0a\u8ff0\u53c2\u6570\u6765\u914d\u7f6e\u8fd9\u4e9b\u9009\u9879\u3002\u8bf7\u6ce8\u610f\uff0c\u60a8\u9700\u8981\u6839\u636e\u81ea\u5df1\u7684\u5b89\u88c5\u73af\u5883\u8c03\u6574\u503c\u3002 \u4ee5\u4e0a\u5c31\u662fMySQL 5.7 \u5b89\u88c5\u5fc5\u5907\u7684 my.ini \u914d\u7f6e\uff1a\u54ea\u4e9b\u53c2\u6570\u662f\u5fc5\u9700\u7684\uff1f\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16],"tags":[],"class_list":["post-25597","post","type-post","status-publish","format-standard","hentry","category-16"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/25597","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/comments?post=25597"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/25597\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=25597"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=25597"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=25597"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}