{"id":126,"date":"2015-08-20T16:17:00","date_gmt":"2015-08-20T08:17:00","guid":{"rendered":"http:\/\/yyshell.com\/?p=126"},"modified":"2015-09-14T10:09:20","modified_gmt":"2015-09-14T02:09:20","slug":"centos%e7%b3%bb%e7%bb%9f%e5%bf%ab%e9%80%9f%e6%8c%82%e8%bd%bd%e7%a3%81%e7%9b%98%e6%95%99%e7%a8%8b","status":"publish","type":"post","link":"https:\/\/yyshell.com\/?p=126","title":{"rendered":"CentOS\u7cfb\u7edf\u5feb\u901f\u6302\u8f7d\u78c1\u76d8\u6559\u7a0b"},"content":{"rendered":"<p>\u73b0\u5728\u5f88\u591a\u7ad9\u957f\u90fd\u559c\u6b22\u79df\u7528\u4e91\u670d\u52a1\u5668\u6765\u5efa\u7ad9\u4e86\uff0c\u4e91\u670d\u52a1\u5668\u901a\u5e38\u6709\u4e24\u5757\u78c1\u76d8\uff0c\u4e00\u5757\u7cfb\u7edf\u76d8\uff0c\u4e00\u5757\u653e\u6570\u636e\u7684\u76d8\uff0c\u6570\u636e\u76d8\u9700\u8981\u6302\u8f7d\u624d\u80fd\u4f7f\u7528\u8d77\u6765\u3002\u90e8\u5206\u7ad9\u957f\u8fde\u57fa\u672c\u7684\u78c1\u76d8\u6302\u8f7d\u90fd\u4e0d\u4f1a\uff0c\u7ecf\u5e38\u95ee\u6211\uff0c\u6211\u4e5f\u662f\u5f88\u6349\u6025\u7684\uff0c\u4e0b\u9762\u5c31\u5199\u4e2a\u7b80\u8981\u7684\u6559\u7a0b\uff0c\u7cfb\u7edf\u8f93\u5165\u7684\u547d\u4ee4\u90fd\u662f[root@format ~]# \u4e4b\u540e\u7684\u5b57\u7b26\uff0c\u4e0d\u8981\u4e00\u80a1\u8111\u590d\u5236\uff0c\u5bfc\u81f4\u51fa\u9519\uff01<\/p>\n<p>\u670d\u52a1\u5668\u78c1\u76d8\u901a\u5e38\u5206\u4e3aide\u63a5\u53e3\u7684\u548cscsi\u63a5\u53e3\u7684\u3002\u5728\u670d\u52a1\u5668\u4e0a\u770b\uff0c\u5c31\u662fdev\u76ee\u5f55\u4e0b\u9762\u7684\u8bbe\u5907\u4ee5h\u5f00\u5934\u548cs\u5f00\u5934\u7684\u533a\u522b\u3002\u76ee\u524d\uff0c\u5927\u90e8\u5206\u90fd\u662fs\u5f00\u5934\u7684\u78c1\u76d8\u8bbe\u5907\uff0c\u663e\u793a\u4e3asda\uff0csdb\u7b49\u7b49\u3002<\/p>\n<p>\u767b\u5f55\u7cfb\u7edf\u540e\uff0c\u6302\u8f7d\u78c1\u76d8\u7b2c\u4e00\u6b65\uff0c\u67e5\u770b\u5df2\u6709\u7684\u78c1\u76d8\u8bbe\u5907\u3002<\/p>\n<pre class=\"lang:default decode:true\">[root@format ~]# ls \/dev\/sd*<\/pre>\n<p>\u663e\u793a\u7ed3\u679c\uff1a<\/p>\n<pre class=\"lang:default decode:true\">\/dev\/sda \/dev\/sda1 \/dev\/sda2 \/dev\/sda3 \/dev\/sdb<\/pre>\n<p>sda\u8bbe\u5907\u53ca\u5176\u540e\u9762\u76841,2,3\u5206\u533a\u660e\u663e\u5c31\u662f\u7cfb\u7edf\u5b89\u88c5\u7684\u78c1\u76d8\u3002\u6211\u4eec\u53ea\u9700\u8981\u5904\u7406\u540e\u9762\u7684\u7b2c\u4e8c\u5757\u78c1\u76d8sdb\u8bbe\u5907\u5c31\u884c\u4e86\u3002<\/p>\n<p>\u7b2c\u4e8c\u6b65\uff0c\u5148\u683c\u5f0f\u5316\u78c1\u76d8\uff1a<\/p>\n<pre class=\"lang:default decode:true \">[root@format ~]# mkfs.ext4 \/dev\/sdb<\/pre>\n<p>\u8fd9\u91cc\uff0ccentos6\u7cfb\u5217\u63a8\u8350\u4f7f\u7528ext4\u6587\u4ef6\u7cfb\u7edf\uff0ccentos7\u63a8\u8350\u4f7f\u7528xfs\u6587\u4ef6\u7cfb\u7edf\u3002centos7\u683c\u5f0f\u5316\u7684\u65f6\u5019\uff0c\u7528mkfs.xfs \/dev\/sdb \u5c31\u53ef\u4ee5\u4e86\u3002<\/p>\n<p>\u76f4\u63a5\u683c\u5f0f\u5316\u78c1\u76d8\u8bbe\u5907\u4f1a\u63d0\u9192\u4f60\uff1a<\/p>\n<blockquote><p>\/dev\/sdb is entire device, not just one partition!<\/p><\/blockquote>\n<p>\u63d0\u9192\u4f60\uff0csdb\u662f\u4e00\u4e2a\u8bbe\u5907\uff0c\u4e0d\u662f\u4e00\u4e2a\u5206\u533a\u3002\u6211\u89c9\u5f97\u4e91\u670d\u52a1\u5668\u6ca1\u6709\u5fc5\u8981\u5206\u533a\uff0c\u76f4\u63a5\u7528\u6574\u4e2a\u8bbe\u5907\u5c31\u53ef\u4ee5\u4e86\u3002\u9009\u62e9\u65e0\u8bba\u5982\u4f55\u90fd\u4e5f\u8981\u7ee7\u7eed\uff0c\u6309y\u7ee7\u7eed\u3002<\/p>\n<p>\u7b2c\u4e09\u6b65\uff0c\u521b\u5efa\u8981\u6302\u8f7d\u7684\u76ee\u5f55\uff1a<\/p>\n<pre class=\"lang:default decode:true \">[root@format ~]# mkdir \/mnt\/sdb<\/pre>\n<p>\u6b64\u65f6\uff0c\u6211\u4eec\u5df2\u7ecf\u5728\/mnt \u76ee\u5f55\u4e0b\u9762\u521b\u5efa\u4e86\u8981\u6302\u8f7d\u7684\u76ee\u5f55sdb\u4e86\u3002<\/p>\n<p>\u7b2c\u56db\u6b65\uff0c\u7f16\u8f91fstab\u6587\u4ef6\uff1a<\/p>\n<pre class=\"lang:default decode:true \">[root@format ~]# echo \"\/dev\/sdb \/mnt\/sdb ext4 defaults 0 0\" &gt;&gt; \/etc\/fstab<\/pre>\n<p>\u4e2d\u95f4\u7684ext4\u662f\u4f60\u4e0a\u9762\u7b2c\u4e8c\u6b65\u683c\u5f0f\u5316\u7684\u65f6\u5019\u4f7f\u7528\u7684\u6587\u4ef6\u7cfb\u7edf\u7c7b\u578b\uff0c\u5982\u679c\u662fCentOS7\uff0c\u4f7f\u7528xfs\u6587\u4ef6\u7cfb\u7edf\uff0c\u6539\u6210xfs\u5c31\u884c\u4e86\u3002<\/p>\n<p>\u7b2c\u4e94\u6b65\uff0c\u6302\u8f7d\uff1a<\/p>\n<pre class=\"lang:default decode:true \">[root@format ~]# mount -a<\/pre>\n<p>\u5982\u679c\u6ca1\u62a5\u9519\uff0c\u5e94\u8be5\u5df2\u7ecf\u6302\u8f7d\u6210\u529f\u4e86\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u73b0\u5728\u5f88\u591a\u7ad9\u957f\u90fd\u559c\u6b22\u79df\u7528\u4e91\u670d\u52a1\u5668\u6765\u5efa\u7ad9\u4e86\uff0c\u4e91\u670d\u52a1\u5668\u901a\u5e38\u6709\u4e24\u5757\u78c1\u76d8\uff0c\u4e00\u5757\u7cfb\u7edf\u76d8\uff0c\u4e00\u5757<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"class_list":["post-126","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/yyshell.com\/index.php?rest_route=\/wp\/v2\/posts\/126","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/yyshell.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/yyshell.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/yyshell.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/yyshell.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=126"}],"version-history":[{"count":1,"href":"https:\/\/yyshell.com\/index.php?rest_route=\/wp\/v2\/posts\/126\/revisions"}],"predecessor-version":[{"id":127,"href":"https:\/\/yyshell.com\/index.php?rest_route=\/wp\/v2\/posts\/126\/revisions\/127"}],"wp:attachment":[{"href":"https:\/\/yyshell.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=126"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/yyshell.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=126"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/yyshell.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=126"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}