SSL: 1
Warning: Cannot modify header information - headers already sent by (output started at /www/blog/wp-includes/load.php:1646) in /www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1893
Warning: Cannot modify header information - headers already sent by (output started at /www/blog/wp-includes/load.php:1646) in /www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1893
Warning: Cannot modify header information - headers already sent by (output started at /www/blog/wp-includes/load.php:1646) in /www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1893
Warning: Cannot modify header information - headers already sent by (output started at /www/blog/wp-includes/load.php:1646) in /www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1893
Warning: Cannot modify header information - headers already sent by (output started at /www/blog/wp-includes/load.php:1646) in /www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1893
Warning: Cannot modify header information - headers already sent by (output started at /www/blog/wp-includes/load.php:1646) in /www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1893
Warning: Cannot modify header information - headers already sent by (output started at /www/blog/wp-includes/load.php:1646) in /www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1893
Warning: Cannot modify header information - headers already sent by (output started at /www/blog/wp-includes/load.php:1646) in /www/blog/wp-includes/rest-api/class-wp-rest-server.php on line 1893
{"id":619,"date":"2017-03-20T12:30:16","date_gmt":"2017-03-20T04:30:16","guid":{"rendered":"https:\/\/blog.weskiller.com\/?p=619"},"modified":"2017-03-22T15:59:23","modified_gmt":"2017-03-22T07:59:23","slug":"%e5%88%9d%e8%af%86docker","status":"publish","type":"post","link":"https:\/\/blog.gamein.vip\/docker.html","title":{"rendered":"\u521d\u8bc6docker"},"content":{"rendered":"
\u5f88\u4e45\u4ee5\u524d\u5c31\u542c\u95fbdocker\u5f88\u706b\uff0c\u66ff\u4ee3\u865a\u62df\u5316\u7684\u4e00\u79cd\u5bb9\u5668\u6280\u672f\uff0c\u4e00\u76f4\u4e5f\u6709\u5fc3\u5b66\u4e60\uff0c\u4f46\u662f\u4e00\u76f4\u90fd…\u3002(\u597d\u5427\uff0c\u592a\u61d2\u4e86) \u5f88\u4e45\u4ee5\u524d\u5c31\u542c\u95fbdocker\u5f88\u706b\uff0c\u66ff\u4ee3\u865a\u62df\u5316\u7684\u4e00\u79cd\u5bb9\u5668\u6280\u672f\uff0c\u4e00\u76f4\u4e5f\u6709\u5fc3\u5b66\u4e60\uff0c\u4f46\u662f\u4e00\u76f4\u90fd…\u3002(\u597d\u5427\uff0c\u592a […]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[36,4],"tags":[37],"class_list":["post-619","post","type-post","status-publish","format-standard","hentry","category-docker","category-linux","tag-container"],"_links":{"self":[{"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/posts\/619","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/comments?post=619"}],"version-history":[{"count":5,"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/posts\/619\/revisions"}],"predecessor-version":[{"id":627,"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/posts\/619\/revisions\/627"}],"wp:attachment":[{"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/media?parent=619"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/categories?post=619"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.gamein.vip\/wp-json\/wp\/v2\/tags?post=619"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}
\n\u516c\u53f8\u6709\u8fd120+\u7684mysql\u6570\u636e\u5e93\uff0c\u4e00\u76f4\u4f7f\u7528Kernel-based Virtual Machine\u7684\u865a\u62df\u5316\u6280\u672f\u8fdb\u884c\u8d44\u6e90\u9694\u79bb\uff0c\u968f\u7740\u516c\u53f8\u7684\u53d1\u5c55\uff0c\u5404\u79cd\u7c7b\u578b\u7684\u6570\u636e\u5e93\u8d8a\u6765\u8d8a\u591a\u3002
\nkvm\u7684\u65b9\u6848\u5bf9\u4e8ecpu\uff0cmemory\uff0cdisk io\u65b9\u9762\u8d1f\u8f7d\u90fd\u662f\u975e\u5e38\u660e\u663e\u7684\u3002
\n\u5728\u5b9e\u9645\u6d4b\u8bd5\u4e2d\uff0c\u5728\u4e00\u53f040\u683896G\u5185\u5b58\u548c\u56fa\u6001raid10\u7684\u670d\u52a1\u5668\u4e0a\uff0c\u521b\u5efa5\u4e2akvm\u5b9e\u4f8b\uff0c\u6bcf\u4e2a\u5b9e\u4f8b\u8bbe\u5b9a8\u683816G\u6570\u636e\u76d8\u653e\u5728\u56fa\u6001raid\u4e0a\uff08\u5b9e\u4f8b\u4e2d\u8fd0\u884cmysql\uff09\u3002
\n\u5728\u6bcf\u65e5\u5cf0\u503c\u4e0b\uff0c\u7ecf\u5e38\u4f1a\u51fa\u73b0\u78c1\u76d8io\u800c\u5bfc\u81f4\u7684cpu wait\u8017\u65f6,sql\u5e73\u5747\u6267\u884c\u65f6\u95f4\u8017\u65f6\u5230\u4e86\u79d2\u7ea7\u3002kvm\u4e3b\u673a\u4e0a\uff0c\u78c1\u76d8io\u8d1f\u8f7d\u5728400%\u5de6\u53f3\u3002\u66f4\u4e25\u91cd\u7684\u662f\uff0c\u5728\u5b9e\u4f8b\u6ca1\u6709\u4efb\u4f55\u8d1f\u8f7d\uff08kvm\u5b9e\u4f8b\u6ca1\u6709\u8fd0\u884cmysql\uff09\u60c5\u51b5\u4e0b\uff0ckvm\u4e3b\u673a\u7684\u78c1\u76d8io\u8fd8\u662f\u660e\u663e\u964d\u4f4e\u4e86\u8fd130%\u5de6\u53f3\u3002
\n\u800c\u5728kvm\u5b9e\u4f8b\u4e2d\u3002\u5206\u914d\u768416G\u5185\u5b58\u5b9e\u9645\u5e94\u7528\u5360\u7528\u7684\u4ec5\u670914G\u5de6\u53f3\uff0c\u5269\u4e0b\u7684\u6240\u6709\u90fd\u88ab\u7cfb\u7edf\u7528\u4e8ebuffer,\u800cswap\u7a7a\u95f4\u5360\u7528\u4e5f\u5f88\u4e25\u91cd\uff0c\u80fd\u8fbe\u5230\u771f\u5b9e\u5185\u5b58\u76842\u500d\u3002
\n\u4f7f\u7528\u8d44\u6e90\u9694\u79bb\uff0c\u4f46\u662f\u4f5c\u4e3a\u4ee3\u4ef7\uff0c\u8d44\u6e90\u9694\u79bb\u4e5f\u8981\u6d88\u8017\u8d44\u6e90\u3002\u5f53\u7136\u5e0c\u671b\u9694\u79bb\u6d88\u8017\u7684\u8d44\u6e90\u8d8a\u5c0f\u8d8a\u597d\u3002
\n\u53bb\u4e86\u89e3\u4e86docker\u6280\u672f\u7684\u5b9e\u73b0\uff0c\u9605\u8bfb\u4e86\u4e00\u672c\u5165\u95e8\u4e66\u7c4d\u300aDocker \u5b9e\u8df5\u300b<\/a>\uff0c\u5728\u7ebf\u4e0a\u4f7f\u7528docker\u8fd0\u884cmysql\u5b9e\u4f8b\u8dd1\u4e86\u4e00\u6bb5\u65f6\u95f4\u3002
\n\u786e\u5b9e\u76f8\u5bf9\u4e8ekvm\u8d44\u6e90\u9694\u79bb\u7684\u6d88\u8017\u51cf\u5c11\uff0c\u7ba1\u7406\u4e5f\u76f8\u5bf9\u4fbf\u5229\u3002\u6700\u91cd\u8981\u662f\u89e3\u51b3\u4e86\u78c1\u76d8io\u6027\u80fd\u4e0a\u7684\u95ee\u9898\u3002\u5728\u6700\u8fd1\u4e00\u6bb5\u65f6\u95f4\u5185\u7684\u6d4b\u8bd5\uff0c\u5728\u6bcf\u65e5\u5cf0\u503c\u4e0b\uff0cdocker\u4e3b\u673a\u78c1\u76d8io\u8d1f\u8f7d\u964d\u4f4e\u4e3a60%~80%\uff0cmysql\u5b9e\u4f8b\u5185\u5b58\u4e3a\u771f\u5b9e\u7684\u9650\u5b9a\u503c\u3002\u800c\u4e14\u6240\u6709docker\u5b9e\u4f8b\u5171\u4eabcache\uff0c\u800c\u4e0d\u662fkvm\u7684\u6bcf\u4e2a\u5355\u72ec\u5b9e\u4f8b\u5171\u4eabcache\uff0c\u731c\u6d4b\u4e5f\u662fio\u8d1f\u8f7d\u4e0b\u964d\u5982\u6b64\u5927\u7684\u539f\u56e0\u3002
\n\u4f46\u662f\u4e5f\u968f\u4e4b\u800c\u6765\u7684\u53d1\u73b0\u4e00\u4e9b\u95ee\u9898\u3002
\nNo1. \u5728\u4f7f\u7528\u4e2d\u53d1\u73b0\u4e00\u4e9bbug\uff0crestart\u7684\u65f6\u5019\uff0c\u5982\u679c\u670d\u52a1\u5668\u8d1f\u8d23\u8f83\u5927\uff0c\u5b9e\u4f8b\u5728\u91cd\u542f\u5b8c\u6210\u540e\uff0c\u4f1a\u51fa\u73b0\u5b9e\u4f8b\u5047\u6b7b\u7684\u60c5\u51b5\uff0c\u800cps\u663e\u793a\u5728\u6b63\u5e38\u8fd0\u884c\u3002
\nNo2. docker\u7684\u7f51\u7edc\u914d\u7f6e\u4e0d\u591f\u5f3a\u5927\u3002\u65e0\u6cd5\u5b9e\u73b0\u67d0\u4e9b\u9700\u6c42\uff08\u6bd4\u5982docker\u4e3b\u673a\u548c\u5b9e\u4f8b\u5728\u540c\u4e00\u7f51\u6bb5\uff09
\nNo3. docker\u7684\u955c\u50cf\u521b\u5efa\u4e0d\u591f\u5f3a\u5927\u3002dockerfile\u53ea\u80fd\u4ece\u53e6\u5916\u4e00\u4e2a\u955c\u50cf\u5f00\u59cb\uff0c\u800c\u4e00\u4e2a\u7b80\u5355\u7684nginx\u5bb9\u5668\u5b8c\u6210\u521b\u5efa\u540e\uff0c\u53ef\u80fd\u4f1a\u4e0d\u7b26\u5408\u4f60\u65e5\u5e38\u719f\u6089\u7684\u914d\u7f6e\u8def\u5f84\u3002\uff08\u4e5f\u53ef\u4ee5\u7528go\u8bed\u8a00\u7f16\u8bd1\uff09
\nNo4. \u8fd9\u662f\u5728\u56fd\u5185\u624d\u6709\u7684\u95ee\u9898\u3002\u7531\u4e8e\u88ab\u5899\u7684\u539f\u56e0\uff0cdocker\u4ed3\u5e93\u57fa\u672c\u4e0a\u8bbf\u95ee\u4e0d\u4e86\u3002\uff08\u5728\u5b66\u4e60\u4e2d\u4f7f\u7528\u7684alpine\u955c\u50cf\u90fd\u662f\u6211\u4ece\u56fd\u5916vps\u4e0b\u7684\uff09
\nNo5. docker\u7684\u8054\u5408\u6587\u4ef6\u7cfb\u7edf\uff0c\u8ba9selinux\u5f88\u5c34\u5c2c\u3002
\nNo6. docker\u7684\u5bb9\u5668\u73af\u5883\u4e5f\u662f\u4e00\u4e2a\u5927\u95ee\u9898\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"