{"id":2368,"date":"2010-09-27T11:38:34","date_gmt":"2010-09-27T03:38:34","guid":{"rendered":"http:\/\/www.orczhou.com\/?p=2368"},"modified":"2010-09-27T18:58:14","modified_gmt":"2010-09-27T10:58:14","slug":"flachcache-first-view","status":"publish","type":"post","link":"https:\/\/www.orczhou.com\/index.php\/2010\/09\/flachcache-first-view\/","title":{"rendered":"Flachcache\u521d\u63a2"},"content":{"rendered":"<p>Flashcache\u662fFacebook\u6280\u672f\u56e2\u961f\u7684\u53c8\u4e00\u529b\u4f5c\uff0c\u6700\u521d\u662f\u4e3a\u52a0\u901fMySQL\u8bbe\u8ba1\u7684\u3002Flashcache\u662f\u5728Linux\u5c42\u9762\u7684\uff0c\u6240\u4ee5\u4efb\u4f55\u53d7\u78c1\u76d8IO\u56f0\u7ed5\u7684\u8f6f\u4ef6\u6216\u5e94\u7528\u90fd\u53ef\u4ee5\u65b9\u4fbf\u7684\u4f7f\u7528\u4e4b\u3002<\/p>\n<div class=\"myt1\">1. Why Flashcache<\/div>\n<p>\u968f\u7740\u65f6\u95f4\u7684\u6d41\u901d\uff0c\u7f51\u7ad9\u4e0a\u7684\u6570\u636e\u4e00\u76f4\u5728\u4e0d\u505c\u7684\u79ef\u7d2f\u3002\u5982\u679c\u4f60\u7ecf\u8425\u7684\u53ea\u662f\u4e00\u4e2a\u535a\u5ba2\u7684\u8bdd\uff0c\u8fd9\u4e0d\u4f1a\u662f\u95ee\u9898\uff0c\u56e0\u4e3a10G\u7684\u7a7a\u95f4\uff0c\u5927\u6982\u5c31\u591f\u4f60\u5199\u4e00\u8f88\u5b50\u4e86\uff08\u5982\u679c\u653e\u5728\u786c\u76d8\u4e0a\uff0c\u5176\u5b9e\u4e00\u8f88\u5b50\u5f88\u77ed\uff09\u3002\u5982\u679c\u4f60\u6070\u5de7\u5728\u4e00\u4e2a\u5feb\u901f\u589e\u957f\u7684\u516c\u53f8\uff0c\u6570\u636e\u4f1a\u8d8a\u6765\u8d8a\u591a\uff0c\u4eceMB\uff0c\u5230GB\uff0c\u518d\u5230TB\u3002<\/p>\n<p>\u5982\u679c\u5c06\u8fd9\u4e9b\u6570\u636e\u5168\u90e8\u653e\u5728\u5927\u5bb9\u91cf\u7684SATA\u3001SAS\u76d8\u4e0a\u65f6\uff0c\u4f1a\u53d1\u73b0\u6027\u80fd\uff08\u54cd\u5e94\u65f6\u95f4\uff09\u4e0d\u591f\uff1b\u5982\u679c\u5168\u653e\u5728SSD\u4e0a\u65f6\uff0c\u53c8\u4f1a\u53d1\u73b0\u6210\u672c\u5f88\u9ad8\u3002\u5373\u4f7f\u516c\u53f8\u80fd\u591f\u5927\u6c14\u5230\u90fd\u653e\u5230SSD\u4e0a\uff0c\u4f60\u4f1a\u53d1\u73b01TB\u7684\u6570\u636e\u91cc\u9762\u53ef\u80fd\u53ea\u6709200G\u662f\u7ecf\u5e38\u88ab\u8bbf\u95ee\u7684\uff0c300G\u53ef\u80fd\u5076\u5c14\u88ab\u8bbf\u95ee\u5230\uff0c\u6700\u540e\u5269\u4e0b\u7684500G\u53ef\u80fd\u5df2\u7ecf\u6210\u4e3a\u5386\u53f2\u6570\u636e\u4e86\uff0c\u51e0\u4e4e\u4e0d\u88ab\u8bbf\u95ee\u5230\uff0c\u5982\u679c\u5168\u90e8\u90fd\u653e\u5728SSD\u4e0a\u6709\u7565\u6709\u6d6a\u8d39\u3002\u4e8e\u662f\u5c31\u6709\u4e86<a href=\"http:\/\/www.facebook.com\/note.php?note_id=388112370932\">Flashcache<\/a>\u3002<\/p>\n<p>Flashcache\u4e00\u4e2a\u975e\u5e38\u4e0d\u9519\u7684\u8f6f\u4ef6\uff08\u51c6\u786e\u7684\u8bf4\u662f\u4e00\u4e2a<a href=\"http:\/\/tldp.org\/LDP\/lkmpg\/2.6\/html\/\">Linux\u7684\u6a21\u5757<\/a>\uff09\uff0c\u53ef\u4ee5\u52a8\u6001\u52a0\u8f7d\u3002Flashcache\u901a\u8fc7\u5728\u6587\u4ef6\u7cfb\u7edf\uff08VFS\uff09\u548c\u8bbe\u5907\u9a71\u52a8\u4e4b\u95f4\u65b0\u589e\u4e86\u4e00\u6b21\u7f13\u5b58\u5c42\uff0c\u6765\u5b9e\u73b0\u5bf9\u70ed\u95e8\u7684\u7f13\u5b58\u3002Flashcache\u662f\u53e6\u4e00\u79cd\u7f13\u5b58\uff0c\u4e00\u822c\u7528SSD\u4f5c\u4e3a\u4ecb\u8d28\u7684\u7f13\u5b58\uff08\u4e00\u822c\u7684\u7f13\u5b58\u7528\u7684\u662f\u5185\u5b58\uff09\uff0c\u901a\u8fc7\u5c06\u4f20\u7edf\u786c\u76d8\u4e0a\u7684\u70ed\u95e8\u6570\u636e\u7f13\u5b58\u5230SSD\u4e0a\uff0c\u7136\u540e\u5229\u7528SSD\u4f18\u79c0\u7684\u8bfb\u6027\u80fd\uff0c\u6765\u52a0\u901f\u7cfb\u7edf\u3002\u8fd9\u4e2a\u65b9\u6cd5\u8f83\u4e4b\u5185\u5b58\u7f13\u5b58\uff0c\u6ca1\u6709\u5185\u5b58\u5feb\uff0c\u4f46\u662f\u7a7a\u95f4\u53ef\u4ee5\u6bd4\u5185\u5b58\u5927\u5f88\u591a\u3002<\/p>\n<p>\u672c\u6587\u662f\u4e00\u4e2a\u5173\u4e8eFlashcache\u7684\u521d\u6b65\u4ecb\u7ecd\u3002<!--more--><\/p>\n<div class=\"myt1\">2. \u8c01\u9002\u5408\u7528Flashcache<\/div>\n<p>\u6570\u636e\u91cf\u5f88\u5927\uff08\u4f8b\u59824TB\uff09\uff0c\u70ed\u95e8\u6570\u636e\u4e5f\u5f88\u5927\uff08800GB\uff09\uff0c\u4e0d\u5fc5\u8981\u6216\u8005\u4e0d\u820d\u5f97\u5168\u90e8\u4e70\u5185\u5b58\u6765\u7f13\u5b58\u3002<\/p>\n<div class=\"myt1\">3. \u8c01<strong>\u4e0d<\/strong>\u9002\u5408\u7528Flashcache<\/div>\n<p>\u6570\u636e\u91cf\u4e0d\u5927\u7684\u8bdd\uff0c\u4e00\u822cFlashcache\u5c31\u6ca1\u4ec0\u4e48\u7528\u6b66\u4e4b\u5730\u4e86\uff0c\u5185\u5b58\u5c31\u53ef\u4ee5\u5e2e\u4f60\u89e3\u51b3\u95ee\u9898\u4e86\uff1b<\/p>\n<p>\u4e0d\u5dee\u94b1\uff0c\u4e70\u5185\u5b58\u5457\uff1b<\/p>\n<p>\u53e6\u5916Flashcache\u7684\u52a0\u5165\u4e5f\u4f7f\u5f97\u7cfb\u7edf\u7684\u590d\u6742\u5ea6\u589e\u52a0\u4e86\u4e00\u5c42\uff0c\u5982\u679c\u4f60\u575a\u6301<a href=\"http:\/\/en.wikipedia.org\/wiki\/KISS_principle\">KISS\u539f\u5219<\/a>\uff08Keep it simple, Stupid!\uff09\uff0c\u4e5f\u53ef\u4ee5\u5f03\u7528\u4e4b\u3002<\/p>\n<div class=\"myt1\">4. \u57fa\u672c\u539f\u7406\u56fe<\/div>\n<p><a href=\"http:\/\/www.flickr.com\/photos\/26825745@N06\/5023251788\/\" title=\"Flashcache_orczhou by orczhou, on Flickr\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/farm5.static.flickr.com\/4146\/5023251788_f67a46dc7d.jpg\" width=\"500\" height=\"296\" alt=\"Flashcache_orczhou\" \/><\/a><\/p>\n<p>\u4e0a\u56fe\u4e2d\uff0cFlashcache\u5c06\u666e\u901a\u7684SAS\u76d8\uff08\/dev\/sda\uff09\u548c\u4e00\u4e2a\u9ad8\u901f\u7684SSD(\/dev\/sdb)\u865a\u62df\u6210\u4e00\u4e2a\u5e26\u7f13\u5b58\u7684\u5757\u8bbe\u5907\uff08\/dev\/mapper\/cachedev\uff09\u3002\u540e\u7eed\u8fd8\u5c06\u4f1a\u6709\u66f4\u591a\u5173\u4e8eFlashcache\u76f8\u5173\u7684\u6587\u7ae0\u51fa\u73b0\uff0c\u656c\u8bf7\u671f\u5f85\u3002<\/p>\n<div class=\"myt1\">5. Flashcache\u662f\u5426\u53ea\u662f\u4e00\u4e2a\u8fc7\u6e21\u4ea7\u54c1<\/div>\n<p>\u5bf9\u4e8e\u5f53\u524d\uff0cPCI\u63a5\u53e3\u7684SSD\u4ef7\u683c\u8fd8\u5341\u5206\u6602\u8d35\uff0c\u800c\u968f\u7740\u65f6\u95f4\u7684\u63a8\u79fb\uff0c\u4ef7\u683c\u4f1a\u964d\uff1b\u53e6\u5916\uff0c\u6839\u636e<a href=\"http:\/\/zh.wikipedia.org\/zh-hk\/%E6%91%A9%E5%B0%94%E5%AE%9A%E5%BE%8B\">\u6469\u5c14\u5b9a\u5f8b<\/a>\uff0c\u672a\u6765\u4f1a\u6709\u66f4\u5feb\u7684\u8bbe\u5907\u51fa\u73b0\uff0c\u6240\u4ee5Flashcache\u662f\u4e00\u4e2a\u201c\u6301\u4e45\u7684\u201d\u4ea7\u54c1\uff0c\u8fd8\u53ea\u662f\u4e00\u4e2a\u8fc7\u6e21\u8f6f\u4ef6\uff0c\u8fd9\u5e76\u4e0d\u597d\u8bf4\u3002<\/p>\n<p>\u5173\u6ce8\u672a\u6765\u65b0\u6280\u672f\u7684\u53d1\u5c55\u5427:)<\/p>\n<p>\u53c2\u8003\uff1a<\/p>\n<p>1. <a href=\"http:\/\/github.com\/facebook\/flashcache\/\">Facebook \/ Flashcache<\/a><\/p>\n<p>2. <a href=\"http:\/\/www.facebook.com\/note.php?note_id=388112370932\">Releasing Flashcache of Facebook<\/a><\/p>\n<p>3. <a href=\"http:\/\/github.com\/facebook\/flashcache\/blob\/master\/doc\/flashcache-doc.txt\">flashcache-doc.txt<\/a><\/p>\n<p>PS\uff1a\u5199\u5b8c\u6574\u7bc7\u6587\u7ae0\uff0c\u6700\u5927\u7684\u6536\u83b7\u662f\uff1a\u53d1\u73b0\u4eba\u7684\u4e00\u751f\u5176\u5b9e\u5f88\u77ed\u3001\u5f88\u77ed\uff0c\u53ef\u80fd\u8fde1GB\u90fd\u4e0d\u5230\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Flashcache\u662fFacebook\u6280\u672f\u56e2\u961f\u7684\u53c8\u4e00\u529b\u4f5c\uff0c\u6700\u521d\u662f\u4e3a\u52a0\u901fMySQL\u8bbe\u8ba1\u7684\u3002Flashcache\u662f\u5728Linux\u5c42\u9762\u7684\uff0c\u6240\u4ee5\u4efb\u4f55\u53d7\u78c1\u76d8IO\u56f0\u7ed5\u7684\u8f6f\u4ef6\u6216\u5e94\u7528\u90fd\u53ef\u4ee5\u65b9\u4fbf\u7684\u4f7f\u7528\u4e4b\u3002 1. Why Flashcache \u968f\u7740\u65f6\u95f4\u7684\u6d41\u901d\uff0c\u7f51\u7ad9\u4e0a\u7684\u6570\u636e\u4e00\u76f4\u5728\u4e0d\u505c\u7684\u79ef\u7d2f\u3002\u5982\u679c\u4f60\u7ecf\u8425\u7684\u53ea\u662f\u4e00\u4e2a\u535a\u5ba2\u7684\u8bdd\uff0c\u8fd9\u4e0d\u4f1a\u662f\u95ee\u9898\uff0c\u56e0\u4e3a10G\u7684\u7a7a\u95f4\uff0c\u5927\u6982\u5c31\u591f\u4f60\u5199\u4e00\u8f88\u5b50\u4e86\uff08\u5982\u679c\u653e\u5728\u786c\u76d8\u4e0a\uff0c\u5176\u5b9e\u4e00\u8f88\u5b50\u5f88\u77ed\uff09\u3002\u5982\u679c\u4f60\u6070\u5de7\u5728\u4e00\u4e2a\u5feb\u901f\u589e\u957f\u7684\u516c\u53f8\uff0c\u6570\u636e\u4f1a\u8d8a\u6765\u8d8a\u591a\uff0c\u4eceMB\uff0c\u5230GB\uff0c\u518d\u5230TB\u3002 \u5982\u679c\u5c06\u8fd9\u4e9b\u6570\u636e\u5168\u90e8\u653e\u5728\u5927\u5bb9\u91cf\u7684SATA\u3001SAS\u76d8\u4e0a\u65f6\uff0c\u4f1a\u53d1\u73b0\u6027\u80fd\uff08\u54cd\u5e94\u65f6\u95f4\uff09\u4e0d\u591f\uff1b\u5982\u679c\u5168\u653e\u5728SSD\u4e0a\u65f6\uff0c\u53c8\u4f1a\u53d1\u73b0\u6210\u672c\u5f88\u9ad8\u3002\u5373\u4f7f\u516c\u53f8\u80fd\u591f\u5927\u6c14\u5230\u90fd\u653e\u5230SSD\u4e0a\uff0c\u4f60\u4f1a\u53d1\u73b01TB\u7684\u6570\u636e\u91cc\u9762\u53ef\u80fd\u53ea\u6709200G\u662f\u7ecf\u5e38\u88ab\u8bbf\u95ee\u7684\uff0c300G\u53ef\u80fd\u5076\u5c14\u88ab\u8bbf\u95ee\u5230\uff0c\u6700\u540e\u5269\u4e0b\u7684500G\u53ef\u80fd\u5df2\u7ecf\u6210\u4e3a\u5386\u53f2\u6570\u636e\u4e86\uff0c\u51e0\u4e4e\u4e0d\u88ab\u8bbf\u95ee\u5230\uff0c\u5982\u679c\u5168\u90e8\u90fd\u653e\u5728SSD\u4e0a\u6709\u7565\u6709\u6d6a\u8d39\u3002\u4e8e\u662f\u5c31\u6709\u4e86Flashcache\u3002 Flashcache\u4e00\u4e2a\u975e\u5e38\u4e0d\u9519\u7684\u8f6f\u4ef6\uff08\u51c6\u786e\u7684\u8bf4\u662f\u4e00\u4e2aLinux\u7684\u6a21\u5757\uff09\uff0c\u53ef\u4ee5\u52a8\u6001\u52a0\u8f7d\u3002Flashcache\u901a\u8fc7\u5728\u6587\u4ef6\u7cfb\u7edf\uff08VFS\uff09\u548c\u8bbe\u5907\u9a71\u52a8\u4e4b\u95f4\u65b0\u589e\u4e86\u4e00\u6b21\u7f13\u5b58\u5c42\uff0c\u6765\u5b9e\u73b0\u5bf9\u70ed\u95e8\u7684\u7f13\u5b58\u3002Flashcache\u662f\u53e6\u4e00\u79cd\u7f13\u5b58\uff0c\u4e00\u822c\u7528SSD\u4f5c\u4e3a\u4ecb\u8d28\u7684\u7f13\u5b58\uff08\u4e00\u822c\u7684\u7f13\u5b58\u7528\u7684\u662f\u5185\u5b58\uff09\uff0c\u901a\u8fc7\u5c06\u4f20\u7edf\u786c\u76d8\u4e0a\u7684\u70ed\u95e8\u6570\u636e\u7f13\u5b58\u5230SSD\u4e0a\uff0c\u7136\u540e\u5229\u7528SSD\u4f18\u79c0\u7684\u8bfb\u6027\u80fd\uff0c\u6765\u52a0\u901f\u7cfb\u7edf\u3002\u8fd9\u4e2a\u65b9\u6cd5\u8f83\u4e4b\u5185\u5b58\u7f13\u5b58\uff0c\u6ca1\u6709\u5185\u5b58\u5feb\uff0c\u4f46\u662f\u7a7a\u95f4\u53ef\u4ee5\u6bd4\u5185\u5b58\u5927\u5f88\u591a\u3002 \u672c\u6587\u662f\u4e00\u4e2a\u5173\u4e8eFlashcache\u7684\u521d\u6b65\u4ecb\u7ecd\u3002<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_eb_attr":"","inline_featured_image":false,"_tocer_settings":[],"footnotes":""},"categories":[27,6],"tags":[60,121,45],"class_list":["post-2368","post","type-post","status-publish","format-standard","hentry","category-linux","category-mysql","tag-flashcache","tag-linux","tag-45"],"_links":{"self":[{"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/posts\/2368","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/comments?post=2368"}],"version-history":[{"count":18,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/posts\/2368\/revisions"}],"predecessor-version":[{"id":2482,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/posts\/2368\/revisions\/2482"}],"wp:attachment":[{"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/media?parent=2368"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/categories?post=2368"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.orczhou.com\/index.php\/wp-json\/wp\/v2\/tags?post=2368"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}