{"id":156629,"date":"2019-09-03T09:09:14","date_gmt":"2019-09-03T01:09:14","guid":{"rendered":"https:\/\/gulass.cn\/?p=156629"},"modified":"2019-08-27T10:10:12","modified_gmt":"2019-08-27T02:10:12","slug":"centos7-raid5","status":"publish","type":"post","link":"https:\/\/gulass.cn\/centos7-raid5.html","title":{"rendered":"CentOS 7 \u8f6fRAID5\u8bbe\u7f6e"},"content":{"rendered":"\n\n\n
\u5bfc\u8bfb<\/td>\nRAID\u662f\u82f1\u6587Redundant Array of Independent Disks\u7684\u7f29\u5199\uff0c\u4e2d\u6587\u7b80\u79f0\u4e3a\u72ec\u7acb\u5197\u4f59\u78c1\u76d8\u9635\u5217\u3002<\/strong><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n
RAID\u7684\u8bbe\u7f6e\u65b9\u6cd5<\/strong><\/div>\n
\u4e00\u3001RAID\u78c1\u76d8\u9635\u5217\u4ecb\u7ecd<\/strong><\/span><\/div>\n

RAID\u662f\u82f1\u6587Redundant Array of Independent Disks\u7684\u7f29\u5199\uff0c\u4e2d\u6587\u7b80\u79f0\u4e3a\u72ec\u7acb\u5197\u4f59\u78c1\u76d8\u9635\u5217\u3002RAID\u662f\u628a\u591a\u5757\u72ec\u7acb\u7684\u7269\u7406\u786c\u76d8\u6309\u4e0d\u540c\u7684\u65b9\u5f0f\u7ec4\u5408\u8d77\u6765\u5f62\u6210\u4e00\u4e2a\u786c\u76d8\u7ec4\uff08\u903b\u8f91\u786c\u76d8\uff09\uff0c\u4ece\u800c\u63d0\u4f9b\u6bd4\u5355\u4e2a\u786c\u76d8\u66f4\u9ad8\u7684\u5b58\u50a8\u6027\u80fd\u548c\u63d0\u4f9b\u6570\u636e\u5907\u4efd\u6280\u672f\u7ec4\u6210\u78c1\u76d8\u9635\u5217\u7684\u4e0d\u540c\u65b9\u5f0f\u79f0\u4e3aRAID\u7ea7\u522b\uff08RAID Levels\uff09\uff0c\u5e38\u7528\u7684RAID\u7ea7\u522b\u6709\u4ee5\u4e0b\u51e0\u79cd: RAIDO\uff0cRAID1\uff0cRAID5\uff0cRAID6\uff0cRAID1+0\u7b49<\/p>\n

\u4e8c\u3001RAID 5\u78c1\u76d8\u9635\u5217<\/strong><\/span><\/div>\n

RAID 5\u78c1\u76d8\u9635\u5217\u7531N\uff08N>=3\uff09\u5757\u76d8\u7ec4\u6210\u9635\u5217\uff0c\u4e00\u4efd\u6570\u636e\u4ea7\u751fN-1\u4e2a\u6761\u5e26\uff0c\u540c\u65f6\u8fd8\u67091\u4efd\u6821\u9a8c\u6570\u636e\u5171N\u4efd\u6570\u636e\u5728N\u5757\u76d8\u4e0a\u5faa\u73af\u5747\u8861\u5b58\u50a8
\n\"\"
\nN\u5757\u76d8\u540c\u65f6\u8bfb\u5199\uff0c\u8bfb\u6027\u80fd\u5f88\u9ad8\uff0c\u4f46\u7531\u4e8e\u6709\u6821\u9a8c\u673a\u5236\u7684\u95ee\u9898\uff0c\u5199\u6027\u80fd\u76f8\u5bf9\u4e0d\u9ad8\u3002\u78c1\u76d8\u4e3a\uff08N-1\uff09\/N\uff0c\u53ef\u9760\u6027\u9ad8\uff0c\u5141\u8bb8\u574f1\u5757\u76d8\uff0c\u4e0d\u5f71\u54cd\u6240\u6709\u6570\u636e\u3002
\n\"\"<\/p>\n

\u5b9e\u9a8c\u6b65\u9aa4\u73af\u5883\u51c6\u5907\uff1a
\n1.\u51c6\u5907\u4e09\u4e2a\u4ee5\u4e0a\u5e76\u4e14\u5927\u5c0f\u76f8\u540c\u7684\u786c\u76d8\uff0c\u505a\u597d\u5206\u533a\uff08fd\uff09\uff0c\u68c0\u67e5\u662f\u5426\u5b89\u88c5\u4e86mdadm\u5b89\u88c5\u5305
\n\"\"
\n2.\u547d\u4ee4\uff1amdadm -C -v \/dev\/md5 -l5 -n3 \/dev\/sd[b-d]1 -x1 \/dev\/sde1<\/span>
\n\"\"
\n3.\u67e5\u770b\u540c\u6b65\u8fdb\u7a0b \u547d\u4ee4\uff1acat \/proc\/mdstat<\/span>
\n\"\"
\n4.\u67e5\u770b\u78c1\u76d8\u4f7f\u7528\u60c5\u51b5 \u547d\u4ee4 mdadm -D \/dev\/md5<\/span>
\n\"\"
\n5\u6267\u884c\u201cmdadm -f \/dev\/md5 \/dev\/sdb1\u201d<\/span>\u547d\u4ee4\u5378\u6389\u78c1\u76d8\u6765\u6a21\u62df\u4e00\u5757\u78c1\u76d8\u6302\u4e86\u3002
\n\u53ef\u4ee5\u770b\u5230\u6b63\u5728\u66ff\u6362\uff0csdb1\u5df2\u7ecf\u5931\u6548
\n\"\"\"\"
\n6.\u7528mdadm \/dev\/md5 \/ -r \/dev\/sdb1<\/span>\u79fb\u9664 \u7136\u540e\u628a\/dev\/sde1 mdadm \/dev\/md5 --add \/dev\/sdf1<\/span>\u589e\u52a0\u4e3a\u70ed\u5907\u76d8
\n\"\"
\n7.\u683c\u5f0f\u5316\uff0c\u6302\u8f7d\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"

RAID\u662f\u82f1\u6587Redundant Array of Independent Disks\u7684\u7f29\u5199\uff0c\u4e2d\u6587\u7b80\u79f0\u4e3a\u72ec\u7acb\u5197 […]<\/p>\n","protected":false},"author":1890,"featured_media":156644,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[55],"tags":[],"class_list":["post-156629","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-thread"],"acf":[],"_links":{"self":[{"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/posts\/156629","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/users\/1890"}],"replies":[{"embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/comments?post=156629"}],"version-history":[{"count":5,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/posts\/156629\/revisions"}],"predecessor-version":[{"id":157299,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/posts\/156629\/revisions\/157299"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/media\/156644"}],"wp:attachment":[{"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/media?parent=156629"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/categories?post=156629"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/gulass.cn\/wp-json\/wp\/v2\/tags?post=156629"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}