{"id":2097,"date":"2020-07-29T23:49:59","date_gmt":"2020-07-29T15:49:59","guid":{"rendered":"http:\/\/39.97.231.10\/?p=2097"},"modified":"2020-07-29T23:49:59","modified_gmt":"2020-07-29T15:49:59","slug":"mysql-8-0-%e5%85%8b%e9%9a%86clone%e6%8f%92%e4%bb%b6","status":"publish","type":"post","link":"http:\/\/www.weijing.co\/?p=2097","title":{"rendered":"MySQL 8.0 \u514b\u9686(clone)\u63d2\u4ef6"},"content":{"rendered":"<div class=\\\"blog_title\\\">\n<h2><span style=\\\"font-size: 1.23077rem;\\\">\u4e00\u3001\u514b\u9686(clone)\u63d2\u4ef6\u7b80\u4ecb<\/span><\/h2>\n<\/div>\n<div class=\\\"blog_content\\\">\n<div class=\\\"blog_detail\\\">\nMySQL 8.0 \u65b0\u589e\u4e86\u4e00\u4e2aclone\u63d2\u4ef6\uff0c\u80fd\u591f\u5b9e\u73b0\u672c\u5730\u6216\u8005\u8fdc\u7a0bMySQL\u5b9e\u4f8b\u5feb\u901f\u514b\u9686\u3002\u514b\u9686\u7684\u6570\u636e\u662fInnoDB\u5f15\u64ce\u7684\u5feb\u7167\u6570\u636e\uff0c\u5305\u62ec\u6570\u636e\u5e93(schema)\uff0c\u8868(tables)\uff0c\u8868\u7a7a\u95f4(tablespaces)\uff0c\u6570\u636e\u5b57\u5178\u5143\u6570\u636e(data dictionary metadata)\u3002\u514b\u9686\u7684\u6570\u636e\u662f\u4e00\u4e2a\u529f\u80fd\u9f50\u5168\u7684\u6570\u636e\u76ee\u5f55\uff0c\u4f7f\u7528\u8be5\u76ee\u5f55\u80fd\u591f\u5feb\u901f\u6dfb\u52a0\u4ece\u8282\u70b9\u6216\u8005\u7ec4\u590d\u5236\u8282\u70b9\u3002<br \/>\n\u4ece\u8fdc\u7a0bMySQL\u5b9e\u4f8b\u514b\u9686\u6570\u636e\u65f6\uff0c\u8fdc\u7a0b\u7684MySQL\u5b9e\u4f8b\u79f0\u4e4b\u4e3adonor\uff0c\u5b83\u662f\u6570\u636e\u63d0\u4f9b\u8005\uff0c\u662f\u514b\u9686\u7684\u6570\u636e\u6e90\u3002\u672c\u5730\u514b\u9686\u6570\u636e\u7684\u63a5\u6536\u8005\uff0c\u79f0\u4e4b\u4e3arecipient\u3002\u514b\u9686\u7684\u6570\u636e\u901a\u8fc7\u7f51\u7edc\uff0c\u4ecedonor\u4f20\u8f93\u7ed9recipient\u3002recipient\u672c\u5730\u7684\u6570\u636e\u9ed8\u8ba4\u4f1a\u88ab\u6e05\u9664\uff0c\u5f53\u7136\u4e5f\u53ef\u4ee5\u4e3arecipient\u6307\u5b9a\u4e00\u4e2a\u4e0d\u540c\u7684\u76ee\u5f55\u7528\u4e8e\u5b58\u50a8\u514b\u9686\u6570\u636e\u3002<br \/>\n\u514b\u9686\u63d2\u4ef6\u9664\u4e86\u514b\u9686\u6570\u636e\u4e4b\u5916\uff0c\u8fd8\u652f\u6301\u642d\u5efa\u590d\u5236\u3002\u514b\u9686\u64cd\u4f5c\u80fd\u591f\u83b7\u53d6\u590d\u5236\u7684\u5750\u6807\u70b9\uff0c\u5728\u514b\u9686\u5b8c\u6210\u4e4b\u540e\uff0c\u5229\u7528\u590d\u5236\u7684\u5750\u6807\u70b9\u4fe1\u606f\uff0c\u80fd\u591f\u5f88\u65b9\u4fbf\u7684\u642d\u5efa\u4e3b\u4ece\u590d\u5236\uff0c\u6216\u8005\u589e\u52a0\u7ec4\u590d\u5236\u8282\u70b9\u3002\u514b\u9686\u63d2\u4ef6\u652f\u6301\u8868\u6570\u636e\u52a0\u5bc6\u548c\u538b\u7f29\uff0c\u5728\u4f7f\u7528clone\u63d2\u4ef6\u4e4b\u524d\uff0c\u9700\u8981\u5b89\u88c5\u63d2\u4ef6\u3002<\/p>\n<h4>\u4e8c\u3001\u5b89\u88c5\u514b\u9686(clone)\u63d2\u4ef6<\/h4>\n<p>\u514b\u9686\u64cd\u4f5c\u4e4b\u524d\uff0c\u9700\u8981\u5728\u514b\u9686\u7684\u6e90\u5b9e\u4f8b(donor)\u548c\u76ee\u7684\u5b9e\u4f8b(recipient)\u4e0a\u5b89\u88c5clone\u63d2\u4ef6\u3002<br \/>\n\u5728my.cnf\u914d\u7f6e\u6587\u4ef6\u4e2d\u52a0\u8f7dclone\u63d2\u4ef6\uff1a<br \/>\n[mysqld]<br \/>\nplugin-load-add=mysql_clone.so<br \/>\n\u4e5f\u53ef\u4ee5\u5728MySQL\u5b9e\u4f8b\u8fd0\u884c\u65f6\u52a8\u6001\u5b89\u88c5\uff0c\u5982\u4e0b\uff1a<br \/>\nINSTALL PLUGIN clone SONAME \\&#8217;mysql_clone.so\\&#8217;;<br \/>\n\u67e5\u770bclone\u63d2\u4ef6\u72b6\u6001\uff1a<br \/>\nSELECT PLUGIN_NAME, PLUGIN_STATUS FROM INFORMATION_SCHEMA.PLUGINS WHERE PLUGIN_NAME = \\&#8217;clone\\&#8217;;<br \/>\n\u5982\u679cclone\u63d2\u4ef6\u52a0\u8f7d\u5931\u8d25\uff0c\u67e5\u770bmysql\u9519\u8bef\u65e5\u5fd7\uff0c\u6392\u67e5\u95ee\u9898\u3002<\/p>\n<h4>\u4e09\u3001\u514b\u9686\u672c\u5730\u6570\u636e<\/h4>\n<p>\u5728\u540c\u4e00\u53f0\u673a\u5668\u4e0a\uff0c\u4eceMySQL\u6570\u636e\u76ee\u5f55\u514b\u9686\u6570\u636e\u5230\u53e6\u5916\u4e00\u4e2a\u76ee\u5f55\u3002<br \/>\n\u8bed\u6cd5\uff1a<br \/>\nCLONE LOCAL DATA DIRECTORY [=] \\&#8217;clone_dir\\&#8217;;<br \/>\n\u6267\u884c\u4e0a\u8ff0\u547d\u4ee4\u9700\u8981\u6709BACKUP_ADMIN\u6743\u9650\uff0c\u9700\u8981\u5148\u6388\u6743\uff0c\u5982\u4e0b\uff1a<br \/>\nGRANT BACKUP_ADMIN ON *.* TO \\&#8217;clone_user\\&#8217;;<br \/>\n\u6267\u884c\u672c\u5730\u514b\u9686\uff1a<br \/>\nCLONE LOCAL DATA DIRECTORY = \\&#8217;\/path\/to\/clone_dir\\&#8217;;<br \/>\n\/path\/to\/clone_dir \u8def\u5f84\u7684\u5b50\u76ee\u5f55clone_dir\u5fc5\u987b\u4e0d\u80fd\u5b58\u5728\uff0cMySQL\u5e94\u5f53\u5bf9\u5176\u7236\u76ee\u5f55\u6709\u5199\u6743\u9650\uff0c\u6700\u597d\u5c06\u5176\u7236\u76ee\u5f55\u7684\u5c5e\u4e3b\u8bbe\u7f6e\u4e3amysql\u7528\u6237\u3002<br \/>\n\u5728\u514b\u9686\u5b8c\u6210\u4e4b\u540e\uff0c\u53ef\u4ee5\u5728\u514b\u9686\u7684\u76ee\u5f55\u4e0a\uff0c\u542f\u52a8\u4e00\u4e2a\u65b0\u7684MySQL\u5b9e\u4f8b\uff08\u5e94\u5f53\u8bbe\u7f6e\u4e0d\u540c\u7aef\u53e3\uff09\u3002<br \/>\nmysqld_safe &#8211;datadir=clone_dir<\/p>\n<h4>\u56db\u3001\u514b\u9686\u8fdc\u7a0b\u6570\u636e<\/h4>\n<p>\u514b\u9686\u63d2\u4ef6\u652f\u6301\u8fdc\u7a0bMySQL\u5b9e\u4f8b\u514b\u9686\uff0c\u901a\u8fc7\u7f51\u7edc\u5c06\u8fdc\u7a0b(donor)\u6570\u636e\u4f20\u8f93\u5230\u672c\u5730(recipient)\u3002<\/p>\n<h5>4.1 \u8fdc\u7a0b\u514b\u9686\u8bed\u6cd5<\/h5>\n<pre><code>CLONE INSTANCE FROM \\'user\\'@\\'host\\':port\nIDENTIFIED BY \\'password\\'\n[DATA DIRECTORY [=] \\'clone_dir\\']\n[REQUIRE [NO] SSL];\n<\/code><\/pre>\n<ul>\n<li>user\uff1a\u8fdc\u7a0bdonor\u5b9e\u4f8b\u4e0a\u7684\u7528\u6237<\/li>\n<li>password\uff1a\u5bc6\u7801<\/li>\n<li>host\uff1a\u8fdc\u7a0bdonor\u5b9e\u4f8b\u7684\u5730\u5740<\/li>\n<li>port\uff1a\u8fdc\u7a0bdonor\u5b9e\u4f8b\u7684\u7aef\u53e3<\/li>\n<li>DATA DIRECTORY [=] \\&#8217;clone_dir\\&#8217;\uff1a\u53ef\u9009\uff0c\u6307\u5b9arecipient\u5b58\u50a8\u514b\u9686\u6570\u636e\u7684\u76ee\u5f55\u3002\u5982\u679c\u4e0d\u60f3\u6e05\u9664recipient\u5df2\u6709\u7684\u6570\u636e\u76ee\u5f55\uff0c\u53ef\u4ee5\u6307\u5b9a\u4e00\u4e2a\u989d\u5916\u7684\u6570\u636e\u76ee\u5f55\u3002<\/li>\n<li>[REQUIRE [NO] SSL]\uff1a\u663e\u5f0f\u6307\u5b9a\u662f\u5426\u4f7f\u7528\u52a0\u5bc6\u8fde\u63a5\u4f20\u8f93\u6570\u636e<\/li>\n<\/ul>\n<h5>4.2 \u8fdc\u7a0b\u514b\u9686\u524d\u63d0\u6761\u4ef6<\/h5>\n<ul>\n<li>donor\u548crecipient\u5fc5\u987b\u7248\u672c\u76f8\u540c<\/li>\n<li>clone\u63d2\u4ef6\u8981\u6c428.0.17\u53ca\u4ee5\u4e0a\u7248\u672c<\/li>\n<li>\u5728donor\u548crecipient\u90fd\u9700\u8981\u5b89\u88c5clone\u63d2\u4ef6<\/li>\n<li>\u5728donor\u7aef\uff0c\u514b\u9686\u7528\u6237\u9700\u8981BACKUP_ADMIN\u6743\u9650\u6765\u8bbf\u95ee\u548c\u4f20\u8f93\u6570\u636e\uff0c\u5728donor\u7aef\u514b\u9686\u64cd\u4f5c\u671f\u95f4\uff0cDDL\u64cd\u4f5c\u5c06\u88ab\u963b\u585e<\/li>\n<li>\u5728recipient\u7aef\uff0c\u514b\u9686\u7528\u6237\u9700\u8981CLONE_ADMIN\u6743\u9650\u6765\u63a5\u6536\u5e76\u5b58\u50a8\u6570\u636e\uff0c\u514b\u9686\u64cd\u4f5c\u671f\u95f4\uff0cDDL\u64cd\u4f5c\u88ab\u963b\u585e\uff0c\u514b\u9686\u5b8c\u6210\u540e\uff0crecipient\u5b9e\u4f8b\u81ea\u52a8\u91cd\u542f<\/li>\n<li>donor\u548crecipient\u5fc5\u987b\u8fd0\u884c\u5728\u76f8\u540c\u7684\u64cd\u4f5c\u7cfb\u7edf\u5e73\u53f0\u4e0a<\/li>\n<li>donor\u548crecipient\u5fc5\u987b\u6709\u76f8\u540c\u7684\u5b57\u7b26\u96c6\u548c\u6821\u9a8c\u89c4\u5219<\/li>\n<li>donor\u548crecipient\u5fc5\u987b\u6709\u76f8\u540c\u7684\u00a0innodb_page_size\u00a0\u548c\u00a0innodb_data_file_path \u53c2\u6570\u914d\u7f6e<\/li>\n<li>recipient\u00a0\u4e0a\u5fc5\u987b\u6709\u8db3\u591f\u7684\u78c1\u76d8\u7a7a\u95f4\u5b58\u50a8\u514b\u9686\u6570\u636e<\/li>\n<li>\u514b\u9686\u64cd\u4f5c\u540c\u4e00\u65f6\u95f4\u53ea\u5141\u8bb8\u8fd0\u884c\u4e00\u6b21\uff0c\u4e0d\u652f\u6301\u5e76\u53d1\u8fd0\u884c\u3002<\/li>\n<\/ul>\n<h5>4.3 \u8fdc\u7a0b\u514b\u9686\u793a\u4f8b<\/h5>\n<ol>\n<li>\u5728donor\u8282\u70b9\u521b\u5efa\u514b\u9686\u7528\u6237\uff1a<\/li>\n<\/ol>\n<p>CREATE USER \\&#8217;donor_clone_user\\&#8217;@\\&#8217;%\\&#8217; IDENTIFIED BY \\&#8217;password\\&#8217;;<br \/>\nGRANT BACKUP_ADMIN on\u00a0<em>.<\/em>\u00a0to \\&#8217;donor_clone_user\\&#8217;@\\&#8217;%\\&#8217;;<\/p>\n<ol start=\\\"2\\\">\n<li>\u5728donor\u8282\u70b9\u5b89\u88c5\u514b\u9686\u63d2\u4ef6\uff1a<\/li>\n<\/ol>\n<p>INSTALL PLUGIN clone SONAME \\&#8217;mysql_clone.so\\&#8217;;<\/p>\n<ol start=\\\"3\\\">\n<li>\u5728recipient\u8282\u70b9\u521b\u5efa\u514b\u9686\u7528\u6237\uff1a<\/li>\n<\/ol>\n<p>CREATE USER \\&#8217;recipient_clone_user\\&#8217;@\\&#8217;%\\&#8217; IDENTIFIED BY \\&#8217;password\\&#8217;;<br \/>\nGRANT CLONE_ADMIN on\u00a0<em>.<\/em>\u00a0to \\&#8217;recipient_clone_user\\&#8217;@\\&#8217;%\\&#8217;;<\/p>\n<ol start=\\\"4\\\">\n<li>\u5728recipient\u8282\u70b9\u5b89\u88c5\u514b\u9686\u63d2\u4ef6\uff1a<\/li>\n<\/ol>\n<p>INSTALL PLUGIN clone SONAME \\&#8217;mysql_clone.so\\&#8217;;<\/p>\n<ol start=\\\"5\\\">\n<li>\u8bbe\u7f6eclone_valid_donor_list\u53c2\u6570\uff1a<\/li>\n<\/ol>\n<p>SET GLOBAL clone_valid_donor_list = \\&#8217;example.donor.host.com:3306\\&#8217;;<\/p>\n<ol start=\\\"6\\\">\n<li>\u6267\u884c\u514b\u9686\uff1a<\/li>\n<\/ol>\n<p>CLONE INSTANCE FROM \\&#8217;donor_clone_user\\&#8217;@\\&#8217;example.donor.host.com\\&#8217;:3306 IDENTIFIED BY \\&#8217;password\\&#8217;;<br \/>\n\u5728\u4e0a\u8ff0\u514b\u9686\u6267\u884c\u5b8c\u6210\u4e4b\u540e\uff0crecipient\u00a0\u8282\u70b9\u4f1a\u81ea\u52a8\u91cd\u65b0\u542f\u52a8\u3002<br \/>\n<strong>\u6ce8\u610f\uff1a<\/strong><\/p>\n<ul>\n<li>\u4e0d\u7ba1\u662f\u672c\u5730\u514b\u9686\uff0c\u8fd8\u662f\u8fdc\u7a0b\u514b\u9686\uff0c\u5bf9\u4e8e\u7528\u6237\u521b\u5efa\u5728\u6570\u636e\u76ee\u5f55\u4e4b\u5916\u7684\u8868\u6216\u8005\u8868\u7a7a\u95f4\uff0c\u5982\u679c\u8868\u7a7a\u95f4\u540d\u79f0\u76f8\u540c\uff0c\u514b\u9686\u65f6\uff0c\u6240\u6709\u8868\u7a7a\u95f4\u653e\u5728\u4e00\u4e2a\u76ee\u5f55\u4e2d\uff0c\u5c06\u5bfc\u81f4\u8868\u7a7a\u95f4\u547d\u540d\u51b2\u7a81\u3002<\/li>\n<li>\u5728\u514b\u9686\u64cd\u4f5c\u671f\u95f4\uff0c\u53d1\u751f\u7f51\u7edc\u4e2d\u65ad\u95ee\u9898\uff0c\u5982\u679c\u7f51\u7edc\u95ee\u9898\u80fd\u57285\u5206\u949f\u4e4b\u5185\u89e3\u51b3\uff0c\u90a3\u4e48\u514b\u9686\u64cd\u4f5c\u80fd\u591f\u6062\u590d\uff0c\u5426\u5219\u514b\u9686\u64cd\u4f5c\u8fd4\u56de\u9519\u8bef\u3002<\/li>\n<\/ul>\n<h4>\u4e94\u3001\u901a\u8fc7\u514b\u9686\u642d\u5efa\u4e3b\u4ece\u590d\u5236<\/h4>\n<p>\u5728\u514b\u9686\u64cd\u4f5c\u6267\u884c\u8fc7\u7a0b\u4e2d\uff0cdonor\u8282\u70b9\u7684binlog\u6587\u4ef6\u3001\u4f4d\u7f6e\u4ee5\u53ca gtid_executed \u90fd\u4f1a\u4f20\u8f93\u5230recipient\u8282\u70b9\u3002\u5728\u514b\u9686\u5b8c\u6210\u540e\uff0c\u62e5\u6709\u8fd9\u4e9b\u4fe1\u606f\u5c31\u80fd\u591f\u5728recipient\u4e0edonor\u8282\u70b9\u4e4b\u95f4\u5efa\u7acb\u590d\u5236\u5173\u7cfb\u3002<br \/>\n\u5728recipient\u8282\u70b9\u4e0a\u67e5\u8be2binlog\u4f4d\u7f6e\u4fe1\u606f\uff1a<br \/>\nSELECT BINLOG_FILE, BINLOG_POSITION FROM performance_schema.clone_status;<br \/>\n\u5728recipient\u8282\u70b9\u4e0a\u67e5\u8be2gtid_executed\uff1a<br \/>\nSELECT @@GLOBAL.GTID_EXECUTED;<br \/>\n\u521b\u5efa\u590d\u5236\u5173\u7cfb\uff1a<br \/>\nCHANGE MASTER TO MASTER_HOST = \\&#8217;master_host_name\\&#8217;, MASTER_PORT = master_port_num, &#8230; MASTER_AUTO_POSITION = 1;<br \/>\nSTART SLAVE;<br \/>\n\u5982\u679c\u514b\u9686\u7684donor\u672c\u8eab\u5c31\u662f\u4e00\u4e2a\u4ece\u8282\u70b9\uff0c\u90a3\u4e48recipient\u5728\u514b\u9686\u5b8c\u6210\u91cd\u542f\u4e4b\u540e\uff0c\u590d\u5236\u81ea\u52a8\u5efa\u7acb\u3002\u5982\u679c\u514b\u9686\u7684donor\u662f\u4e3b\u8282\u70b9\uff0c\u90a3\u4e48\u9700\u8981\u6267\u884cchange master to\uff0c\u6307\u5b9a\u4e3b\u5e93\u3002<\/p>\n<h4>\u516d\u3001\u514b\u9686\u529f\u80fd\u7684\u76d1\u63a7<\/h4>\n<p>\u7531\u4e8e\u6570\u636e\u91cf\u7684\u5927\u5c0f\u4ee5\u53ca\u7f51\u7edc\u5e26\u5bbd\u7b49\u786c\u4ef6\u56e0\u7d20\u7684\u5f71\u54cd\uff0c\u514b\u9686\u64cd\u4f5c\u53ef\u80fd\u4f1a\u6267\u884c\u5f88\u957f\u65f6\u95f4\uff0c\u901a\u8fc7\u67e5\u8be2recipient\u8282\u70b9\u4e0aperformance_schema\u4e2d\u7684\u76f8\u5173\u8868\uff0c\u5c31\u80fd\u5b9e\u73b0\u76d1\u63a7\u514b\u9686\u64cd\u4f5c\u7684\u8fc7\u7a0b\u548c\u72b6\u6001\u3002<\/p>\n<ul>\n<li>clone_status\uff0c\u63d0\u4f9b\u4e86\u514b\u9686\u8fc7\u7a0b\u4e2d\uff0c\u5f53\u524d\u6216\u8005\u6700\u8fd1\u4e00\u6b21\u6267\u884c\u7684\u514b\u9686\u64cd\u4f5c\u7684\u72b6\u6001\uff0c\u901a\u5e38\u6709\u56db\u79cd\u72b6\u6001\uff0cNot Started,\u00a0In Progress,\u00a0Completed,\u00a0Failed\u3002<\/li>\n<li>clone_progress\uff0c\u63d0\u4f9b\u4e86\u514b\u9686\u8fc7\u7a0b\u4e2d\uff0c\u5f53\u524d\u6216\u8005\u6700\u8fd1\u4e00\u6b21\u6267\u884c\u7684\u514b\u9686\u64cd\u4f5c\u7684\u9636\u6bb5\uff0c\u4e3b\u8981\u5305\u62ecDROP DATA,\u00a0FILE COPY,\u00a0PAGE_COPY,\u00a0REDO_COPY,\u00a0FILE_SYNC,\u00a0RESTART, RECOVERY\u3002<\/li>\n<\/ul>\n<p>clone_status \u548c clone_progress \u53ea\u80fd\u5728recipient\u8282\u70b9\u4e0a\u76d1\u63a7\u514b\u9686\u72b6\u6001\u3002\u5982\u679c\u60f3\u76d1\u63a7donor\u4e0a\u7684\u72b6\u6001\uff0c\u9700\u8981\u4f7f\u7528 Performance Schema Stage Events\u3002<br \/>\n\u542f\u7528 stage\/innodb\/clone%\uff1a<br \/>\nUPDATE performance_schema.setup_instruments SET ENABLED = \\&#8217;YES\\&#8217; WHERE NAME LIKE \\&#8217;stage\/innodb\/clone%\\&#8217;;<br \/>\n\u542f\u7528 stage event consumer tables\uff1a<br \/>\nUPDATE performance_schema.setup_consumers SET ENABLED = \\&#8217;YES\\&#8217; WHERE NAME LIKE \\&#8217;%stages%\\&#8217;;<br \/>\n\u542f\u7528\u4e4b\u540e\uff0c\u4e0b\u9762\u4e09\u4e2a\u8868\u53ef\u7528\uff1a<\/p>\n<ul>\n<li>events_stages_current<\/li>\n<li>events_stages_history<\/li>\n<li>events_stages_history_long<\/li>\n<\/ul>\n<p>\u67e5\u8be2\u514b\u9686\u64cd\u4f5c\u8fdb\u5ea6\uff1a<br \/>\nSELECT EVENT_NAME, WORK_COMPLETED, WORK_ESTIMATED FROM performance_schema.events_stages_current WHERE EVENT_NAME LIKE \\&#8217;stage\/innodb\/clone%\\&#8217;;<br \/>\nSELECT EVENT_NAME, WORK_COMPLETED, WORK_ESTIMATED FROM events_stages_history WHERE EVENT_NAME LIKE \\&#8217;stage\/innodb\/clone%\\&#8217;;<br \/>\nSELECT * FROM performance_schema.setup_instruments WHERE NAME LIKE WHERE NAME LIKE \\&#8217;%clone%\\&#8217;;<\/p>\n<h4>\u4e03\u3001\u514b\u9686\u529f\u80fd\u76f8\u5173\u53c2\u6570<\/h4>\n<ul>\n<li>clone_autotune_concurrency<\/li>\n<li>clone_buffer_size<\/li>\n<li>clone_ddl_timeout<\/li>\n<li>clone_enable_compression<\/li>\n<li>clone_max_concurrency<\/li>\n<li>clone_max_data_bandwidth<\/li>\n<li>clone_max_network_bandwidth<\/li>\n<li>clone_ssl_ca<\/li>\n<li>clone_ssl_cert<\/li>\n<li>clone_ssl_key<\/li>\n<li>clone_valid_donor_list<\/li>\n<\/ul>\n<h4>\u516b\u3001\u514b\u9686\u529f\u80fd\u7684\u9650\u5236<\/h4>\n<ol>\n<li>\u5728\u514b\u9686\u64cd\u4f5c\u671f\u95f4\uff0cDDL\u5305\u542btruncate table\u4e0d\u5141\u8bb8\u6267\u884c\uff0cDML\u53ef\u4ee5\u6267\u884c\u3002<\/li>\n<li>MySQL\u7248\u672c\u4e0d\u540c\uff0c\u4e0d\u80fd\u505a\u514b\u9686\u64cd\u4f5c\uff0cdonor \u548c recipient \u8282\u70b9\u7684\u7248\u672c\u5fc5\u987b\u76f8\u540c\uff0c\u4e14\u5fc5\u987b\u662f8.0.17\u53ca\u4ee5\u4e0a\u7248\u672c\u3002<\/li>\n<li>\u514b\u9686\u64cd\u4f5c\u4e0d\u80fd\u5e76\u53d1\u6267\u884c\uff0c\u540c\u4e00\u65f6\u95f4\u53ea\u80fd\u6267\u884c\u4e00\u6b21\u514b\u9686\u64cd\u4f5c\u3002<\/li>\n<li>\u8fdc\u7a0b\u514b\u9686\u4e0d\u652f\u6301mysqlx_port\u6307\u5b9a\u7684X\u534f\u8bae\u7684\u7aef\u53e3\u3002<\/li>\n<li>\u514b\u9686\u64cd\u4f5c\u4e0d\u652f\u6301\u5bf9MySQL\u914d\u7f6e\u4fe1\u606f\u8fdb\u884c\u514b\u9686\uff0c\u5305\u62ecmy.cnf\u4e2d\u7684\u914d\u7f6e\u4fe1\u606f\u3002<\/li>\n<li>\u514b\u9686\u64cd\u4f5c\u4e0d\u652f\u6301\u5bf9binlog\u65e5\u5fd7\u8fdb\u884c\u514b\u9686\u3002<\/li>\n<li>\u514b\u9686\u64cd\u4f5c\u9488\u5bf9InnoDB\u5f15\u64ce\u7684\u8868\u8fdb\u884c\u514b\u9686\uff0c\u975eInnoDB\u8868\uff0c\u6bd4\u5982MyISAM\uff0cCSV\u7b49\uff0c\u53ea\u514b\u9686\u51fa\u7a7a\u8868\u3002<\/li>\n<li>\u4e0d\u652f\u6301\u901a\u8fc7MySQL Router\u8fde\u63a5\u5230donor\u8282\u70b9\u6267\u884c\u514b\u9686\u64cd\u4f5c\u3002<\/li>\n<li>\u672c\u5730\u514b\u9686\u4e0d\u652f\u6301\u521b\u5efa\u5728\u7edd\u5bf9\u8def\u5f84\u7684\u901a\u7528\u8868\u7a7a\u95f4\uff0c\u53ef\u80fd\u5bfc\u81f4\u8868\u7a7a\u95f4\u547d\u540d\u51b2\u7a81\u3002<\/li>\n<\/ol>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u4e00\u3001\u514b\u9686(clone)\u63d2\u4ef6\u7b80\u4ecb MySQL 8.0 \u65b0\u589e\u4e86\u4e00\u4e2aclone\u63d2\u4ef6\uff0c\u80fd\u591f\u5b9e\u73b0\u672c\u5730\u6216\u8005\u8fdc\u7a0bMySQL\u5b9e &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"\" href=\"http:\/\/www.weijing.co\/?p=2097\"> <span class=\"screen-reader-text\">MySQL 8.0 \u514b\u9686(clone)\u63d2\u4ef6<\/span> \u67e5\u770b\u5168\u6587 &raquo;<\/a><\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"default","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"default","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":""},"categories":[90,88],"tags":[],"uagb_featured_image_src":{"full":false,"thumbnail":false,"medium":false,"medium_large":false,"large":false,"1536x1536":false,"2048x2048":false,"mailpoet_newsletter_max":false,"woocommerce_thumbnail":false,"woocommerce_single":false,"woocommerce_gallery_thumbnail":false,"shop_catalog":false,"shop_single":false,"shop_thumbnail":false},"uagb_author_info":{"display_name":"weijing","author_link":"http:\/\/www.weijing.co\/?author=4"},"uagb_comment_info":0,"uagb_excerpt":"\u4e00\u3001\u514b\u9686(clone)\u63d2\u4ef6\u7b80\u4ecb MySQL 8.0 \u65b0\u589e\u4e86\u4e00\u4e2aclone\u63d2\u4ef6\uff0c\u80fd\u591f\u5b9e\u73b0\u672c\u5730\u6216\u8005\u8fdc\u7a0bMySQL\u5b9e&hellip;","_links":{"self":[{"href":"http:\/\/www.weijing.co\/index.php?rest_route=\/wp\/v2\/posts\/2097"}],"collection":[{"href":"http:\/\/www.weijing.co\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.weijing.co\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.weijing.co\/index.php?rest_route=\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"http:\/\/www.weijing.co\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2097"}],"version-history":[{"count":0,"href":"http:\/\/www.weijing.co\/index.php?rest_route=\/wp\/v2\/posts\/2097\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.weijing.co\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2097"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.weijing.co\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2097"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.weijing.co\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2097"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}